public class DefaultForTypeAnnotator extends TypeAnnotator
DefaultFor; it is designed to be used in a ListTypeAnnotator constructed in
GenericAnnotatedTypeFactory.createTypeAnnotator() ()}
DefaultForTypeAnnotator traverses types deeply.
This class takes care of two of the attributes of DefaultFor; the others are handled
in QualifierDefaults.
ListTypeAnnotatortypeFactoryvisitedNodes| Constructor and Description |
|---|
DefaultForTypeAnnotator(AnnotatedTypeFactory typeFactory)
Creates a
DefaultForTypeAnnotator from the given checker, using that checker to
determine the annotations that are in the type hierarchy. |
| Modifier and Type | Method and Description |
|---|---|
void |
addAtmClass(java.lang.Class<? extends AnnotatedTypeMirror> typeClass,
javax.lang.model.element.AnnotationMirror theQual)
Add default qualifier,
theQual, for the given AnnotatedTypeMirror class. |
DefaultForTypeAnnotator |
addStandardDefaults()
Adds standard rules.
|
void |
addTypeKind(javax.lang.model.type.TypeKind typeKind,
javax.lang.model.element.AnnotationMirror theQual)
Add default qualifier,
theQual, for the given TypeKind. |
void |
addTypes(java.lang.Class<?> clazz,
javax.lang.model.element.AnnotationMirror theQual)
Add default qualifier,
theQual, for the given type. |
protected java.lang.Void |
scan(AnnotatedTypeMirror type,
java.lang.Void p)
Scan
type by calling type.accept(this, p); this method may be overridden by
subclasses. |
visitExecutablereduce, reset, scan, scanAndReduce, scanAndReduce, visit, visit, visitArray, visitDeclared, visitIntersection, visitNoType, visitNull, visitPrimitive, visitTypeVariable, visitUnion, visitWildcardpublic DefaultForTypeAnnotator(AnnotatedTypeFactory typeFactory)
DefaultForTypeAnnotator from the given checker, using that checker to
determine the annotations that are in the type hierarchy.public void addTypeKind(javax.lang.model.type.TypeKind typeKind,
javax.lang.model.element.AnnotationMirror theQual)
theQual, for the given TypeKind.public void addAtmClass(java.lang.Class<? extends AnnotatedTypeMirror> typeClass, javax.lang.model.element.AnnotationMirror theQual)
theQual, for the given AnnotatedTypeMirror class.public void addTypes(java.lang.Class<?> clazz,
javax.lang.model.element.AnnotationMirror theQual)
theQual, for the given type.protected java.lang.Void scan(AnnotatedTypeMirror type, java.lang.Void p)
AnnotatedTypeScannertype by calling type.accept(this, p); this method may be overridden by
subclasses.scan in class AnnotatedTypeScanner<java.lang.Void,java.lang.Void>type - type to scanp - the parameter to usetypepublic DefaultForTypeAnnotator addStandardDefaults()
LiteralTreeAnnotator.addStandardLiteralQualifiers().