Package com.google.auto.common
Class SuperficialValidation
- java.lang.Object
-
- com.google.auto.common.SuperficialValidation
-
public final class SuperficialValidation extends java.lang.ObjectA utility class that traversesElementinstances and ensures that all type information is present and resolvable.
-
-
Field Summary
Fields Modifier and Type Field Description private static javax.lang.model.element.ElementVisitor<java.lang.Boolean,java.lang.Void>ELEMENT_VALIDATING_VISITORprivate static javax.lang.model.type.TypeVisitor<java.lang.Boolean,java.lang.Void>TYPE_VALIDATING_VISITORprivate static javax.lang.model.element.AnnotationValueVisitor<java.lang.Boolean,javax.lang.model.type.TypeMirror>VALUE_VALIDATING_VISITOR
-
Constructor Summary
Constructors Constructor Description SuperficialValidation()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static booleanisValidBaseElement(javax.lang.model.element.Element e)private static booleanvalidateAnnotation(javax.lang.model.element.AnnotationMirror annotationMirror)private static booleanvalidateAnnotations(java.lang.Iterable<? extends javax.lang.model.element.AnnotationMirror> annotationMirrors)private static booleanvalidateAnnotationValue(javax.lang.model.element.AnnotationValue annotationValue, javax.lang.model.type.TypeMirror expectedType)private static booleanvalidateAnnotationValues(java.util.Map<? extends javax.lang.model.element.ExecutableElement,? extends javax.lang.model.element.AnnotationValue> valueMap)static booleanvalidateElement(javax.lang.model.element.Element element)static booleanvalidateElements(java.lang.Iterable<? extends javax.lang.model.element.Element> elements)private static booleanvalidateType(javax.lang.model.type.TypeMirror type)private static booleanvalidateTypes(java.lang.Iterable<? extends javax.lang.model.type.TypeMirror> types)
-
-
-
Field Detail
-
ELEMENT_VALIDATING_VISITOR
private static final javax.lang.model.element.ElementVisitor<java.lang.Boolean,java.lang.Void> ELEMENT_VALIDATING_VISITOR
-
TYPE_VALIDATING_VISITOR
private static final javax.lang.model.type.TypeVisitor<java.lang.Boolean,java.lang.Void> TYPE_VALIDATING_VISITOR
-
VALUE_VALIDATING_VISITOR
private static final javax.lang.model.element.AnnotationValueVisitor<java.lang.Boolean,javax.lang.model.type.TypeMirror> VALUE_VALIDATING_VISITOR
-
-
Method Detail
-
validateElements
public static boolean validateElements(java.lang.Iterable<? extends javax.lang.model.element.Element> elements)
-
validateElement
public static boolean validateElement(javax.lang.model.element.Element element)
-
isValidBaseElement
private static boolean isValidBaseElement(javax.lang.model.element.Element e)
-
validateTypes
private static boolean validateTypes(java.lang.Iterable<? extends javax.lang.model.type.TypeMirror> types)
-
validateType
private static boolean validateType(javax.lang.model.type.TypeMirror type)
-
validateAnnotations
private static boolean validateAnnotations(java.lang.Iterable<? extends javax.lang.model.element.AnnotationMirror> annotationMirrors)
-
validateAnnotation
private static boolean validateAnnotation(javax.lang.model.element.AnnotationMirror annotationMirror)
-
validateAnnotationValues
private static boolean validateAnnotationValues(java.util.Map<? extends javax.lang.model.element.ExecutableElement,? extends javax.lang.model.element.AnnotationValue> valueMap)
-
validateAnnotationValue
private static boolean validateAnnotationValue(javax.lang.model.element.AnnotationValue annotationValue, javax.lang.model.type.TypeMirror expectedType)
-
-