Package org.hibernate.validator.ap
Class ConstraintValidationProcessor
java.lang.Object
javax.annotation.processing.AbstractProcessor
org.hibernate.validator.ap.ConstraintValidationProcessor
- All Implemented Interfaces:
Processor
@SupportedAnnotationTypes("*")
@SupportedOptions({"diagnosticKind","verbose","methodConstraintsSupported"})
public class ConstraintValidationProcessor
extends AbstractProcessor
An annotation processor for checking Bean Validation constraints.
The processor supports the following options:
diagnosticKind: the severity with which any occurred problems shall be reported. Must be given in form of the string representation of a value fromDiagnostic.Kind, e.g. "diagnosticKind=WARNING". Default is Kind.ERROR.verbose: whether a verbose output shall be created or not. Must be given as String parsable byBoolean.parseBoolean(java.lang.String). Default isfalse.methodConstraintsSupported: Whether constraints at other methods than JavaBeans getter methods may be annotated with constraints or not. Must be given as String parsable byBoolean.parseBoolean(java.lang.String). Can be set tofalsein order to allow only getter based property constraints but not method level constraints as supported by Hibernate Validator. Default istrue.
- Author:
- Hardy Ferentschik, Gunnar Morling
-
Field Summary
Fields inherited from class javax.annotation.processing.AbstractProcessor
processingEnv -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidinit(ProcessingEnvironment processingEnv) booleanprocess(Set<? extends TypeElement> annotations, RoundEnvironment roundEnvironment) Methods inherited from class javax.annotation.processing.AbstractProcessor
getCompletions, getSupportedAnnotationTypes, getSupportedOptions, isInitialized
-
Constructor Details
-
ConstraintValidationProcessor
public ConstraintValidationProcessor()
-
-
Method Details
-
init
- Specified by:
initin interfaceProcessor- Overrides:
initin classAbstractProcessor
-
getSupportedSourceVersion
- Specified by:
getSupportedSourceVersionin interfaceProcessor- Overrides:
getSupportedSourceVersionin classAbstractProcessor
-
process
- Specified by:
processin interfaceProcessor- Specified by:
processin classAbstractProcessor
-