. */ namespace SP\Domain\Security\Ports; use SP\Domain\Core\Dtos\ItemSearchDto; use SP\Domain\Core\Exceptions\ConstraintException; use SP\Domain\Core\Exceptions\QueryException; use SP\Domain\Security\Models\Eventlog as EventlogModel; use SP\Infrastructure\Database\QueryResult; /** * Class EventlogRepository * * @template T of EventlogModel */ interface EventlogRepository { /** * Clears the event log * * @return bool con el resultado * @throws QueryException * @throws ConstraintException */ public function clear(): bool; /** * Searches for items by a given filter * * @param ItemSearchDto $itemSearchData * * @return QueryResult * @throws ConstraintException * @throws QueryException */ public function search(ItemSearchDto $itemSearchData): QueryResult; /** * @param EventlogModel $eventlog * * @return QueryResult * @throws ConstraintException * @throws QueryException */ public function create(EventlogModel $eventlog): QueryResult; }