Module io.avaje.validation
Package io.avaje.validation.adapter
Interface ValidationContext.AnnotationFactory
- Enclosing interface:
ValidationContext
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Factory for creating an Annotation Adapter for a given annotation.
-
Method Summary
Modifier and TypeMethodDescriptioncreate(Class<? extends Annotation> annotationType, ValidationContext ctx, Set<Class<?>> groups, Map<String, Object> attributes) Create and return a ValidationAdapter given the type and annotations or return null.
-
Method Details
-
create
ValidationAdapter<?> create(Class<? extends Annotation> annotationType, ValidationContext ctx, Set<Class<?>> groups, Map<String, Object> attributes) Create and return a ValidationAdapter given the type and annotations or return null. Returning null means that the adapter could be created by another factory.- Parameters:
annotationType- The annotation type for which the adapter is being createdctx- The validation contextgroups- The validation groups associated with the annotationattributes- The attributes associated with the annotation- Returns:
- The created validation adapter or null if not applicable
-