org.aspectj.weaver.patterns
Class ExactTypePattern

java.lang.Object
  extended by org.aspectj.weaver.patterns.PatternNode
      extended by org.aspectj.weaver.patterns.TypePattern
          extended by org.aspectj.weaver.patterns.ExactTypePattern
All Implemented Interfaces:
IHasPosition, IHasSourceLocation
Direct Known Subclasses:
BindingTypePattern

public class ExactTypePattern
extends TypePattern


Nested Class Summary
 
Nested classes/interfaces inherited from class org.aspectj.weaver.patterns.TypePattern
TypePattern.MatchKind
 
Field Summary
static java.util.Map<java.lang.String,java.lang.Class<?>> boxedPrimitivesMap
           
 boolean checked
           
 boolean isVoid
           
static java.util.Map<java.lang.String,java.lang.Class<?>> primitiveTypesMap
           
protected  ResolvedType resolvedType
           
protected  UnresolvedType type
           
 
Fields inherited from class org.aspectj.weaver.patterns.TypePattern
AND, annotationPattern, ANY, ANY_KEY, ANY_WITH_ANNO, BINDING, DYNAMIC, ELLIPSIS, ELLIPSIS_KEY, EXACT, HAS_MEMBER, includeSubtypes, isVarArgs, NO, NO_KEY, NOT, OR, STATIC, TYPE_CATEGORY, typeParameters, WILD
 
Fields inherited from class org.aspectj.weaver.patterns.PatternNode
end, sourceContext, start
 
Constructor Summary
ExactTypePattern(UnresolvedType type, boolean includeSubtypes, boolean isVarArgs)
           
 
Method Summary
 java.lang.Object accept(PatternNodeVisitor visitor, java.lang.Object data)
           
protected  boolean couldEverMatchSameTypesAs(TypePattern other)
           
 boolean equals(java.lang.Object other)
           
 ResolvedType getResolvedExactType(World world)
           
 UnresolvedType getType()
           
 int hashCode()
           
 boolean isArray()
           
 boolean isVoid()
          for quickly recognizing the pattern 'void'
protected  boolean matchesExactly(ResolvedType matchType)
           
protected  boolean matchesExactly(ResolvedType matchType, ResolvedType annotatedType)
           
 FuzzyBoolean matchesInstanceof(ResolvedType matchType)
           
protected  boolean matchesSubtypes(ResolvedType type)
           
 TypePattern parameterizeWith(java.util.Map<java.lang.String,UnresolvedType> typeVariableMap, World w)
          return a version of this type pattern with all type variables references replaced by the corresponding entry in the map.
static TypePattern read(VersionedDataInputStream s, ISourceContext context)
           
static TypePattern readTypePattern150(VersionedDataInputStream s, ISourceContext context)
           
static TypePattern readTypePatternOldStyle(java.io.DataInputStream s, ISourceContext context)
           
 TypePattern resolveBindings(IScope scope, Bindings bindings, boolean allowBinding, boolean requireExactType)
          This can modify in place, or return a new TypePattern if the type changes.
 java.lang.String toString()
           
 void write(CompressingDataOutputStream out)
           
 
Methods inherited from class org.aspectj.weaver.patterns.TypePattern
getAnnotationPattern, getExactType, getTypeParameters, hasFailedResolution, isBangVoid, isEllipsis, isIncludeSubtypes, isStar, isStarAnnotation, isVarArgs, matches, matchesStatically, matchesSubtypes, notExactType, postRead, remapAdviceFormals, resolve, resolveExactType, setAnnotationTypePattern, setIsVarArgs, setTypeParameters
 
Methods inherited from class org.aspectj.weaver.patterns.PatternNode
copyLocationFrom, getEnd, getFileName, getSourceContext, getSourceLocation, getStart, readLocation, setLocation, traverse, writeLocation
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

type

protected UnresolvedType type

resolvedType

protected transient ResolvedType resolvedType

checked

public boolean checked

isVoid

public boolean isVoid

primitiveTypesMap

public static final java.util.Map<java.lang.String,java.lang.Class<?>> primitiveTypesMap

boxedPrimitivesMap

public static final java.util.Map<java.lang.String,java.lang.Class<?>> boxedPrimitivesMap
Constructor Detail

ExactTypePattern

public ExactTypePattern(UnresolvedType type,
                        boolean includeSubtypes,
                        boolean isVarArgs)
Method Detail

matchesSubtypes

protected boolean matchesSubtypes(ResolvedType type)
Overrides:
matchesSubtypes in class TypePattern

isArray

public boolean isArray()
Overrides:
isArray in class TypePattern

couldEverMatchSameTypesAs

protected boolean couldEverMatchSameTypesAs(TypePattern other)
Overrides:
couldEverMatchSameTypesAs in class TypePattern

matchesExactly

protected boolean matchesExactly(ResolvedType matchType)
Specified by:
matchesExactly in class TypePattern

matchesExactly

protected boolean matchesExactly(ResolvedType matchType,
                                 ResolvedType annotatedType)
Specified by:
matchesExactly in class TypePattern

getType

public UnresolvedType getType()

getResolvedExactType

public ResolvedType getResolvedExactType(World world)

isVoid

public boolean isVoid()
Description copied from class: TypePattern
for quickly recognizing the pattern 'void'

Overrides:
isVoid in class TypePattern

matchesInstanceof

public FuzzyBoolean matchesInstanceof(ResolvedType matchType)
Specified by:
matchesInstanceof in class TypePattern

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

write

public void write(CompressingDataOutputStream out)
           throws java.io.IOException
Specified by:
write in class PatternNode
Throws:
java.io.IOException

read

public static TypePattern read(VersionedDataInputStream s,
                               ISourceContext context)
                        throws java.io.IOException
Throws:
java.io.IOException

readTypePattern150

public static TypePattern readTypePattern150(VersionedDataInputStream s,
                                             ISourceContext context)
                                      throws java.io.IOException
Throws:
java.io.IOException

readTypePatternOldStyle

public static TypePattern readTypePatternOldStyle(java.io.DataInputStream s,
                                                  ISourceContext context)
                                           throws java.io.IOException
Throws:
java.io.IOException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

resolveBindings

public TypePattern resolveBindings(IScope scope,
                                   Bindings bindings,
                                   boolean allowBinding,
                                   boolean requireExactType)
Description copied from class: TypePattern
This can modify in place, or return a new TypePattern if the type changes.

Overrides:
resolveBindings in class TypePattern

parameterizeWith

public TypePattern parameterizeWith(java.util.Map<java.lang.String,UnresolvedType> typeVariableMap,
                                    World w)
return a version of this type pattern with all type variables references replaced by the corresponding entry in the map.

Specified by:
parameterizeWith in class TypePattern

accept

public java.lang.Object accept(PatternNodeVisitor visitor,
                               java.lang.Object data)
Specified by:
accept in class PatternNode