| java.lang.Object ch.ethz.prose.crosscut.SignaturePattern ch.ethz.prose.crosscut.MethodCutSignaturePattern
MethodCutSignaturePattern | class MethodCutSignaturePattern extends SignaturePattern implements Serializable(Code) | | Every Crosscut contains a method to be executed when a join-point is hit.
In the case of MethodCut objects, the advice method has three
roles:
- The pattern role: through a special signature, define matches for the
target class, and for the parameters of the methods belonging to the target.
- The method finder role: determine which method o of the crosscut
must be ivoked upon a hit join-point.
- The optimization role: to cathegorize the signature of the advice
method, such that the subsequent execution of the advice method is efficient.
The categorization is currently performed according to the
SIGNATURE__XXX
constants.
|
Method Summary | |
protected boolean | matchesParameters(Method actualMethod) Returns true if the signature of
methoObj , seen as a pattern,
matches the signature (the parameter types) for
actualMehtod . | public String | toString() |
MethodCutSignaturePattern | protected MethodCutSignaturePattern(MethodCut crsc) throws MissingInformationException(Code) | | Create an UserDefinedMCSignature that encapsulates the
method to be executed.
Postcondition: methodObj is properly initialized
Implementation:
- if
crsc (i.e., a subclass of FunctionalCrossscut)
defines exaclty one method, this method is
the advice method.
- If
crsc defines several methods, the one whose
name corresponds to crsc.ADVICE_NAME() is the advice method
throws: MissingInformationExeception - crsc does not define a method at all,or if it defines several, none of them matches crsc.ADVICE_NAME() . |
matchesParameters | protected boolean matchesParameters(Method actualMethod)(Code) | | Returns true if the signature of
methoObj , seen as a pattern,
matches the signature (the parameter types) for
actualMehtod .
|
|
|