Interface VariantSetAttributesAction

All Superinterfaces:
VariantUpdateAction

public interface VariantSetAttributesAction extends VariantUpdateAction

Sets the attributes of the Variant. Existing attributes will be replaced with the new ones.


Example to create an instance using the builder pattern

     VariantSetAttributesAction variantSetAttributesAction = VariantSetAttributesAction.builder()
             .plusAttributes(attributesBuilder -> attributesBuilder)
             .build()
 
  • Field Details

    • SET_ATTRIBUTES

      static final String SET_ATTRIBUTES
      discriminator value for VariantSetAttributesAction
      See Also:
  • Method Details

    • getAttributes

      @NotNull @Valid @NotNull @Valid List<Attribute> getAttributes()

      Attributes to set for the Variant according to the respective AttributeDefinition.

      Returns:
      attributes
    • getStaged

      Boolean getStaged()

      If true, only the staged attributes are updated. If false, both the current and staged attributes are updated.

      Returns:
      staged
    • setAttributes

      void setAttributes(Attribute... attributes)

      Attributes to set for the Variant according to the respective AttributeDefinition.

      Parameters:
      attributes - values to be set
    • setAttributes

      void setAttributes(List<Attribute> attributes)

      Attributes to set for the Variant according to the respective AttributeDefinition.

      Parameters:
      attributes - values to be set
    • setStaged

      void setStaged(Boolean staged)

      If true, only the staged attributes are updated. If false, both the current and staged attributes are updated.

      Parameters:
      staged - value to be set
    • of

      factory method
      Returns:
      instance of VariantSetAttributesAction
    • of

      factory method to create a shallow copy VariantSetAttributesAction
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • copyDeep

      Specified by:
      copyDeep in interface VariantUpdateAction
    • deepCopy

      @Nullable static VariantSetAttributesAction deepCopy(@Nullable VariantSetAttributesAction template)
      factory method to create a deep copy of VariantSetAttributesAction
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      builder factory method for VariantSetAttributesAction
      Returns:
      builder
    • builder

      create builder for VariantSetAttributesAction instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withVariantSetAttributesAction

      default <T> T withVariantSetAttributesAction(Function<VariantSetAttributesAction,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static tools.jackson.core.type.TypeReference<VariantSetAttributesAction> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference