Interface CartState

All Superinterfaces:
JsonEnum
All Known Implementing Classes:
CartState.CartStateEnum

public interface CartState extends JsonEnum

Indicates the current status of a Cart.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static enum 
    possible values of CartState
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final CartState
    The default state where a Cart can be updated and ordered.
    static final CartState
    A Cart is frozen.
    static final CartState
    An anonymous Cart was merged into a Customer's Cart on sign-in, and no further operations are allowed on the Cart.
    static final CartState
    A Cart was ordered, and no further operations are allowed on the Cart.
  • Method Summary

    Modifier and Type
    Method
    Description
    static CartState
    factory method for a enum value of CartState if no enum has been found an anonymous instance will be created
    method to find enum using the JSON value
    the JSON value
    the enum value
    convert value to string
    static CartState[]
    possible enum values
  • Field Details

    • ACTIVE

      static final CartState ACTIVE

      The default state where a Cart can be updated and ordered.

    • MERGED

      static final CartState MERGED

      An anonymous Cart was merged into a Customer's Cart on sign-in, and no further operations are allowed on the Cart.

    • ORDERED

      static final CartState ORDERED

      A Cart was ordered, and no further operations are allowed on the Cart.

    • FROZEN

      static final CartState FROZEN

      A Cart is frozen. Update actions that can change the price of (Custom) Line Items are not allowed.

      • Add LineItem
      • Change LineItem Quantity
      • Remove LineItem
      • Set LineItem DistributionChannel
      • Set LineItem SupplyChannel
      • Add CustomLineItem
      • Change CustomLineItem Quantity
      • Remove CustomLineItem
      • Change TaxMode
      • Set LineItem Price
      • Set LineItem TotalPrice
  • Method Details

    • getJsonName

      String getJsonName()
      the JSON value
      Specified by:
      getJsonName in interface JsonEnum
      Returns:
      json value
    • name

      String name()
      the enum value
      Specified by:
      name in interface JsonEnum
      Returns:
      name
    • toString

      String toString()
      convert value to string
      Specified by:
      toString in interface JsonEnum
      Overrides:
      toString in class Object
      Returns:
      string representation
    • findEnum

      static CartState findEnum(String value)
      factory method for a enum value of CartState if no enum has been found an anonymous instance will be created
      Parameters:
      value - the enum value to be wrapped
      Returns:
      enum instance
    • findEnumViaJsonName

      static Optional<CartState> findEnumViaJsonName(String jsonName)
      method to find enum using the JSON value
      Parameters:
      jsonName - the json value to be wrapped
      Returns:
      optional of enum instance
    • values

      static CartState[] values()
      possible enum values
      Returns:
      array of possible enum values