Class BooleanFieldBuilder

java.lang.Object
com.commercetools.importapi.models.customfields.BooleanFieldBuilder
All Implemented Interfaces:
Builder<BooleanField>

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

     BooleanField booleanField = BooleanField.builder()
             .value(true)
             .build()
 
  • Constructor Details

    • BooleanFieldBuilder

      public BooleanFieldBuilder()
  • Method Details

    • value

      public BooleanFieldBuilder value(Boolean value)
      set the value to the value
      Parameters:
      value - value to be set
      Returns:
      Builder
    • getValue

      public Boolean getValue()
      value of value}
      Returns:
      value
    • build

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

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

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

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