clusters: fix linting (ugh)
Signed-off-by: Varun Patil <radialapps@gmail.com>pull/767/head
parent
66f9616942
commit
46a15a16eb
|
@ -87,7 +87,7 @@ class AlbumsBackend extends Backend
|
||||||
$this->tq->allowEmptyRoot();
|
$this->tq->allowEmptyRoot();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getClustersI(int $fileid = 0): array
|
public function getClustersInternal(int $fileid = 0): array
|
||||||
{
|
{
|
||||||
// Run actual queries
|
// Run actual queries
|
||||||
$list = [];
|
$list = [];
|
||||||
|
|
|
@ -66,7 +66,7 @@ abstract class Backend
|
||||||
*
|
*
|
||||||
* @param int $fileid Filter clusters by file ID (optional)
|
* @param int $fileid Filter clusters by file ID (optional)
|
||||||
*/
|
*/
|
||||||
abstract protected function getClustersI(int $fileid = 0): array;
|
abstract public function getClustersInternal(int $fileid = 0): array;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get a cluster ID for the given cluster.
|
* Get a cluster ID for the given cluster.
|
||||||
|
@ -134,8 +134,9 @@ abstract class Backend
|
||||||
*
|
*
|
||||||
* @param int $fileid Filter clusters by file ID (optional)
|
* @param int $fileid Filter clusters by file ID (optional)
|
||||||
*/
|
*/
|
||||||
public final function getClusters(int $fileid): array {
|
final public function getClusters(int $fileid): array
|
||||||
$list = $this->getClustersI($fileid);
|
{
|
||||||
|
$list = $this->getClustersInternal($fileid);
|
||||||
|
|
||||||
foreach ($list as &$cluster) {
|
foreach ($list as &$cluster) {
|
||||||
$cluster['cluster_id'] = $this->getClusterId($cluster);
|
$cluster['cluster_id'] = $this->getClusterId($cluster);
|
||||||
|
@ -148,7 +149,7 @@ abstract class Backend
|
||||||
/**
|
/**
|
||||||
* Register the backend. Do not override.
|
* Register the backend. Do not override.
|
||||||
*/
|
*/
|
||||||
public static final function register(): void
|
final public static function register(): void
|
||||||
{
|
{
|
||||||
Manager::register(static::clusterType(), static::class);
|
Manager::register(static::clusterType(), static::class);
|
||||||
}
|
}
|
||||||
|
|
|
@ -123,7 +123,7 @@ class FaceRecognitionBackend extends Backend
|
||||||
unset($row['face_x'], $row['face_y'], $row['face_w'], $row['face_h'], $row['image_height'], $row['image_width']);
|
unset($row['face_x'], $row['face_y'], $row['face_w'], $row['face_h'], $row['image_height'], $row['image_width']);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getClustersI(int $fileid = 0): array
|
public function getClustersInternal(int $fileid = 0): array
|
||||||
{
|
{
|
||||||
if ($fileid) {
|
if ($fileid) {
|
||||||
throw new \Exception('FaceRecognitionBackend: fileid filter not implemented');
|
throw new \Exception('FaceRecognitionBackend: fileid filter not implemented');
|
||||||
|
|
|
@ -63,7 +63,7 @@ class PlacesBackend extends Backend
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getClustersI(int $fileid = 0): array
|
public function getClustersInternal(int $fileid = 0): array
|
||||||
{
|
{
|
||||||
if ($fileid) {
|
if ($fileid) {
|
||||||
throw new \Exception('PlacesBackend: fileid filter not implemented');
|
throw new \Exception('PlacesBackend: fileid filter not implemented');
|
||||||
|
|
|
@ -129,7 +129,7 @@ class RecognizeBackend extends Backend
|
||||||
unset($row['face_w'], $row['face_h'], $row['face_x'], $row['face_y']);
|
unset($row['face_w'], $row['face_h'], $row['face_x'], $row['face_y']);
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getClustersI(int $fileid = 0): array
|
public function getClustersInternal(int $fileid = 0): array
|
||||||
{
|
{
|
||||||
$query = $this->tq->getBuilder();
|
$query = $this->tq->getBuilder();
|
||||||
|
|
||||||
|
|
|
@ -67,7 +67,7 @@ class TagsBackend extends Backend
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getClustersI(int $fileid = 0): array
|
public function getClustersInternal(int $fileid = 0): array
|
||||||
{
|
{
|
||||||
if ($fileid) {
|
if ($fileid) {
|
||||||
throw new \Exception('TagsBackend: fileid filter not implemented');
|
throw new \Exception('TagsBackend: fileid filter not implemented');
|
||||||
|
|
Loading…
Reference in New Issue