Class OutOfStockErrorImpl
java.lang.Object
com.commercetools.api.models.error.OutOfStockErrorImpl
- All Implemented Interfaces:
ErrorObject,OutOfStockError,io.vrap.rmf.base.client.ModelBase
public class OutOfStockErrorImpl
extends Object
implements OutOfStockError, io.vrap.rmf.base.client.ModelBase
Returned when some of the Line Items are out of stock at the time of placing an Order.
The error is returned as a failed response to:
- Create Order from Cart, Create Order in Store from Cart, Create Order from Quote, and Create Order by Import requests on Orders.
- Create Order from Cart, Create Order in Store from Cart, and Create Order from Quote requests on My Orders.
- Create Order from Cart in BusinessUnit and Create Order from Quote in BusinessUnit requests on Associate Orders.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vrap.rmf.base.client.ModelBase
io.vrap.rmf.base.client.ModelBase.FilteredRecursiveToStringStyle -
Field Summary
Fields inherited from interface com.commercetools.api.models.error.OutOfStockError
OUT_OF_STOCK -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopyDeep()booleangetCode()Error identifier.Unique identifiers of the Line Items that are out of stock."Some line items are out of stock at the time of placing the order: $itemSku."getSkus()SKUs of the Line Items that are out of stock.inthashCode()voidsetLineItems(String... lineItems) Unique identifiers of the Line Items that are out of stock.voidsetLineItems(List<String> lineItems) Unique identifiers of the Line Items that are out of stock.voidsetMessage(String message) "Some line items are out of stock at the time of placing the order: $itemSku."voidSKUs of the Line Items that are out of stock.voidSKUs of the Line Items that are out of stock.voidError-specific additional fields.toString()values()Error-specific additional fields.Methods inherited from interface com.commercetools.api.models.error.ErrorObject
withErrorObjectMethods inherited from interface io.vrap.rmf.base.client.ModelBase
reflectionString, reflectionStringMethods inherited from interface com.commercetools.api.models.error.OutOfStockError
withOutOfStockError
-
Constructor Details
-
OutOfStockErrorImpl
public OutOfStockErrorImpl()create empty instance
-
-
Method Details
-
getCode
Description copied from interface:ErrorObjectError identifier.
- Specified by:
getCodein interfaceErrorObject- Specified by:
getCodein interfaceOutOfStockError- Returns:
- code
-
getMessage
"Some line items are out of stock at the time of placing the order: $itemSku."- Specified by:
getMessagein interfaceErrorObject- Specified by:
getMessagein interfaceOutOfStockError- Returns:
- message
-
values
Error-specific additional fields.
- Specified by:
valuesin interfaceErrorObject- Returns:
- map of the pattern property values
-
getLineItems
Unique identifiers of the Line Items that are out of stock.
- Specified by:
getLineItemsin interfaceOutOfStockError- Returns:
- lineItems
-
getSkus
SKUs of the Line Items that are out of stock.
- Specified by:
getSkusin interfaceOutOfStockError- Returns:
- skus
-
setMessage
Description copied from interface:OutOfStockError"Some line items are out of stock at the time of placing the order: $itemSku."- Specified by:
setMessagein interfaceErrorObject- Specified by:
setMessagein interfaceOutOfStockError- Parameters:
message- value to be set
-
setValue
Description copied from interface:ErrorObjectError-specific additional fields.
- Specified by:
setValuein interfaceErrorObject- Parameters:
key- property namevalue- property value
-
setLineItems
Description copied from interface:OutOfStockErrorUnique identifiers of the Line Items that are out of stock.
- Specified by:
setLineItemsin interfaceOutOfStockError- Parameters:
lineItems- values to be set
-
setLineItems
Description copied from interface:OutOfStockErrorUnique identifiers of the Line Items that are out of stock.
- Specified by:
setLineItemsin interfaceOutOfStockError- Parameters:
lineItems- values to be set
-
setSkus
Description copied from interface:OutOfStockErrorSKUs of the Line Items that are out of stock.
- Specified by:
setSkusin interfaceOutOfStockError- Parameters:
skus- values to be set
-
setSkus
Description copied from interface:OutOfStockErrorSKUs of the Line Items that are out of stock.
- Specified by:
setSkusin interfaceOutOfStockError- Parameters:
skus- values to be set
-
equals
-
hashCode
public int hashCode() -
toString
-
copyDeep
- Specified by:
copyDeepin interfaceErrorObject- Specified by:
copyDeepin interfaceOutOfStockError
-