Class AttributeReferenceBuilder

java.lang.Object
com.commercetools.api.models.attribute_group.AttributeReferenceBuilder
All Implemented Interfaces:
Builder<AttributeReference>

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

     AttributeReference attributeReference = AttributeReference.builder()
             .key("{key}")
             .build()
 
  • Constructor Details

    • AttributeReferenceBuilder

      public AttributeReferenceBuilder()
  • Method Details

    • key

      The Attribute's name as given in its AttributeDefinition.

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

      public String getKey()

      The Attribute's name as given in its AttributeDefinition.

      Returns:
      key
    • build

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

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

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

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