Class DefaultFacadeValidationService

java.lang.Object
de.hybris.platform.cmsfacades.common.validator.impl.DefaultFacadeValidationService
All Implemented Interfaces:
FacadeValidationService

public class DefaultFacadeValidationService extends Object implements FacadeValidationService
Default implementation of a facade level validation service. This service will create a new instance of the Errors, ensure that the given validator can support the object to be validated, then perform the validation.

If any validation errors were found, then a ValidationException is thrown.

  • Constructor Details

    • DefaultFacadeValidationService

      public DefaultFacadeValidationService()
  • Method Details

    • validate

      public void validate(org.springframework.validation.Validator validator, Object validatee) throws ValidationException
      Description copied from interface: FacadeValidationService
      Validate the given DTO.
      Specified by:
      validate in interface FacadeValidationService
      Parameters:
      validator - - the validator to use for the validation
      validatee - - the object being validated
      Throws:
      ValidationException - when validation errors were found
    • validate

      public void validate(org.springframework.validation.Validator validator, Object validatee, Object bindingObject) throws ValidationException
      Description copied from interface: FacadeValidationService
      Validate the given DTO.
      Specified by:
      validate in interface FacadeValidationService
      Parameters:
      validator - - the validator to use for the validation
      validatee - - the object being validated
      bindingObject - - the object to use for binding the field errors
      Throws:
      ValidationException - when validation errors were found
    • validateInternal

      protected void validateInternal(org.springframework.validation.Validator validator, Object validatee, org.springframework.validation.Errors errors) throws ValidationException
      Validate the object using the provided binded errors
      Parameters:
      validator -
      validatee -
      errors -
      Throws:
      ValidationException
    • getValidatorErrorFactory

      protected ErrorFactory getValidatorErrorFactory()
    • setValidatorErrorFactory

      public void setValidatorErrorFactory(ErrorFactory validatorErrorFactory)