Interface GraphQLDuplicatePriceKeyError
- All Superinterfaces:
GraphQLErrorObject
Returned when a Price key conflicts with an existing key.
Keys of Embedded Prices must be unique per ProductVariant.
Example to create an instance using the builder pattern
GraphQLDuplicatePriceKeyError graphQLDuplicatePriceKeyError = GraphQLDuplicatePriceKeyError.builder()
.conflictingPrice(conflictingPriceBuilder -> conflictingPriceBuilder)
.build()
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
discriminator value for GraphQLDuplicatePriceKeyError -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
builder factory method for GraphQLDuplicatePriceKeyErrorbuilder
(GraphQLDuplicatePriceKeyError template) create builder for GraphQLDuplicatePriceKeyError instancedeepCopy
(GraphQLDuplicatePriceKeyError template) factory method to create a deep copy of GraphQLDuplicatePriceKeyError@NotNull String
getCode()
One of the error codes that is listed on the Errors page.@NotNull @Valid Price
Conflicting Embedded Price.of()
factory methodof
(GraphQLDuplicatePriceKeyError template) factory method to create a shallow copy GraphQLDuplicatePriceKeyErrorvoid
setConflictingPrice
(Price conflictingPrice) Conflicting Embedded Price.static com.fasterxml.jackson.core.type.TypeReference<GraphQLDuplicatePriceKeyError>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
accessor map functionMethods inherited from interface com.commercetools.api.models.error.GraphQLErrorObject
setValue, values, withGraphQLErrorObject
-
Field Details
-
DUPLICATE_PRICE_KEY
discriminator value for GraphQLDuplicatePriceKeyError- See Also:
-
-
Method Details
-
getCode
Description copied from interface:GraphQLErrorObject
One of the error codes that is listed on the Errors page.
- Specified by:
getCode
in interfaceGraphQLErrorObject
- Returns:
- code
-
getConflictingPrice
Conflicting Embedded Price.
- Returns:
- conflictingPrice
-
setConflictingPrice
Conflicting Embedded Price.
- Parameters:
conflictingPrice
- value to be set
-
of
factory method- Returns:
- instance of GraphQLDuplicatePriceKeyError
-
of
factory method to create a shallow copy GraphQLDuplicatePriceKeyError- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
@Nullable static GraphQLDuplicatePriceKeyError deepCopy(@Nullable GraphQLDuplicatePriceKeyError template) factory method to create a deep copy of GraphQLDuplicatePriceKeyError- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for GraphQLDuplicatePriceKeyError- Returns:
- builder
-
builder
create builder for GraphQLDuplicatePriceKeyError instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withGraphQLDuplicatePriceKeyError
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
-