Package com.google.auto.common
Class SuperficialValidation
java.lang.Object
com.google.auto.common.SuperficialValidation
A utility class that traverses
Element
instances and ensures that all type information
is present and resolvable.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final ElementVisitor<Boolean,
Void> private static final TypeVisitor<Boolean,
Void> private static final AnnotationValueVisitor<Boolean,
TypeMirror> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static boolean
private static boolean
validateAnnotation
(AnnotationMirror annotationMirror) private static boolean
validateAnnotations
(Iterable<? extends AnnotationMirror> annotationMirrors) private static boolean
validateAnnotationValue
(AnnotationValue annotationValue, TypeMirror expectedType) private static boolean
validateAnnotationValues
(Map<? extends ExecutableElement, ? extends AnnotationValue> valueMap) static boolean
validateElement
(Element element) static boolean
validateElements
(Iterable<? extends Element> elements) private static boolean
validateType
(TypeMirror type) private static boolean
validateTypes
(Iterable<? extends TypeMirror> types)
-
Field Details
-
ELEMENT_VALIDATING_VISITOR
-
TYPE_VALIDATING_VISITOR
-
VALUE_VALIDATING_VISITOR
-
-
Constructor Details
-
SuperficialValidation
public SuperficialValidation()
-
-
Method Details
-
validateElements
-
validateElement
-
isValidBaseElement
-
validateTypes
-
validateType
-
validateAnnotations
-
validateAnnotation
-
validateAnnotationValues
private static boolean validateAnnotationValues(Map<? extends ExecutableElement, ? extends AnnotationValue> valueMap) -
validateAnnotationValue
private static boolean validateAnnotationValue(AnnotationValue annotationValue, TypeMirror expectedType)
-