Package org.revapi.java.spi
Class TypeMirrorPairVisitor<R>
- java.lang.Object
-
- javax.lang.model.util.AbstractTypeVisitor6<R,P>
-
- javax.lang.model.util.SimpleTypeVisitor6<R,P>
-
- javax.lang.model.util.SimpleTypeVisitor7<R,TypeMirror>
-
- org.revapi.java.spi.TypeMirrorPairVisitor<R>
-
- All Implemented Interfaces:
TypeVisitor<R,TypeMirror>
public class TypeMirrorPairVisitor<R> extends SimpleTypeVisitor7<R,TypeMirror>
Similar toElementPairVisitor
but provides a visitor to visit two type mirrors of the same type.Typical usage:
javax.lang.model.type.TypeMirror t1 = ...; javax.lang.model.type.TypeMirror t2 = ...; t1.accept(new TypeMirrorPairVisitor<Void>() { protected Void visitArray(ArrayType t1, ArrayType t2) { ... } }, t2);
- Since:
- 0.1
- Author:
- Lukas Krejci
- See Also:
ElementPairVisitor
-
-
Field Summary
-
Fields inherited from class javax.lang.model.util.SimpleTypeVisitor6
DEFAULT_VALUE
-
-
Constructor Summary
Constructors Constructor Description TypeMirrorPairVisitor()
-
Method Summary
-
Methods inherited from class javax.lang.model.util.SimpleTypeVisitor6
defaultAction
-
Methods inherited from class javax.lang.model.util.AbstractTypeVisitor6
visit, visit
-
-
-
-
Method Detail
-
unmatchedAction
protected R unmatchedAction(@Nonnull TypeMirror type, @Nullable TypeMirror otherType)
-
defaultMatchAction
protected R defaultMatchAction(@Nonnull TypeMirror type, @Nullable TypeMirror otherType)
-
visitPrimitive
public final R visitPrimitive(PrimitiveType type, TypeMirror otherType)
- Specified by:
visitPrimitive
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitPrimitive
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitPrimitive
protected R visitPrimitive(PrimitiveType type, PrimitiveType otherType)
-
visitNull
public final R visitNull(NullType type, TypeMirror otherType)
- Specified by:
visitNull
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitNull
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitArray
public final R visitArray(ArrayType type, TypeMirror otherType)
- Specified by:
visitArray
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitArray
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitDeclared
public final R visitDeclared(DeclaredType type, TypeMirror otherType)
- Specified by:
visitDeclared
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitDeclared
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitDeclared
protected R visitDeclared(DeclaredType type, DeclaredType otherType)
-
visitError
public final R visitError(ErrorType type, TypeMirror otherType)
- Specified by:
visitError
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitError
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitTypeVariable
public final R visitTypeVariable(TypeVariable type, TypeMirror otherType)
- Specified by:
visitTypeVariable
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitTypeVariable
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitTypeVariable
protected R visitTypeVariable(TypeVariable type, TypeVariable otherType)
-
visitWildcard
public final R visitWildcard(WildcardType type, TypeMirror otherType)
- Specified by:
visitWildcard
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitWildcard
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitWildcard
protected R visitWildcard(WildcardType type, WildcardType otherType)
-
visitExecutable
public final R visitExecutable(ExecutableType type, TypeMirror otherType)
- Specified by:
visitExecutable
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitExecutable
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitExecutable
protected R visitExecutable(ExecutableType type, ExecutableType otherType)
-
visitNoType
public final R visitNoType(NoType type, TypeMirror otherType)
- Specified by:
visitNoType
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitNoType
in classSimpleTypeVisitor6<R,TypeMirror>
-
visitIntersection
public final R visitIntersection(IntersectionType type, TypeMirror otherType)
- Specified by:
visitIntersection
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitIntersection
in classAbstractTypeVisitor6<R,TypeMirror>
-
visitIntersection
protected R visitIntersection(IntersectionType type, IntersectionType otherType)
-
visitUnion
public final R visitUnion(UnionType type, TypeMirror otherType)
- Specified by:
visitUnion
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitUnion
in classSimpleTypeVisitor7<R,TypeMirror>
-
visitUnknown
public R visitUnknown(TypeMirror type, TypeMirror otherType)
- Specified by:
visitUnknown
in interfaceTypeVisitor<R,TypeMirror>
- Overrides:
visitUnknown
in classAbstractTypeVisitor6<R,TypeMirror>
-
-