Class Validator
java.lang.Object
org.robolectric.annotation.processing.validator.Validator
- All Implemented Interfaces:
ElementVisitor<Void,Element>
- Direct Known Subclasses:
FoundOnImplementsValidator
,ImplementsValidator
public abstract class Validator extends Object implements ElementVisitor<Void,Element>
Base class for validators.
-
Field Summary
Fields Modifier and Type Field Description protected TypeElement
annotationType
protected AnnotationMirror
currentAnnotation
protected Element
currentElement
protected Elements
elements
protected Helpers
helpers
protected Messager
messager
protected RobolectricModel.Builder
modelBuilder
protected Types
types
-
Constructor Summary
Constructors Constructor Description Validator(RobolectricModel.Builder modelBuilder, ProcessingEnvironment env, String annotationType)
-
Method Summary
Modifier and Type Method Description protected void
error(String msg)
protected void
error(String msg, AnnotationValue av)
TypeElement
getAnnotationType()
protected AnnotationMirror
getCurrentAnnotation()
void
init(Element e, Element p)
protected void
message(Diagnostic.Kind severity, String msg)
protected void
message(Diagnostic.Kind severity, String msg, AnnotationValue av)
Void
visit(Element e)
Void
visit(Element e, Element p)
Void
visitExecutable(ExecutableElement e, Element p)
Void
visitPackage(PackageElement e, Element p)
Void
visitType(TypeElement e, Element p)
Void
visitTypeParameter(TypeParameterElement e, Element p)
Void
visitUnknown(Element e, Element p)
Void
visitVariable(VariableElement e, Element p)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface javax.lang.model.element.ElementVisitor
visitModule, visitRecordComponent
-
Field Details
-
Constructor Details
-
Validator
public Validator(RobolectricModel.Builder modelBuilder, ProcessingEnvironment env, String annotationType)
-
-
Method Details
-
getCurrentAnnotation
-
message
-
message
-
error
-
error
-
init
-
getAnnotationType
-
visit
- Specified by:
visit
in interfaceElementVisitor<Void,Element>
-
visit
- Specified by:
visit
in interfaceElementVisitor<Void,Element>
-
visitPackage
- Specified by:
visitPackage
in interfaceElementVisitor<Void,Element>
-
visitType
- Specified by:
visitType
in interfaceElementVisitor<Void,Element>
-
visitVariable
- Specified by:
visitVariable
in interfaceElementVisitor<Void,Element>
-
visitExecutable
- Specified by:
visitExecutable
in interfaceElementVisitor<Void,Element>
-
visitTypeParameter
- Specified by:
visitTypeParameter
in interfaceElementVisitor<Void,Element>
-
visitUnknown
- Specified by:
visitUnknown
in interfaceElementVisitor<Void,Element>
-