Class ShippingMethodReferenceBuilder
java.lang.Object
com.commercetools.api.models.shipping_method.ShippingMethodReferenceBuilder
- All Implemented Interfaces:
Builder<ShippingMethodReference>
public class ShippingMethodReferenceBuilder
extends Object
implements Builder<ShippingMethodReference>
ShippingMethodReferenceBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ShippingMethodReference shippingMethodReference = ShippingMethodReference.builder()
.id("{id}")
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
builds ShippingMethodReference with checking for non-null required valuesbuilds ShippingMethodReference without checking for non-null required valuesgetId()
Unique identifier of the referenced ShippingMethod.getObj()
Contains the representation of the expanded ShippingMethod.Unique identifier of the referenced ShippingMethod.obj
(ShippingMethod obj) Contains the representation of the expanded ShippingMethod.Contains the representation of the expanded ShippingMethod.of()
factory method for an instance of ShippingMethodReferenceBuilderof
(ShippingMethodReference template) create builder for ShippingMethodReference instancewithObj
(Function<ShippingMethodBuilder, ShippingMethod> builder) Contains the representation of the expanded ShippingMethod.
-
Constructor Details
-
ShippingMethodReferenceBuilder
public ShippingMethodReferenceBuilder()
-
-
Method Details
-
id
Unique identifier of the referenced ShippingMethod.
- Parameters:
id
- value to be set- Returns:
- Builder
-
obj
public ShippingMethodReferenceBuilder obj(Function<ShippingMethodBuilder, ShippingMethodBuilder> builder) Contains the representation of the expanded ShippingMethod. Only present in responses to requests with Reference Expansion for ShippingMethods.
- Parameters:
builder
- function to build the obj value- Returns:
- Builder
-
withObj
public ShippingMethodReferenceBuilder withObj(Function<ShippingMethodBuilder, ShippingMethod> builder) Contains the representation of the expanded ShippingMethod. Only present in responses to requests with Reference Expansion for ShippingMethods.
- Parameters:
builder
- function to build the obj value- Returns:
- Builder
-
obj
Contains the representation of the expanded ShippingMethod. Only present in responses to requests with Reference Expansion for ShippingMethods.
- Parameters:
obj
- value to be set- Returns:
- Builder
-
getId
Unique identifier of the referenced ShippingMethod.
- Returns:
- id
-
getObj
Contains the representation of the expanded ShippingMethod. Only present in responses to requests with Reference Expansion for ShippingMethods.
- Returns:
- obj
-
build
builds ShippingMethodReference with checking for non-null required values- Specified by:
build
in interfaceBuilder<ShippingMethodReference>
- Returns:
- ShippingMethodReference
-
buildUnchecked
builds ShippingMethodReference without checking for non-null required values- Returns:
- ShippingMethodReference
-
of
factory method for an instance of ShippingMethodReferenceBuilder- Returns:
- builder
-
of
create builder for ShippingMethodReference instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-