Interface Update
- All Superinterfaces:
ResourceUpdate<Update,
UpdateAction, UpdateBuilder>
Update
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
Update update = Update.builder()
.version(0.3)
.plusActions(actionsBuilder -> actionsBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic UpdateBuilder
builder()
builder factory method for Updatestatic UpdateBuilder
create builder for Update instancestatic Update
factory method to create a deep copy of Update@NotNull @Valid List<UpdateAction>
@NotNull Long
static Update
of()
factory methodstatic Update
factory method to create a shallow copy Updatevoid
setActions
(UpdateAction... actions) set actionsvoid
setActions
(List<UpdateAction> actions) set actionsvoid
setVersion
(Long version) set versionstatic com.fasterxml.jackson.core.type.TypeReference<Update>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withUpdate
(Function<Update, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.ResourceUpdate
get
-
Method Details
-
getVersion
- Specified by:
getVersion
in interfaceResourceUpdate<Update,
UpdateAction, UpdateBuilder> - Returns:
- version
-
getActions
- Specified by:
getActions
in interfaceResourceUpdate<Update,
UpdateAction, UpdateBuilder> - Returns:
- actions
-
setVersion
set version- Specified by:
setVersion
in interfaceResourceUpdate<Update,
UpdateAction, UpdateBuilder> - Parameters:
version
- value to be set
-
setActions
set actions- Parameters:
actions
- values to be set
-
setActions
set actions- Specified by:
setActions
in interfaceResourceUpdate<Update,
UpdateAction, UpdateBuilder> - Parameters:
actions
- values to be set
-
of
factory method- Returns:
- instance of Update
-
of
factory method to create a shallow copy Update- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of Update- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for Update- Returns:
- builder
-
builder
create builder for Update instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withUpdate
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
-