mirror of
https://github.com/AnimeThemes/animethemes-server.git
synced 2026-09-07 13:13:09 +02:00
* refactor(api): prefer composition to strict inheritance for API queries, requests & actions * style: fix StyleCI findigns
24 lines
462 B
PHP
24 lines
462 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Contracts\Http\Api\Field;
|
|
|
|
use App\Http\Api\Query\Query;
|
|
use App\Http\Api\Schema\Schema;
|
|
|
|
/**
|
|
* Interface SelectableField.
|
|
*/
|
|
interface SelectableField
|
|
{
|
|
/**
|
|
* Determine if the field should be included in the select clause of our query.
|
|
*
|
|
* @param Query $query
|
|
* @param Schema $schema
|
|
* @return bool
|
|
*/
|
|
public function shouldSelect(Query $query, Schema $schema): bool;
|
|
}
|