Class ParcelTrackingDataBuilder
java.lang.Object
com.commercetools.importapi.models.order_patches.ParcelTrackingDataBuilder
- All Implemented Interfaces:
Builder<ParcelTrackingData>
ParcelTrackingDataBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ParcelTrackingData parcelTrackingData = ParcelTrackingData.builder()
.parcelId("{parcelId}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds ParcelTrackingData with checking for non-null required valuesbuilds ParcelTrackingData without checking for non-null required valuesvalue of parcelId}value of trackingData}static ParcelTrackingDataBuilder
of()
factory method for an instance of ParcelTrackingDataBuilderstatic ParcelTrackingDataBuilder
of
(ParcelTrackingData template) create builder for ParcelTrackingData instanceset the value to the parcelIdtrackingData
(TrackingData trackingData) set the value to the trackingDataset the value to the trackingData using the builder functionset the value to the trackingData using the builder function
-
Constructor Details
-
ParcelTrackingDataBuilder
public ParcelTrackingDataBuilder()
-
-
Method Details
-
parcelId
set the value to the parcelId- Parameters:
parcelId
- value to be set- Returns:
- Builder
-
trackingData
public ParcelTrackingDataBuilder trackingData(Function<TrackingDataBuilder, TrackingDataBuilder> builder) set the value to the trackingData using the builder function- Parameters:
builder
- function to build the trackingData value- Returns:
- Builder
-
withTrackingData
public ParcelTrackingDataBuilder withTrackingData(Function<TrackingDataBuilder, TrackingData> builder) set the value to the trackingData using the builder function- Parameters:
builder
- function to build the trackingData value- Returns:
- Builder
-
trackingData
set the value to the trackingData- Parameters:
trackingData
- value to be set- Returns:
- Builder
-
getParcelId
value of parcelId}- Returns:
- parcelId
-
getTrackingData
value of trackingData}- Returns:
- trackingData
-
build
builds ParcelTrackingData with checking for non-null required values- Specified by:
build
in interfaceBuilder<ParcelTrackingData>
- Returns:
- ParcelTrackingData
-
buildUnchecked
builds ParcelTrackingData without checking for non-null required values- Returns:
- ParcelTrackingData
-
of
factory method for an instance of ParcelTrackingDataBuilder- Returns:
- builder
-
of
create builder for ParcelTrackingData instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-