Interface IAppointmentHandler
- All Superinterfaces:
IAPIHandler
,IGenericHandler
,Serializable
- All Known Implementing Classes:
AppointmentHandler
Handler for
Appointment
entities.- Author:
- XIMA MEDIA GmbH
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Cancels the given appointment.Books the given appointment.getAllBy
(UserContext uc, IAppointmentQueryParams queryParams) Returns all appointments that match the given query parameters.getByUUID
(UserContext uc, String uuid) Finds the appointment with the given UUID.getByUUID
(UserContext uc, UUID uuid) Finds the appointment with the given UUID.Moves an appointment to a different time and date.Validates whether the given appointments can be created or updated.Methods inherited from interface de.xima.fc.com.interfaces.IAPIHandler
getName
Methods inherited from interface de.xima.fc.handler.interfaces.entity.IGenericHandler
create, create, delete, delete, deleteBy, deleteById, deleteById, getAll, getAllBy, getAttributes, getAttributes, getBy, getById, getById, getById, getEntityRefs, getSingleAttributes, getSingleAttributes, resultTotalCount, update, update
-
Method Details
-
cancelBookedAppointment
void cancelBookedAppointment(UserContext uc, IAppointmentDeleteBookingParams params) throws AppointmentBookingException Cancels the given appointment. You should callvalidateAppointments(UserContext, IAppointmentValidateParams)
first if you have not done so yet.- Parameters:
uc
- Current user context for accessing the database.params
- Parameters with the appointment to cancel, must be a persisted entity.- Throws:
AppointmentBookingException
- When the booking could not be performed. SeeAppointmentBookingException.getBookingError()
for more details.
-
createBookedAppointment
Appointment createBookedAppointment(UserContext uc, IAppointmentCreateBookingParams params) throws AppointmentBookingException Books the given appointment. You should callvalidateAppointments(UserContext, IAppointmentValidateParams)
first if you have not done so yet.- Parameters:
uc
- Current user context for accessing the database.params
- Parameters with the appointment to book, must be a new (non-persisted) entity.- Returns:
- The persisted appointment.
- Throws:
AppointmentBookingException
- When the booking could not be performed. SeeAppointmentBookingException.getBookingError()
for more details.
-
getAllBy
Returns all appointments that match the given query parameters. You should callvalidateAppointments(UserContext, IAppointmentValidateParams)
first if you have not done so yet.- Parameters:
uc
- Current user context for accessing the database.queryParams
- Restrictions to apply the returned appointments.- Returns:
- All appointments that match the given query parameters.
-
getByUUID
Finds the appointment with the given UUID.- Parameters:
uc
- Current user context for accessing the database.uuid
- UUID of an appointment.- Returns:
- The appointment with the given UUID.
-
getByUUID
Finds the appointment with the given UUID.- Parameters:
uc
- Current user context for accessing the database.uuid
- UUID of an appointment.- Returns:
- The appointment with the given UUID.
-
moveBookedAppointment
Appointment moveBookedAppointment(UserContext uc, IAppointmentMoveBookingParams params) throws AppointmentBookingException Moves an appointment to a different time and date.- Parameters:
uc
- Current user context for accessing the database.params
- Parameters with the appointment to move.- Returns:
- The updated appointment from the database.
- Throws:
AppointmentBookingException
- When the booking could not be performed. SeeAppointmentBookingException.getBookingError()
for more details.
-
validateAppointments
List<EAppointmentBookingError> validateAppointments(UserContext uc, IAppointmentValidateParams params) Validates whether the given appointments can be created or updated.- Parameters:
uc
- Current user context for accessing the database.params
- Parameters with the appointments to validate.- Returns:
- The validation errors for each appointment.
-