Interface MoneyOverflowError
- All Superinterfaces:
ErrorObject
Returned when a Money operation overflows the 64-bit integer range. See Money usage for more information.
Example to create an instance using the builder pattern
MoneyOverflowError moneyOverflowError = MoneyOverflowError.builder()
.message("{message}")
.build()
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic MoneyOverflowErrorBuilder
builder()
builder factory method for MoneyOverflowErrorstatic MoneyOverflowErrorBuilder
builder
(MoneyOverflowError template) create builder for MoneyOverflowError instancestatic MoneyOverflowError
deepCopy
(MoneyOverflowError template) factory method to create a deep copy of MoneyOverflowError@NotNull String
getCode()
Error identifier.@NotNull String
"A Money operation resulted in an overflow."
static MoneyOverflowError
of()
factory methodstatic MoneyOverflowError
of
(MoneyOverflowError template) factory method to create a shallow copy MoneyOverflowErrorvoid
setMessage
(String message) "A Money operation resulted in an overflow."
static com.fasterxml.jackson.core.type.TypeReference<MoneyOverflowError>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withMoneyOverflowError
(Function<MoneyOverflowError, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.error.ErrorObject
setValue, values, withErrorObject
-
Field Details
-
MONEY_OVERFLOW
discriminator value for MoneyOverflowError- See Also:
-
-
Method Details
-
getCode
Description copied from interface:ErrorObject
Error identifier.
- Specified by:
getCode
in interfaceErrorObject
- Returns:
- code
-
getMessage
"A Money operation resulted in an overflow."
- Specified by:
getMessage
in interfaceErrorObject
- Returns:
- message
-
setMessage
"A Money operation resulted in an overflow."
- Specified by:
setMessage
in interfaceErrorObject
- Parameters:
message
- value to be set
-
of
factory method- Returns:
- instance of MoneyOverflowError
-
of
factory method to create a shallow copy MoneyOverflowError- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of MoneyOverflowError- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for MoneyOverflowError- Returns:
- builder
-
builder
create builder for MoneyOverflowError instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withMoneyOverflowError
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
-