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