Package com.commercetools.api.models.me
Interface MyCartUpdate
- All Superinterfaces:
ResourceUpdate<MyCartUpdate,
MyCartUpdateAction, MyCartUpdateBuilder>
public interface MyCartUpdate
extends ResourceUpdate<MyCartUpdate,MyCartUpdateAction,MyCartUpdateBuilder>
MyCartUpdate
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
MyCartUpdate myCartUpdate = MyCartUpdate.builder()
.version(0.3)
.plusActions(actionsBuilder -> actionsBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic MyCartUpdateBuilder
builder()
builder factory method for MyCartUpdatestatic MyCartUpdateBuilder
builder
(MyCartUpdate template) create builder for MyCartUpdate instancestatic MyCartUpdate
deepCopy
(MyCartUpdate template) factory method to create a deep copy of MyCartUpdate@NotNull @Valid List<MyCartUpdateAction>
Update actions to be performed on the Cart.@NotNull Long
Expected version of the Cart on which the changes apply.static MyCartUpdate
of()
factory methodstatic MyCartUpdate
of
(MyCartUpdate template) factory method to create a shallow copy MyCartUpdatevoid
setActions
(MyCartUpdateAction... actions) Update actions to be performed on the Cart.void
setActions
(List<MyCartUpdateAction> actions) Update actions to be performed on the Cart.void
setVersion
(Long version) Expected version of the Cart on which the changes apply.static com.fasterxml.jackson.core.type.TypeReference<MyCartUpdate>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withMyCartUpdate
(Function<MyCartUpdate, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.ResourceUpdate
get
-
Method Details
-
getVersion
Expected version of the Cart on which the changes apply. If the expected version does not match the actual version, a ConcurrentModification error will be returned.
- Specified by:
getVersion
in interfaceResourceUpdate<MyCartUpdate,
MyCartUpdateAction, MyCartUpdateBuilder> - Returns:
- version
-
getActions
Update actions to be performed on the Cart.
- Specified by:
getActions
in interfaceResourceUpdate<MyCartUpdate,
MyCartUpdateAction, MyCartUpdateBuilder> - Returns:
- actions
-
setVersion
Expected version of the Cart on which the changes apply. If the expected version does not match the actual version, a ConcurrentModification error will be returned.
- Specified by:
setVersion
in interfaceResourceUpdate<MyCartUpdate,
MyCartUpdateAction, MyCartUpdateBuilder> - Parameters:
version
- value to be set
-
setActions
Update actions to be performed on the Cart.
- Parameters:
actions
- values to be set
-
setActions
Update actions to be performed on the Cart.
- Specified by:
setActions
in interfaceResourceUpdate<MyCartUpdate,
MyCartUpdateAction, MyCartUpdateBuilder> - Parameters:
actions
- values to be set
-
of
factory method- Returns:
- instance of MyCartUpdate
-
of
factory method to create a shallow copy MyCartUpdate- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of MyCartUpdate- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for MyCartUpdate- Returns:
- builder
-
builder
create builder for MyCartUpdate instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withMyCartUpdate
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
-