Class OrderLabelBuilder

java.lang.Object
com.commercetools.history.models.label.OrderLabelBuilder
All Implemented Interfaces:
Builder<OrderLabel>

public class OrderLabelBuilder extends Object implements Builder<OrderLabel>
OrderLabelBuilder
Example to create an instance using the builder pattern

     OrderLabel orderLabel = OrderLabel.builder()
             .customerEmail("{customerEmail}")
             .orderNumber("{orderNumber}")
             .build()
 
  • Constructor Details

    • OrderLabelBuilder

      public OrderLabelBuilder()
  • Method Details

    • customerEmail

      public OrderLabelBuilder customerEmail(String customerEmail)

      Email address of the Customer that the Order belongs to.

      Parameters:
      customerEmail - value to be set
      Returns:
      Builder
    • orderNumber

      public OrderLabelBuilder orderNumber(String orderNumber)

      User-defined unique identifier of the Order that is unique across a Project.

      Parameters:
      orderNumber - value to be set
      Returns:
      Builder
    • getCustomerEmail

      public String getCustomerEmail()

      Email address of the Customer that the Order belongs to.

      Returns:
      customerEmail
    • getOrderNumber

      public String getOrderNumber()

      User-defined unique identifier of the Order that is unique across a Project.

      Returns:
      orderNumber
    • build

      public OrderLabel build()
      builds OrderLabel with checking for non-null required values
      Specified by:
      build in interface Builder<OrderLabel>
      Returns:
      OrderLabel
    • buildUnchecked

      public OrderLabel buildUnchecked()
      builds OrderLabel without checking for non-null required values
      Returns:
      OrderLabel
    • of

      public static OrderLabelBuilder of()
      factory method for an instance of OrderLabelBuilder
      Returns:
      builder
    • of

      public static OrderLabelBuilder of(OrderLabel template)
      create builder for OrderLabel instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder