Class OrderFromCartDraftImpl

java.lang.Object
com.commercetools.api.models.order.OrderFromCartDraftImpl
All Implemented Interfaces:
OrderFromCartDraft, io.vrap.rmf.base.client.Draft<OrderFromCartDraft>, io.vrap.rmf.base.client.ModelBase

public class OrderFromCartDraftImpl extends Object implements OrderFromCartDraft, io.vrap.rmf.base.client.ModelBase
OrderFromCartDraft
  • Constructor Details

    • OrderFromCartDraftImpl

      public OrderFromCartDraftImpl()
      create empty instance
  • Method Details

    • getId

      @Deprecated public String getId()
      Deprecated.

      id of the Cart used to create the Order.

      Specified by:
      getId in interface OrderFromCartDraft
      Returns:
      id
    • getCart

      public CartResourceIdentifier getCart()

      ResourceIdentifier to the Cart from which the Order is created.

      This field is required, but is marked as optional for backwards compatibility reasons.

      Specified by:
      getCart in interface OrderFromCartDraft
      Returns:
      cart
    • getVersion

      public Long getVersion()

      version of the Cart from which the Order is created.

      Specified by:
      getVersion in interface OrderFromCartDraft
      Returns:
      version
    • getOrderNumber

      public String getOrderNumber()

      User-defined identifier for the Order that is unique across a Project. Once set, the value cannot be changed.

      Specified by:
      getOrderNumber in interface OrderFromCartDraft
      Returns:
      orderNumber
    • getPurchaseOrderNumber

      public String getPurchaseOrderNumber()

      User-defined identifier for a purchase Order.

      It is typically set by the Buyer and can be used with Quotes to track the purchase Order during the quote and order flow.

      Specified by:
      getPurchaseOrderNumber in interface OrderFromCartDraft
      Returns:
      purchaseOrderNumber
    • getPaymentState

      public PaymentState getPaymentState()

      Payment status for the Order.

      Specified by:
      getPaymentState in interface OrderFromCartDraft
      Returns:
      paymentState
    • getShipmentState

      public ShipmentState getShipmentState()

      Shipment status for the Order.

      Specified by:
      getShipmentState in interface OrderFromCartDraft
      Returns:
      shipmentState
    • getOrderState

      public OrderState getOrderState()

      Current status for the Order.

      Specified by:
      getOrderState in interface OrderFromCartDraft
      Returns:
      orderState
    • getState

      public StateResourceIdentifier getState()

      State for the Order in a custom workflow.

      Specified by:
      getState in interface OrderFromCartDraft
      Returns:
      state
    • getCustom

      public CustomFieldsDraft getCustom()

      Custom Fields for the Order. The Custom Fields' type must match the Custom Fields' type in the referenced Cart.

      • If empty, the Custom Fields on the referenced Cart are added to the Order automatically.
      • If specified, the Custom Fields are merged with the Custom Fields on the referenced Cart and added to the Order.
      Specified by:
      getCustom in interface OrderFromCartDraft
      Returns:
      custom
    • setId

      @Deprecated public void setId(String id)
      Deprecated.
      Description copied from interface: OrderFromCartDraft

      id of the Cart used to create the Order.

      Specified by:
      setId in interface OrderFromCartDraft
      Parameters:
      id - value to be set
    • setCart

      public void setCart(CartResourceIdentifier cart)
      Description copied from interface: OrderFromCartDraft

      ResourceIdentifier to the Cart from which the Order is created.

      This field is required, but is marked as optional for backwards compatibility reasons.

      Specified by:
      setCart in interface OrderFromCartDraft
      Parameters:
      cart - value to be set
    • setVersion

      public void setVersion(Long version)
      Description copied from interface: OrderFromCartDraft

      version of the Cart from which the Order is created.

      Specified by:
      setVersion in interface OrderFromCartDraft
      Parameters:
      version - value to be set
    • setOrderNumber

      public void setOrderNumber(String orderNumber)
      Description copied from interface: OrderFromCartDraft

      User-defined identifier for the Order that is unique across a Project. Once set, the value cannot be changed.

      Specified by:
      setOrderNumber in interface OrderFromCartDraft
      Parameters:
      orderNumber - value to be set
    • setPurchaseOrderNumber

      public void setPurchaseOrderNumber(String purchaseOrderNumber)
      Description copied from interface: OrderFromCartDraft

      User-defined identifier for a purchase Order.

      It is typically set by the Buyer and can be used with Quotes to track the purchase Order during the quote and order flow.

      Specified by:
      setPurchaseOrderNumber in interface OrderFromCartDraft
      Parameters:
      purchaseOrderNumber - value to be set
    • setPaymentState

      public void setPaymentState(PaymentState paymentState)
      Description copied from interface: OrderFromCartDraft

      Payment status for the Order.

      Specified by:
      setPaymentState in interface OrderFromCartDraft
      Parameters:
      paymentState - value to be set
    • setShipmentState

      public void setShipmentState(ShipmentState shipmentState)
      Description copied from interface: OrderFromCartDraft

      Shipment status for the Order.

      Specified by:
      setShipmentState in interface OrderFromCartDraft
      Parameters:
      shipmentState - value to be set
    • setOrderState

      public void setOrderState(OrderState orderState)
      Description copied from interface: OrderFromCartDraft

      Current status for the Order.

      Specified by:
      setOrderState in interface OrderFromCartDraft
      Parameters:
      orderState - value to be set
    • setState

      public void setState(StateResourceIdentifier state)
      Description copied from interface: OrderFromCartDraft

      State for the Order in a custom workflow.

      Specified by:
      setState in interface OrderFromCartDraft
      Parameters:
      state - value to be set
    • setCustom

      public void setCustom(CustomFieldsDraft custom)
      Description copied from interface: OrderFromCartDraft

      Custom Fields for the Order. The Custom Fields' type must match the Custom Fields' type in the referenced Cart.

      • If empty, the Custom Fields on the referenced Cart are added to the Order automatically.
      • If specified, the Custom Fields are merged with the Custom Fields on the referenced Cart and added to the Order.
      Specified by:
      setCustom in interface OrderFromCartDraft
      Parameters:
      custom - value to be set
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object