Interface CartSetBusinessUnitAction

All Superinterfaces:
CartUpdateAction, ResourceUpdateAction<CartUpdateAction>

public interface CartSetBusinessUnitAction extends CartUpdateAction

Updates the Business Unit on the Cart. The Cart must have an existing Business Unit assigned already.


Example to create an instance using the builder pattern

     CartSetBusinessUnitAction cartSetBusinessUnitAction = CartSetBusinessUnitAction.builder()
             .businessUnit(businessUnitBuilder -> businessUnitBuilder)
             .build()
 
  • Field Details

    • SET_BUSINESS_UNIT

      static final String SET_BUSINESS_UNIT
      discriminator value for CartSetBusinessUnitAction
      See Also:
  • Method Details

    • getBusinessUnit

      @NotNull @Valid @NotNull @Valid BusinessUnitResourceIdentifier getBusinessUnit()

      New Business Unit to assign to the Cart, which must have access to the Store that is set on the Cart.

      Returns:
      businessUnit
    • setBusinessUnit

      void setBusinessUnit(BusinessUnitResourceIdentifier businessUnit)

      New Business Unit to assign to the Cart, which must have access to the Store that is set on the Cart.

      Parameters:
      businessUnit - value to be set
    • of

      factory method
      Returns:
      instance of CartSetBusinessUnitAction
    • of

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

      factory method to create a deep copy of CartSetBusinessUnitAction
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      builder factory method for CartSetBusinessUnitAction
      Returns:
      builder
    • builder

      create builder for CartSetBusinessUnitAction instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withCartSetBusinessUnitAction

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

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