Interface ProductChangeSlugAction

All Superinterfaces:
ProductUpdateAction, ResourceUpdateAction<ProductUpdateAction>

public interface ProductChangeSlugAction extends ProductUpdateAction

Produces the ProductSlugChanged Message.


Example to create an instance using the builder pattern

     ProductChangeSlugAction productChangeSlugAction = ProductChangeSlugAction.builder()
             .slug(slugBuilder -> slugBuilder)
             .build()
 
  • Field Details

  • Method Details

    • getSlug

      @NotNull @Valid @NotNull @Valid LocalizedString getSlug()

      Value to set. Must not be empty. A Product can have the same slug for different Locales, but it must be unique across the Project. Must match the pattern ^[A-Za-z0-9_-]{2,256}+$.

      Returns:
      slug
    • getStaged

      Boolean getStaged()

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

      Returns:
      staged
    • setSlug

      void setSlug(LocalizedString slug)

      Value to set. Must not be empty. A Product can have the same slug for different Locales, but it must be unique across the Project. Must match the pattern ^[A-Za-z0-9_-]{2,256}+$.

      Parameters:
      slug - value to be set
    • setStaged

      void setStaged(Boolean staged)

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

      Parameters:
      staged - value to be set
    • of

      factory method
      Returns:
      instance of ProductChangeSlugAction
    • of

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

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

      builder factory method for ProductChangeSlugAction
      Returns:
      builder
    • builder

      create builder for ProductChangeSlugAction instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withProductChangeSlugAction

      default <T> T withProductChangeSlugAction(Function<ProductChangeSlugAction,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<ProductChangeSlugAction> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference