|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.codehaus.aspectwerkz.pointcut.FieldPointcut
Implements the pointcut concept for field access.
Is an abstraction of a well defined point of execution in the program.
Could matches one or many points as long as they are well defined.
Stores the advices for this specific pointcut.
| Constructor Summary | |
FieldPointcut(java.lang.String pattern)
Creates a new field pointcut. |
|
FieldPointcut(java.lang.String uuid,
java.lang.String pattern)
Creates a new field pointcut. |
|
| Method Summary | |
void |
addPointcutDef(PointcutDefinition pointcut)
Adds a new pointcut definition. |
void |
addPostAdvice(java.lang.String advice)
Adds post advice to the pointcut. |
void |
addPostAdvices(java.lang.String[] advicesToAdd)
Adds post advices to the pointcut. |
void |
addPreAdvice(java.lang.String advice)
Adds a pre advice to the pointcut. |
void |
addPreAdvices(java.lang.String[] advicesToAdd)
Adds pre advices to the pointcut. |
java.lang.String |
getExpression()
Returns the expression of the pointcut. |
int[] |
getPostAdviceIndexes()
Returns a list with the indexes for the post advices for the pointcut. |
AdviceIndexTuple[] |
getPostAdviceIndexTuples()
Returns the advices in the form of an array with advice/index tuples. |
java.lang.String[] |
getPostAdviceNames()
Returns a list with the names for the post advices for the pointcut. |
int[] |
getPreAdviceIndexes()
Returns a list with the indexes for the pre advices for the pointcut. |
AdviceIndexTuple[] |
getPreAdviceIndexTuples()
Returns the advices in the form of an array with advice/index tuples. |
java.lang.String[] |
getPreAdviceNames()
Returns a list with the names for the pre advices for the pointcut. |
boolean |
hasPostAdvice(java.lang.String advice)
Checks if the pointcuts has a certain post advice. |
boolean |
hasPreAdvice(java.lang.String advice)
Checks if the pointcuts has a certain pre advice. |
boolean |
matches(ClassMetaData classMetaData,
FieldMetaData fieldMetaData)
Checks if the pointcut matches a certain join point. |
static boolean |
matchFieldPointcutSuperClasses(org.apache.commons.jexl.JexlContext jexlContext,
java.lang.String name,
ClassMetaData classMetaData,
FieldMetaData fieldMetaData,
PointcutPatternTuple pointcutPattern)
Tries to finds a match at some superclass in the hierarchy. |
static boolean |
matchFieldPointcutSuperClasses(org.apache.commons.jexl.JexlContext jexlContext,
java.lang.String name,
ClassMetaData classMetaData,
PointcutPatternTuple pointcutPattern)
Tries to finds a match at some superclass in the hierarchy. |
void |
removePostAdvice(java.lang.String advice)
Removes a post advice from the pointcut. |
void |
removePreAdvice(java.lang.String advice)
Removes a pre advice from the pointcut. |
void |
setPostAdviceIndexTuples(AdviceIndexTuple[] tuple)
Sets the advices. |
void |
setPostAdvices(int[] indexes,
java.lang.String[] names)
Sets the post advices. |
void |
setPreAdviceIndexTuples(AdviceIndexTuple[] tuple)
Sets the advices. |
void |
setPreAdvices(int[] indexes,
java.lang.String[] names)
Sets the pre advices. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public FieldPointcut(java.lang.String pattern)
pattern - the pattern of the pointcut
public FieldPointcut(java.lang.String uuid,
java.lang.String pattern)
uuid - the UUID for the AspectWerkz systempattern - the pattern for the pointcut| Method Detail |
public void addPointcutDef(PointcutDefinition pointcut)
pointcut - the pointcut definitionpublic void addPreAdvice(java.lang.String advice)
advice - the name of the advice to addpublic void addPostAdvice(java.lang.String advice)
advice - the name of the advice to addpublic void addPreAdvices(java.lang.String[] advicesToAdd)
advicesToAdd - the advices to addpublic void addPostAdvices(java.lang.String[] advicesToAdd)
advicesToAdd - the advices to addpublic void removePreAdvice(java.lang.String advice)
advice - the name of the pre advice to removepublic void removePostAdvice(java.lang.String advice)
advice - the name of the pre advice to removepublic boolean hasPreAdvice(java.lang.String advice)
advice - the advice to check for existence
public boolean hasPostAdvice(java.lang.String advice)
advice - the advice to check for existence
public AdviceIndexTuple[] getPreAdviceIndexTuples()
public void setPreAdviceIndexTuples(AdviceIndexTuple[] tuple)
tuple - the new advice/index tuple arraypublic AdviceIndexTuple[] getPostAdviceIndexTuples()
public void setPostAdviceIndexTuples(AdviceIndexTuple[] tuple)
tuple - the new advice/index tuple arraypublic int[] getPreAdviceIndexes()
public java.lang.String[] getPreAdviceNames()
public int[] getPostAdviceIndexes()
public java.lang.String[] getPostAdviceNames()
public java.lang.String getExpression()
getExpression in interface Pointcut
public void setPreAdvices(int[] indexes,
java.lang.String[] names)
indexes - the new pre advice index arraynames - the new pre advice names array
public void setPostAdvices(int[] indexes,
java.lang.String[] names)
indexes - the new post advice index arraynames - the new post advice names array
public boolean matches(ClassMetaData classMetaData,
FieldMetaData fieldMetaData)
classMetaData - the class meta-datafieldMetaData - the meta-data for the field
public static boolean matchFieldPointcutSuperClasses(org.apache.commons.jexl.JexlContext jexlContext,
java.lang.String name,
ClassMetaData classMetaData,
PointcutPatternTuple pointcutPattern)
jexlContext - the Jexl contextname - the name of the pointcut to evaluateclassMetaData - the class meta-datapointcutPattern - the pointcut pattern
public static boolean matchFieldPointcutSuperClasses(org.apache.commons.jexl.JexlContext jexlContext,
java.lang.String name,
ClassMetaData classMetaData,
FieldMetaData fieldMetaData,
PointcutPatternTuple pointcutPattern)
jexlContext - the Jexl contextname - the name of the pointcut to evaluateclassMetaData - the class meta-datafieldMetaData - the field meta-datapointcutPattern - the pointcut pattern
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||