Interface TrackingData
public interface TrackingData
TrackingData
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
TrackingData trackingData = TrackingData.builder()
.trackingId("{trackingId}")
.carrier("{carrier}")
.provider("{provider}")
.providerTransaction("{providerTransaction}")
.isReturn(true)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic TrackingDataBuilderbuilder()builder factory method for TrackingDatastatic TrackingDataBuilderbuilder(TrackingData template) create builder for TrackingData instancecopyDeep()static TrackingDatadeepCopy(TrackingData template) factory method to create a deep copy of TrackingData@NotNull StringThe carrier that delivers the parcel.@NotNull BooleanFlag to distinguish if the parcel is on the way to the customer (false) or on the way back (true).@NotNull String@NotNull String@NotNull StringThe ID to track one parcel.static TrackingDataof()factory methodstatic TrackingDataof(TrackingData template) factory method to create a shallow copy TrackingDatavoidsetCarrier(String carrier) The carrier that delivers the parcel.voidsetIsReturn(Boolean isReturn) Flag to distinguish if the parcel is on the way to the customer (false) or on the way back (true).voidsetProvider(String provider) set providervoidsetProviderTransaction(String providerTransaction) set providerTransactionvoidsetTrackingId(String trackingId) The ID to track one parcel.static com.fasterxml.jackson.core.type.TypeReference<TrackingData>gives a TypeReference for usage with Jackson DataBinddefault <T> TwithTrackingData(Function<TrackingData, T> helper) accessor map function
-
Method Details
-
getTrackingId
The ID to track one parcel.
- Returns:
- trackingId
-
getCarrier
The carrier that delivers the parcel.
- Returns:
- carrier
-
getProvider
- Returns:
- provider
-
getProviderTransaction
- Returns:
- providerTransaction
-
getIsReturn
Flag to distinguish if the parcel is on the way to the customer (false) or on the way back (true).
- Returns:
- isReturn
-
setTrackingId
The ID to track one parcel.
- Parameters:
trackingId- value to be set
-
setCarrier
The carrier that delivers the parcel.
- Parameters:
carrier- value to be set
-
setProvider
set provider- Parameters:
provider- value to be set
-
setProviderTransaction
set providerTransaction- Parameters:
providerTransaction- value to be set
-
setIsReturn
Flag to distinguish if the parcel is on the way to the customer (false) or on the way back (true).
- Parameters:
isReturn- value to be set
-
of
factory method- Returns:
- instance of TrackingData
-
of
factory method to create a shallow copy TrackingData- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
TrackingData copyDeep() -
deepCopy
factory method to create a deep copy of TrackingData- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for TrackingData- Returns:
- builder
-
builder
create builder for TrackingData instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withTrackingData
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
-