56 lines
1.5 KiB
PHP
56 lines
1.5 KiB
PHP
|
|
<?php
|
||
|
|
|
||
|
|
declare(strict_types=1);
|
||
|
|
|
||
|
|
namespace Uwil\ArcadiaGenesisPhpClient\Repository;
|
||
|
|
|
||
|
|
use Uwil\ArcadiaGenesisPhpClient\Lib\ApiDto\Dto\Employee;
|
||
|
|
use Uwil\ArcadiaGenesisPhpClient\Lib\ApiDto\Dto\PageOf;
|
||
|
|
use Uwil\ArcadiaGenesisPhpClient\Lib\ApiQueryBuilder\Direction;
|
||
|
|
use Uwil\ArcadiaGenesisPhpClient\Lib\ApiValueObject\ArcadiaEmployeeId;
|
||
|
|
use Uwil\ArcadiaGenesisPhpClient\Lib\ApiValueObject\EmployeeSorter;
|
||
|
|
use Uwil\ArcadiaGenesisPhpClient\Lib\Pagination;
|
||
|
|
|
||
|
|
interface EmployeeRepository extends Repository
|
||
|
|
{
|
||
|
|
/**
|
||
|
|
* @return PageOf<Employee>
|
||
|
|
*/
|
||
|
|
public function selectAll(
|
||
|
|
Pagination $pagination,
|
||
|
|
?EmployeeSorter $sorter = null
|
||
|
|
): PageOf;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @return PageOf<Employee>
|
||
|
|
*/
|
||
|
|
public function selectAllSince(
|
||
|
|
Pagination $pagination,
|
||
|
|
\DateTimeInterface $since,
|
||
|
|
Direction $sortDirection = Direction::DESC
|
||
|
|
): PageOf;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @param \Uwil\ArcadiaGenesisPhpClient\Lib\ApiValueObject\SiteId[] $sites
|
||
|
|
* @return PageOf<Employee>
|
||
|
|
*/
|
||
|
|
public function selectAllHavingSitesSince(
|
||
|
|
Pagination $pagination,
|
||
|
|
\DateTimeInterface $since,
|
||
|
|
array $sites,
|
||
|
|
Direction $sortDirection = Direction::DESC
|
||
|
|
): PageOf;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @param \Uwil\ArcadiaGenesisPhpClient\Lib\ApiValueObject\SiteId[] $sites
|
||
|
|
* @return PageOf<Employee>
|
||
|
|
*/
|
||
|
|
public function selectAllHavingSites(
|
||
|
|
Pagination $pagination,
|
||
|
|
array $sites,
|
||
|
|
?EmployeeSorter $sorter = null
|
||
|
|
): PageOf;
|
||
|
|
|
||
|
|
public function find(ArcadiaEmployeeId $id): ?Employee;
|
||
|
|
}
|