Class PromotionalProductValidator

java.lang.Object
com.broadleafcommerce.catalog.service.validation.PromotionalProductValidator
All Implemented Interfaces:
com.broadleafcommerce.data.tracking.core.mapping.validation.EntityValidator

public class PromotionalProductValidator extends Object implements com.broadleafcommerce.data.tracking.core.mapping.validation.EntityValidator
Validations for PromotionalProduct.
Author:
Samarth Dhruva (samarthd)
  • Constructor Details

    • PromotionalProductValidator

      public PromotionalProductValidator()
  • Method Details

    • supports

      public boolean supports(Class<?> serviceClass, com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
      Specified by:
      supports in interface com.broadleafcommerce.data.tracking.core.mapping.validation.EntityValidator
    • validate

      public void validate(@NonNull Object businessInstance, @NonNull org.springframework.validation.Errors errors, com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
      Specified by:
      validate in interface com.broadleafcommerce.data.tracking.core.mapping.validation.EntityValidator
    • validateType

      protected void validateType(PromotionalProduct promotionalProduct, org.springframework.validation.Errors errors)
    • validateProduct

      protected void validateProduct(PromotionalProduct promotionalProduct, org.springframework.validation.Errors errors)
    • validateRelatedProduct

      protected void validateRelatedProduct(PromotionalProduct promotionalProduct, org.springframework.validation.Errors errors)