Class CustomFieldSetTypeBuilder

java.lang.Object
com.commercetools.importapi.models.types.CustomFieldSetTypeBuilder
All Implemented Interfaces:
Builder<CustomFieldSetType>

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

     CustomFieldSetType customFieldSetType = CustomFieldSetType.builder()
             .elementType(elementTypeBuilder -> elementTypeBuilder)
             .build()
 
  • Constructor Details

    • CustomFieldSetTypeBuilder

      public CustomFieldSetTypeBuilder()
  • Method Details

    • elementType

      public CustomFieldSetTypeBuilder elementType(FieldType elementType)

      Field type of the elements in the set.

      Parameters:
      elementType - value to be set
      Returns:
      Builder
    • elementType

      public CustomFieldSetTypeBuilder elementType(Function<FieldTypeBuilder,Builder<? extends FieldType>> builder)

      Field type of the elements in the set.

      Parameters:
      builder - function to build the elementType value
      Returns:
      Builder
    • getElementType

      public FieldType getElementType()

      Field type of the elements in the set.

      Returns:
      elementType
    • build

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

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

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

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