Interface InvalidOperationError
- All Superinterfaces:
ErrorObject
Returned when the resources involved in the request are not in a valid state for the operation.
The client application should validate the constraints described in the error message before sending the request.
Example to create an instance using the builder pattern
InvalidOperationError invalidOperationError = InvalidOperationError.builder()
.message("{message}")
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringdiscriminator value for InvalidOperationError -
Method Summary
Modifier and TypeMethodDescriptionstatic InvalidOperationErrorBuilderbuilder()builder factory method for InvalidOperationErrorstatic InvalidOperationErrorBuilderbuilder(InvalidOperationError template) create builder for InvalidOperationError instancecopyDeep()static InvalidOperationErrordeepCopy(InvalidOperationError template) factory method to create a deep copy of InvalidOperationError@NotNull StringgetCode()Error identifier.@NotNull StringPlain text description of the error.static InvalidOperationErrorof()factory methodstatic InvalidOperationErrorof(InvalidOperationError template) factory method to create a shallow copy InvalidOperationErrorvoidsetMessage(String message) Plain text description of the error.static com.fasterxml.jackson.core.type.TypeReference<InvalidOperationError>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map functionMethods inherited from interface com.commercetools.api.models.error.ErrorObject
setValue, values, withErrorObject
-
Field Details
-
INVALID_OPERATION
discriminator value for InvalidOperationError- See Also:
-
-
Method Details
-
getCode
Description copied from interface:ErrorObjectError identifier.
- Specified by:
getCodein interfaceErrorObject- Returns:
- code
-
getMessage
Plain text description of the error.
- Specified by:
getMessagein interfaceErrorObject- Returns:
- message
-
setMessage
Plain text description of the error.
- Specified by:
setMessagein interfaceErrorObject- Parameters:
message- value to be set
-
of
factory method- Returns:
- instance of InvalidOperationError
-
of
factory method to create a shallow copy InvalidOperationError- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
InvalidOperationError copyDeep()- Specified by:
copyDeepin interfaceErrorObject
-
deepCopy
factory method to create a deep copy of InvalidOperationError- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for InvalidOperationError- Returns:
- builder
-
builder
create builder for InvalidOperationError instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withInvalidOperationError
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
-