Class ProductPriceKeySetMessagePayloadBuilder

java.lang.Object
com.commercetools.api.models.message.ProductPriceKeySetMessagePayloadBuilder
All Implemented Interfaces:
Builder<ProductPriceKeySetMessagePayload>

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

     ProductPriceKeySetMessagePayload productPriceKeySetMessagePayload = ProductPriceKeySetMessagePayload.builder()
             .variantId(0.3)
             .staged(true)
             .build()
 
  • Constructor Details

    • ProductPriceKeySetMessagePayloadBuilder

      public ProductPriceKeySetMessagePayloadBuilder()
  • Method Details

    • variantId

      public ProductPriceKeySetMessagePayloadBuilder variantId(Long variantId)
      set the value to the variantId
      Parameters:
      variantId - value to be set
      Returns:
      Builder
    • priceId

      public ProductPriceKeySetMessagePayloadBuilder priceId(@Nullable String priceId)

      Unique identifier of the Price.

      Parameters:
      priceId - value to be set
      Returns:
      Builder
    • oldKey

      public ProductPriceKeySetMessagePayloadBuilder oldKey(@Nullable String oldKey)

      key value of the Price before the Set Price Key update action.

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

      public ProductPriceKeySetMessagePayloadBuilder key(@Nullable String key)

      key value of the Price after the Set Price Key update action.

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

      Whether the update was only applied to the staged Product Projection.

      Parameters:
      staged - value to be set
      Returns:
      Builder
    • getVariantId

      public Long getVariantId()
      value of variantId}
      Returns:
      variantId
    • getPriceId

      @Nullable public String getPriceId()

      Unique identifier of the Price.

      Returns:
      priceId
    • getOldKey

      @Nullable public String getOldKey()

      key value of the Price before the Set Price Key update action.

      Returns:
      oldKey
    • getKey

      @Nullable public String getKey()

      key value of the Price after the Set Price Key update action.

      Returns:
      key
    • getStaged

      public Boolean getStaged()

      Whether the update was only applied to the staged Product Projection.

      Returns:
      staged
    • build

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

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

      factory method for an instance of ProductPriceKeySetMessagePayloadBuilder
      Returns:
      builder
    • of

      create builder for ProductPriceKeySetMessagePayload instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder