Class ChangeLabelChangeBuilder

java.lang.Object
com.commercetools.history.models.change.ChangeLabelChangeBuilder
All Implemented Interfaces:
io.vrap.rmf.base.client.Builder<ChangeLabelChange>

public class ChangeLabelChangeBuilder extends Object implements io.vrap.rmf.base.client.Builder<ChangeLabelChange>
ChangeLabelChangeBuilder
Example to create an instance using the builder pattern

     ChangeLabelChange changeLabelChange = ChangeLabelChange.builder()
             .change("{change}")
             .previousValue(previousValueBuilder -> previousValueBuilder)
             .nextValue(nextValueBuilder -> nextValueBuilder)
             .fieldName("{fieldName}")
             .attributeName("{attributeName}")
             .build()
 
  • Constructor Details

    • ChangeLabelChangeBuilder

      public ChangeLabelChangeBuilder()
  • Method Details

    • change

      public ChangeLabelChangeBuilder change(String change)
      set the value to the change
      Parameters:
      change - value to be set
      Returns:
      Builder
    • previousValue

      Value before the change.

      Parameters:
      builder - function to build the previousValue value
      Returns:
      Builder
    • withPreviousValue

      Value before the change.

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

      public ChangeLabelChangeBuilder previousValue(LocalizedString previousValue)

      Value before the change.

      Parameters:
      previousValue - value to be set
      Returns:
      Builder
    • nextValue

      Value after the change.

      Parameters:
      builder - function to build the nextValue value
      Returns:
      Builder
    • withNextValue

      Value after the change.

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

      public ChangeLabelChangeBuilder nextValue(LocalizedString nextValue)

      Value after the change.

      Parameters:
      nextValue - value to be set
      Returns:
      Builder
    • fieldName

      public ChangeLabelChangeBuilder fieldName(String fieldName)

      Name of the updated FieldDefinition; only present on changes to Types).

      Parameters:
      fieldName - value to be set
      Returns:
      Builder
    • attributeName

      public ChangeLabelChangeBuilder attributeName(String attributeName)

      Name of the updated AttributeDefinition; only present on changes to Product Types.

      Parameters:
      attributeName - value to be set
      Returns:
      Builder
    • getChange

      public String getChange()
      value of change}
      Returns:
      change
    • getPreviousValue

      public LocalizedString getPreviousValue()

      Value before the change.

      Returns:
      previousValue
    • getNextValue

      public LocalizedString getNextValue()

      Value after the change.

      Returns:
      nextValue
    • getFieldName

      public String getFieldName()

      Name of the updated FieldDefinition; only present on changes to Types).

      Returns:
      fieldName
    • getAttributeName

      public String getAttributeName()

      Name of the updated AttributeDefinition; only present on changes to Product Types.

      Returns:
      attributeName
    • build

      public ChangeLabelChange build()
      builds ChangeLabelChange with checking for non-null required values
      Specified by:
      build in interface io.vrap.rmf.base.client.Builder<ChangeLabelChange>
      Returns:
      ChangeLabelChange
    • buildUnchecked

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

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

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