Interface EstimatedDelivery
public interface EstimatedDelivery
Estimated time window during which a shipment is expected to be delivered. The window is anchored to the selected Shipping Method and the shipping destination.
Example to create an instance using the builder pattern
EstimatedDelivery estimatedDelivery = EstimatedDelivery.builder()
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic EstimatedDeliveryBuilderbuilder()builder factory method for EstimatedDeliverystatic EstimatedDeliveryBuilderbuilder(EstimatedDelivery template) create builder for EstimatedDelivery instancecopyDeep()static EstimatedDeliverydeepCopy(EstimatedDelivery template) factory method to create a deep copy of EstimatedDeliverygetFrom()Date and time (UTC) of the earliest expected delivery.getUntil()Date and time (UTC) of the latest expected delivery.static EstimatedDeliveryof()factory methodstatic EstimatedDeliveryof(EstimatedDelivery template) factory method to create a shallow copy EstimatedDeliveryvoidsetFrom(ZonedDateTime from) Date and time (UTC) of the earliest expected delivery.voidsetUntil(ZonedDateTime until) Date and time (UTC) of the latest expected delivery.static tools.jackson.core.type.TypeReference<EstimatedDelivery>gives a TypeReference for usage with Jackson DataBinddefault <T> TwithEstimatedDelivery(Function<EstimatedDelivery, T> helper) accessor map function
-
Method Details
-
getFrom
ZonedDateTime getFrom()Date and time (UTC) of the earliest expected delivery.
- Returns:
- from
-
getUntil
ZonedDateTime getUntil()Date and time (UTC) of the latest expected delivery. When both
fromanduntilare set,untilmust be equal to or later thanfrom.- Returns:
- until
-
setFrom
Date and time (UTC) of the earliest expected delivery.
- Parameters:
from- value to be set
-
setUntil
Date and time (UTC) of the latest expected delivery. When both
fromanduntilare set,untilmust be equal to or later thanfrom.- Parameters:
until- value to be set
-
of
factory method- Returns:
- instance of EstimatedDelivery
-
of
factory method to create a shallow copy EstimatedDelivery- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
EstimatedDelivery copyDeep() -
deepCopy
factory method to create a deep copy of EstimatedDelivery- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for EstimatedDelivery- Returns:
- builder
-
builder
create builder for EstimatedDelivery instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withEstimatedDelivery
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
-