|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.aspectj.weaver.patterns.PatternNode
org.aspectj.weaver.patterns.TypePattern
public abstract class TypePattern
On creation, type pattern only contains WildTypePattern nodes, not BindingType or ExactType.
Then we call resolveBindings() during compilation During concretization of enclosing pointcuts, we call remapAdviceFormals
Nested Class Summary | |
---|---|
static class |
TypePattern.MatchKind
|
Field Summary | |
---|---|
static byte |
AND
|
static TypePattern |
ANY
|
static byte |
ANY_KEY
|
static byte |
ANY_WITH_ANNO
|
static byte |
BINDING
|
static TypePattern.MatchKind |
DYNAMIC
|
static TypePattern |
ELLIPSIS
|
static byte |
ELLIPSIS_KEY
|
static byte |
EXACT
|
static byte |
HAS_MEMBER
|
static TypePattern |
NO
|
static byte |
NO_KEY
|
static byte |
NOT
|
static byte |
OR
|
static TypePattern.MatchKind |
STATIC
|
static byte |
TYPE_CATEGORY
|
static byte |
WILD
|
Method Summary | |
---|---|
AnnotationTypePattern |
getAnnotationPattern()
|
UnresolvedType |
getExactType()
|
TypePatternList |
getTypeParameters()
|
boolean |
hasFailedResolution()
|
boolean |
isArray()
|
boolean |
isBangVoid()
For quickly recognizing the pattern '!void' |
boolean |
isEllipsis()
|
boolean |
isIncludeSubtypes()
|
boolean |
isStar()
|
boolean |
isStarAnnotation()
|
boolean |
isVarArgs()
|
boolean |
isVoid()
for quickly recognizing the pattern 'void' |
FuzzyBoolean |
matches(ResolvedType type,
TypePattern.MatchKind kind)
|
abstract FuzzyBoolean |
matchesInstanceof(ResolvedType type)
|
boolean |
matchesStatically(ResolvedType type)
|
abstract TypePattern |
parameterizeWith(java.util.Map typeVariableMap,
World w)
return a version of this type pattern in which all type variable references have been replaced by their corresponding entry in the map. |
void |
postRead(ResolvedType enclosingType)
|
static TypePattern |
read(VersionedDataInputStream s,
ISourceContext context)
|
TypePattern |
remapAdviceFormals(IntMap bindings)
This is called during concretization of pointcuts, it is used by BindingTypePattern to return a new BindingTypePattern with a formal index appropiate for the advice, rather than for the lexical declaration, i.e. |
void |
resolve(World world)
|
TypePattern |
resolveBindings(IScope scope,
Bindings bindings,
boolean allowBinding,
boolean requireExactType)
This can modify in place, or return a new TypePattern if the type changes. |
UnresolvedType |
resolveExactType(IScope scope,
Bindings bindings)
|
void |
setAnnotationTypePattern(AnnotationTypePattern annPatt)
|
void |
setIsVarArgs(boolean isVarArgs)
|
void |
setTypeParameters(TypePatternList typeParams)
|
Methods inherited from class org.aspectj.weaver.patterns.PatternNode |
---|
accept, copyLocationFrom, getEnd, getFileName, getSourceContext, getSourceLocation, getStart, readLocation, setLocation, traverse, write, writeLocation |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final TypePattern.MatchKind STATIC
public static final TypePattern.MatchKind DYNAMIC
public static final TypePattern ELLIPSIS
public static final TypePattern ANY
public static final TypePattern NO
public static final byte WILD
public static final byte EXACT
public static final byte BINDING
public static final byte ELLIPSIS_KEY
public static final byte ANY_KEY
public static final byte NOT
public static final byte OR
public static final byte AND
public static final byte NO_KEY
public static final byte ANY_WITH_ANNO
public static final byte HAS_MEMBER
public static final byte TYPE_CATEGORY
Method Detail |
---|
public AnnotationTypePattern getAnnotationPattern()
public boolean isVarArgs()
public boolean isStarAnnotation()
public boolean isArray()
public void setAnnotationTypePattern(AnnotationTypePattern annPatt)
public void setTypeParameters(TypePatternList typeParams)
public TypePatternList getTypeParameters()
public void setIsVarArgs(boolean isVarArgs)
public boolean matchesStatically(ResolvedType type)
public abstract FuzzyBoolean matchesInstanceof(ResolvedType type)
public final FuzzyBoolean matches(ResolvedType type, TypePattern.MatchKind kind)
public UnresolvedType resolveExactType(IScope scope, Bindings bindings)
public UnresolvedType getExactType()
public TypePattern resolveBindings(IScope scope, Bindings bindings, boolean allowBinding, boolean requireExactType)
public void resolve(World world)
public abstract TypePattern parameterizeWith(java.util.Map typeVariableMap, World w)
public void postRead(ResolvedType enclosingType)
public boolean isEllipsis()
public boolean isStar()
public TypePattern remapAdviceFormals(IntMap bindings)
pointcut foo(String name): args(name); --> This makes a BindingTypePattern(0) pointing to the 0th formal before(Foo f, String n): this(f) && foo(n) { ... } --> when resolveReferences is called on the args from the above, it will return a BindingTypePattern(1) before(Foo f): this(f) && foo(*) { ... } --> when resolveReferences is called on the args from the above, it will return an ExactTypePattern(String)
public static TypePattern read(VersionedDataInputStream s, ISourceContext context) throws java.io.IOException
java.io.IOException
public boolean isIncludeSubtypes()
public boolean isBangVoid()
public boolean isVoid()
public boolean hasFailedResolution()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |