Interface Reservation
Example to create an instance using the builder pattern
Reservation reservation = Reservation.builder()
.quantity(1)
.owner(ownerBuilder -> ownerBuilder)
.createdAt("{createdAt}")
.checkoutStartedAt("{checkoutStartedAt}")
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic ReservationBuilderbuilder()builder factory method for Reservationstatic ReservationBuilderbuilder(Reservation template) create builder for Reservation instancecopyDeep()static ReservationdeepCopy(Reservation template) factory method to create a deep copy of Reservation@NotNull String@NotNull String@NotNull @Valid ReferencegetOwner()A Reference represents a loose reference to another resource in the same Project identified by itsid.@NotNull Integerstatic Reservationof()factory methodstatic Reservationof(Reservation template) factory method to create a shallow copy ReservationvoidsetCheckoutStartedAt(String checkoutStartedAt) set checkoutStartedAtvoidsetCreatedAt(String createdAt) set createdAtvoidA Reference represents a loose reference to another resource in the same Project identified by itsid.voidsetQuantity(Integer quantity) set quantitystatic com.fasterxml.jackson.core.type.TypeReference<Reservation>gives a TypeReference for usage with Jackson DataBinddefault <T> TwithReservation(Function<Reservation, T> helper) accessor map function
-
Method Details
-
getQuantity
- Returns:
- quantity
-
getOwner
A Reference represents a loose reference to another resource in the same Project identified by its
id. ThetypeIdindicates the type of the referenced resource. Each resource type has its corresponding Reference type, like ChannelReference. A referenced resource can be embedded through Reference Expansion. The expanded reference is the value of an additionalobjfield then.- Returns:
- owner
-
getCreatedAt
- Returns:
- createdAt
-
getCheckoutStartedAt
- Returns:
- checkoutStartedAt
-
setQuantity
set quantity- Parameters:
quantity- value to be set
-
setOwner
A Reference represents a loose reference to another resource in the same Project identified by its
id. ThetypeIdindicates the type of the referenced resource. Each resource type has its corresponding Reference type, like ChannelReference. A referenced resource can be embedded through Reference Expansion. The expanded reference is the value of an additionalobjfield then.- Parameters:
owner- value to be set
-
setCreatedAt
set createdAt- Parameters:
createdAt- value to be set
-
setCheckoutStartedAt
set checkoutStartedAt- Parameters:
checkoutStartedAt- value to be set
-
of
factory method- Returns:
- instance of Reservation
-
of
factory method to create a shallow copy Reservation- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
Reservation copyDeep() -
deepCopy
factory method to create a deep copy of Reservation- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for Reservation- Returns:
- builder
-
builder
create builder for Reservation instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withReservation
accessor map function- Type Parameters:
T- mapped type- Parameters:
helper- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-