Class WorkerQueryServiceImpl
java.lang.Object
it.univr.passportease.service.worker.impl.WorkerQueryServiceImpl
- All Implemented Interfaces:
WorkerQueryService
Implementation of
WorkerQueryService.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final RequestTypeRepositoryRepository ofRequestTypeentities.private final ReservationRepositoryRepository ofAvailabilityentities. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet all theRequestType.Get theRequestassociated to theAvailabilitywith the given id.
-
Field Details
-
requestTypeRepository
Repository ofRequestTypeentities. -
reservationRepository
Repository ofAvailabilityentities.
-
-
Constructor Details
-
WorkerQueryServiceImpl
public WorkerQueryServiceImpl()
-
-
Method Details
-
getAllRequestTypes
@PreAuthorize("hasAuthority(\'WORKER\') && hasAuthority(\'VALIDATED\')") public List<RequestType> getAllRequestTypes()Get all theRequestType.- Specified by:
getAllRequestTypesin interfaceWorkerQueryService- Returns:
- a list of all the
RequestType.
-
getRequestByAvailabilityID
@PreAuthorize("hasAuthority(\'WORKER\') && hasAuthority(\'VALIDATED\')") public Request getRequestByAvailabilityID(String id) throws InvalidAvailabilityIDException Get theRequestassociated to theAvailabilitywith the given id.- Specified by:
getRequestByAvailabilityIDin interfaceWorkerQueryService- Parameters:
id- theAvailabilityid.- Returns:
- the
Requestassociated to theAvailabilitywith the given id. - Throws:
InvalidAvailabilityIDException- if the given id is not valid.
-