Package org.apache.bval.jsr.util
Class AnnotationsManager
- java.lang.Object
 - 
- org.apache.bval.jsr.util.AnnotationsManager
 
 
- 
public class AnnotationsManager extends Object
Manages (constraint) annotations according to the BV spec.- Since:
 - 2.0
 
 
- 
- 
Constructor Summary
Constructors Constructor Description AnnotationsManager(ApacheValidatorFactory validatorFactory) 
- 
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description <A extends Annotation>
AnnotationProxyBuilder<A>buildProxyFor(A instance)<A extends Annotation>
AnnotationProxyBuilder<A>buildProxyFor(Class<A> type)static <T extends Annotation>
TgetAnnotation(AnnotatedElement e, Class<T> annotationClass)Annotation[]getComposingConstraints(Annotation a)Retrieve the composing constraints for the specified constraintAnnotation.static <T extends Annotation>
T[]getDeclaredAnnotationsByType(AnnotatedElement e, Class<T> annotationClass)static Annotation[]getDeclaredConstraints(Meta<?> meta)Accounts forConstraintmeta-annotation ANDRepeatableconstraint annotations.static booleanisAnnotationDirectlyPresent(AnnotatedElement e, Class<? extends Annotation> t)booleanisComposed(Annotation a)Learn whetherais composed.static Map<String,Object>readAttributes(Annotation a)<A extends Annotation>
Set<jakarta.validation.constraintvalidation.ValidationTarget>supportedTargets(Class<A> constraintType)Get the supported targets forconstraintType.voidvalidateConstraintDefinition(Class<? extends Annotation> type) 
 - 
 
- 
- 
Constructor Detail
- 
AnnotationsManager
public AnnotationsManager(ApacheValidatorFactory validatorFactory)
 
 - 
 
- 
Method Detail
- 
readAttributes
public static Map<String,Object> readAttributes(Annotation a)
 
- 
isAnnotationDirectlyPresent
public static boolean isAnnotationDirectlyPresent(AnnotatedElement e, Class<? extends Annotation> t)
 
- 
getAnnotation
public static <T extends Annotation> T getAnnotation(AnnotatedElement e, Class<T> annotationClass)
 
- 
getDeclaredAnnotationsByType
public static <T extends Annotation> T[] getDeclaredAnnotationsByType(AnnotatedElement e, Class<T> annotationClass)
 
- 
getDeclaredConstraints
public static Annotation[] getDeclaredConstraints(Meta<?> meta)
Accounts forConstraintmeta-annotation ANDRepeatableconstraint annotations.- Parameters:
 meta-- Returns:
 - Annotation[]
 
 
- 
validateConstraintDefinition
public void validateConstraintDefinition(Class<? extends Annotation> type)
 
- 
getComposingConstraints
public Annotation[] getComposingConstraints(Annotation a)
Retrieve the composing constraints for the specified constraintAnnotation.- Parameters:
 a-- Returns:
 Annotation[]
 
- 
isComposed
public boolean isComposed(Annotation a)
Learn whetherais composed.- Parameters:
 a-- Returns:
 boolean
 
- 
supportedTargets
public <A extends Annotation> Set<jakarta.validation.constraintvalidation.ValidationTarget> supportedTargets(Class<A> constraintType)
Get the supported targets forconstraintType.- Parameters:
 constraintType-- Returns:
 SetofValidationTarget
 
- 
buildProxyFor
public <A extends Annotation> AnnotationProxyBuilder<A> buildProxyFor(Class<A> type)
 
- 
buildProxyFor
public <A extends Annotation> AnnotationProxyBuilder<A> buildProxyFor(A instance)
 
 - 
 
 -