spring-framework / org.springframework.validation.beanvalidation / CustomValidatorBean

CustomValidatorBean

open class CustomValidatorBean : SpringValidatorAdapter, Validator, InitializingBean

Configurable bean class that exposes a specific JSR-303 Validator through its original interface as well as through the Spring org.springframework.validation.Validator interface.

Author
Juergen Hoeller

Since
3.0

Constructors

<init>

CustomValidatorBean()

Configurable bean class that exposes a specific JSR-303 Validator through its original interface as well as through the Spring org.springframework.validation.Validator interface.

Functions

afterPropertiesSet

open fun afterPropertiesSet(): Unit

setMessageInterpolator

open fun setMessageInterpolator(messageInterpolator: MessageInterpolator): Unit

Specify a custom MessageInterpolator to use for this Validator.

setTraversableResolver

open fun setTraversableResolver(traversableResolver: TraversableResolver): Unit

Specify a custom TraversableResolver to use for this Validator.

setValidatorFactory

open fun setValidatorFactory(validatorFactory: ValidatorFactory): Unit

Set the ValidatorFactory to obtain the target Validator from.

Default is javax.validation.Validation#buildDefaultValidatorFactory().