Class ShippingMethodLabelBuilder

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

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

     ShippingMethodLabel shippingMethodLabel = ShippingMethodLabel.builder()
             .name("{name}")
             .build()
 
  • Constructor Details

    • ShippingMethodLabelBuilder

      public ShippingMethodLabelBuilder()
  • Method Details

    • key

      public ShippingMethodLabelBuilder key(@Nullable String key)

      User-defined unique identifier of the Shipping Method.

      Parameters:
      key - value to be set
      Returns:
      Builder
    • name

      public ShippingMethodLabelBuilder name(String name)

      Unique name identifier of the Shipping Method.

      Parameters:
      name - value to be set
      Returns:
      Builder
    • getKey

      @Nullable public String getKey()

      User-defined unique identifier of the Shipping Method.

      Returns:
      key
    • getName

      public String getName()

      Unique name identifier of the Shipping Method.

      Returns:
      name
    • build

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

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

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

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