public class ConstraintValidatorManager extends Object
ConstraintValidator
instances.Constructor and Description |
---|
ConstraintValidatorManager(ConstraintValidatorFactory defaultConstraintValidatorFactory,
HibernateConstraintValidatorInitializationContext defaultConstraintValidatorInitializationContext)
Creates a new
ConstraintValidatorManager . |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
ConstraintValidatorFactory |
getDefaultConstraintValidatorFactory() |
HibernateConstraintValidatorInitializationContext |
getDefaultConstraintValidatorInitializationContext() |
<A extends Annotation> |
getInitializedValidator(Type validatedValueType,
ConstraintDescriptorImpl<A> descriptor,
ConstraintValidatorFactory constraintValidatorFactory,
HibernateConstraintValidatorInitializationContext initializationContext) |
int |
numberOfCachedConstraintValidatorInstances() |
public ConstraintValidatorManager(ConstraintValidatorFactory defaultConstraintValidatorFactory, HibernateConstraintValidatorInitializationContext defaultConstraintValidatorInitializationContext)
ConstraintValidatorManager
.defaultConstraintValidatorFactory
- the default validator factorydefaultConstraintValidatorInitializationContext
- the default initialization contextpublic <A extends Annotation> ConstraintValidator<A,?> getInitializedValidator(Type validatedValueType, ConstraintDescriptorImpl<A> descriptor, ConstraintValidatorFactory constraintValidatorFactory, HibernateConstraintValidatorInitializationContext initializationContext)
A
- the annotation typevalidatedValueType
- the type of the value to be validated. Cannot be null
.descriptor
- the constraint descriptor for which to get an initialized constraint validator. Cannot be null
constraintValidatorFactory
- constraint factory used to instantiate the constraint validator. Cannot be null
.initializationContext
- context used on constraint validator initializationnull
is returned if no matching constraint validator could be found.public void clear()
public ConstraintValidatorFactory getDefaultConstraintValidatorFactory()
public HibernateConstraintValidatorInitializationContext getDefaultConstraintValidatorInitializationContext()
public int numberOfCachedConstraintValidatorInstances()
Copyright © 2021 JBoss by Red Hat. All rights reserved.