Record Class ReservationSummaryDTO
java.lang.Object
java.lang.Record
de.gustavblass.fsu.fmi.roombooking.dto.ReservationSummaryDTO
- Record Components:
id- TheReservation.id.applicantId- TheActor.idof theReservation.applicant.requestDate- TheReservation.requestDate.startDate- TheReservation.startDate.endDate- TheReservation.endDate.roomId- TheRoom.idof theReservation.room.
public record ReservationSummaryDTO(@NonNull Long id, @NonNull Long applicantId, @NonNull LocalDateTime requestDate, @NonNull LocalDateTime startDate, @NonNull LocalDateTime endDate, @NonNull Long roomId)
extends Record
Data-transfer object representing a
Reservation.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final @NonNull LongThe field for theapplicantIdrecord component.private final @NonNull LocalDateTimeThe field for theendDaterecord component.private final @NonNull LongThe field for theidrecord component.private final @NonNull LocalDateTimeThe field for therequestDaterecord component.private final @NonNull LongThe field for theroomIdrecord component.private final @NonNull LocalDateTimeThe field for thestartDaterecord component. -
Constructor Summary
ConstructorsConstructorDescriptionReservationSummaryDTO(@NonNull Long id, @NonNull Long applicantId, @NonNull LocalDateTime requestDate, @NonNull LocalDateTime startDate, @NonNull LocalDateTime endDate, @NonNull Long roomId) Creates an instance of aReservationSummaryDTOrecord class. -
Method Summary
Modifier and TypeMethodDescription@NonNull LongReturns the value of theapplicantIdrecord component.@NonNull LocalDateTimeendDate()Returns the value of theendDaterecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@NonNull Longid()Returns the value of theidrecord component.@NonNull LocalDateTimeReturns the value of therequestDaterecord component.@NonNull LongroomId()Returns the value of theroomIdrecord component.@NonNull LocalDateTimeReturns the value of thestartDaterecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
id
-
applicantId
The field for theapplicantIdrecord component. -
requestDate
The field for therequestDaterecord component. -
startDate
The field for thestartDaterecord component. -
endDate
The field for theendDaterecord component. -
roomId
-
-
Constructor Details
-
ReservationSummaryDTO
public ReservationSummaryDTO(@NonNull @NonNull Long id, @NonNull @NonNull Long applicantId, @NonNull @NonNull LocalDateTime requestDate, @NonNull @NonNull LocalDateTime startDate, @NonNull @NonNull LocalDateTime endDate, @NonNull @NonNull Long roomId) Creates an instance of aReservationSummaryDTOrecord class.- Parameters:
id- the value for theidrecord componentapplicantId- the value for theapplicantIdrecord componentrequestDate- the value for therequestDaterecord componentstartDate- the value for thestartDaterecord componentendDate- the value for theendDaterecord componentroomId- the value for theroomIdrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
id
-
applicantId
Returns the value of theapplicantIdrecord component.- Returns:
- the value of the
applicantIdrecord component
-
requestDate
Returns the value of therequestDaterecord component.- Returns:
- the value of the
requestDaterecord component
-
startDate
-
endDate
-
roomId
-