Package de.xima.fc.appointment
Class AppointmentConverter
- java.lang.Object
-
- de.xima.fc.appointment.AppointmentSlotIdConverter
-
- de.xima.fc.appointment.AppointmentConverter
-
public final class AppointmentConverter extends AppointmentSlotIdConverter
Converts between the timestamp / ID representation of an appointment and the appointment itself.- Since:
- 6.5.0
- Author:
- XIMA MEDIA GmbH
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static AppointmentidToAppointment(String id, AppointmentTemplate template, AppointmentType type, Vorgang formRecord)Creates a new appointment for the given slot ID and fills it with the given data.static StringslotToId(ExtendedAppointmentFreeSlot slot)-
Methods inherited from class de.xima.fc.appointment.AppointmentSlotIdConverter
appointmentToId, dateTimeToId, idToInstant, idToInstantNull, instantToId, isValidSlotId
-
-
-
-
Method Detail
-
idToAppointment
public static Appointment idToAppointment(String id, AppointmentTemplate template, AppointmentType type, Vorgang formRecord) throws IllegalArgumentException, NullPointerException
Creates a new appointment for the given slot ID and fills it with the given data.- Parameters:
id- Slot ID indicating the time of the new appointment.template- Template to which the slot should belong.type- Appointment type to which the slot should belong.formRecord- The form record that should be set on the new appointment.- Returns:
- The newly created appointment slot.
- Throws:
IllegalArgumentException- When any of the parameters is invalid.NullPointerException- When any of the parameters is null.
-
slotToId
public static String slotToId(ExtendedAppointmentFreeSlot slot)
- Parameters:
slot- Slot for which to create the ID.- Returns:
- The ID for the given appointment slot. Can be used to identify a slot when booking an appointment.
-
-