Class CustomerGroupUpdateBuilder
java.lang.Object
com.commercetools.api.models.customer_group.CustomerGroupUpdateBuilder
- All Implemented Interfaces:
Builder<CustomerGroupUpdate>
CustomerGroupUpdateBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
CustomerGroupUpdate customerGroupUpdate = CustomerGroupUpdate.builder()
.version(0.3)
.plusActions(actionsBuilder -> actionsBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionactions
(CustomerGroupUpdateAction... actions) Update actions to be performed on the CustomerGroup.actions
(List<CustomerGroupUpdateAction> actions) Update actions to be performed on the CustomerGroup.build()
builds CustomerGroupUpdate with checking for non-null required valuesbuilds CustomerGroupUpdate without checking for non-null required valuesUpdate actions to be performed on the CustomerGroup.Expected version of the CustomerGroup on which the changes should be applied.static CustomerGroupUpdateBuilder
of()
factory method for an instance of CustomerGroupUpdateBuilderstatic CustomerGroupUpdateBuilder
of
(CustomerGroupUpdate template) create builder for CustomerGroupUpdate instanceplusActions
(CustomerGroupUpdateAction... actions) Update actions to be performed on the CustomerGroup.plusActions
(Function<CustomerGroupUpdateActionBuilder, Builder<? extends CustomerGroupUpdateAction>> builder) Update actions to be performed on the CustomerGroup.Expected version of the CustomerGroup on which the changes should be applied.withActions
(Function<CustomerGroupUpdateActionBuilder, Builder<? extends CustomerGroupUpdateAction>> builder) Update actions to be performed on the CustomerGroup.
-
Constructor Details
-
CustomerGroupUpdateBuilder
public CustomerGroupUpdateBuilder()
-
-
Method Details
-
version
Expected version of the CustomerGroup on which the changes should be applied. If the expected version does not match the actual version, a ConcurrentModification error will be returned.
- Parameters:
version
- value to be set- Returns:
- Builder
-
actions
Update actions to be performed on the CustomerGroup.
- Parameters:
actions
- value to be set- Returns:
- Builder
-
actions
Update actions to be performed on the CustomerGroup.
- Parameters:
actions
- value to be set- Returns:
- Builder
-
plusActions
Update actions to be performed on the CustomerGroup.
- Parameters:
actions
- value to be set- Returns:
- Builder
-
plusActions
public CustomerGroupUpdateBuilder plusActions(Function<CustomerGroupUpdateActionBuilder, Builder<? extends CustomerGroupUpdateAction>> builder) Update actions to be performed on the CustomerGroup.
- Parameters:
builder
- function to build the actions value- Returns:
- Builder
-
withActions
public CustomerGroupUpdateBuilder withActions(Function<CustomerGroupUpdateActionBuilder, Builder<? extends CustomerGroupUpdateAction>> builder) Update actions to be performed on the CustomerGroup.
- Parameters:
builder
- function to build the actions value- Returns:
- Builder
-
getVersion
Expected version of the CustomerGroup on which the changes should be applied. If the expected version does not match the actual version, a ConcurrentModification error will be returned.
- Returns:
- version
-
getActions
Update actions to be performed on the CustomerGroup.
- Returns:
- actions
-
build
builds CustomerGroupUpdate with checking for non-null required values- Specified by:
build
in interfaceBuilder<CustomerGroupUpdate>
- Returns:
- CustomerGroupUpdate
-
buildUnchecked
builds CustomerGroupUpdate without checking for non-null required values- Returns:
- CustomerGroupUpdate
-
of
factory method for an instance of CustomerGroupUpdateBuilder- Returns:
- builder
-
of
create builder for CustomerGroupUpdate instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-