Interface ProductUpdate
- All Superinterfaces:
ResourceUpdate<ProductUpdate,ProductUpdateAction, ProductUpdateBuilder>
public interface ProductUpdate
extends ResourceUpdate<ProductUpdate,ProductUpdateAction,ProductUpdateBuilder>
ProductUpdate
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ProductUpdate productUpdate = ProductUpdate.builder()
.version(0.3)
.plusActions(actionsBuilder -> actionsBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic ProductUpdateBuilderbuilder()builder factory method for ProductUpdatestatic ProductUpdateBuilderbuilder(ProductUpdate template) create builder for ProductUpdate instancecopyDeep()static ProductUpdatedeepCopy(ProductUpdate template) factory method to create a deep copy of ProductUpdate@NotNull @Valid List<ProductUpdateAction>Update actions to be performed on the Product.@NotNull LongExpected version of the Product on which the changes should be applied.static ProductUpdateof()factory methodstatic ProductUpdateof(ProductUpdate template) factory method to create a shallow copy ProductUpdatevoidsetActions(ProductUpdateAction... actions) Update actions to be performed on the Product.voidsetActions(List<ProductUpdateAction> actions) Update actions to be performed on the Product.voidsetVersion(Long version) Expected version of the Product on which the changes should be applied.static com.fasterxml.jackson.core.type.TypeReference<ProductUpdate>gives a TypeReference for usage with Jackson DataBinddefault <T> TwithProductUpdate(Function<ProductUpdate, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.ResourceUpdate
get
-
Method Details
-
getVersion
Expected version of the Product on which the changes should be applied. If the expected version does not match the actual version, a ConcurrentModification error will be returned.
- Specified by:
getVersionin interfaceResourceUpdate<ProductUpdate,ProductUpdateAction, ProductUpdateBuilder> - Returns:
- version
-
getActions
Update actions to be performed on the Product.
- Specified by:
getActionsin interfaceResourceUpdate<ProductUpdate,ProductUpdateAction, ProductUpdateBuilder> - Returns:
- actions
-
setVersion
Expected version of the Product on which the changes should be applied. If the expected version does not match the actual version, a ConcurrentModification error will be returned.
- Specified by:
setVersionin interfaceResourceUpdate<ProductUpdate,ProductUpdateAction, ProductUpdateBuilder> - Parameters:
version- value to be set
-
setActions
Update actions to be performed on the Product.
- Parameters:
actions- values to be set
-
setActions
Update actions to be performed on the Product.
- Specified by:
setActionsin interfaceResourceUpdate<ProductUpdate,ProductUpdateAction, ProductUpdateBuilder> - Parameters:
actions- values to be set
-
of
factory method- Returns:
- instance of ProductUpdate
-
of
factory method to create a shallow copy ProductUpdate- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
ProductUpdate copyDeep() -
deepCopy
factory method to create a deep copy of ProductUpdate- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for ProductUpdate- Returns:
- builder
-
builder
create builder for ProductUpdate instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withProductUpdate
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
-