abc.weaving.aspectinfo
Class AccessorDispatch
java.lang.Object
abc.weaving.aspectinfo.AccessorMethod
abc.weaving.aspectinfo.AccessorDispatch
public class AccessorDispatch
- extends AccessorMethod
- Author:
- Pavel Avgustinov
Class representing an accessor method for a field - given the appropriate information, it
constructs a public method in the appropriate class, with the appropriate type, taking
the same arguments as the method it's wrapping around and returning that method's result.
Constructor Summary |
AccessorDispatch(java.lang.String name,
MethodInstance mi,
ClassType target,
Position pos)
|
Method Summary |
protected void |
addDispatch(int modifiers,
soot.SootClass sc,
boolean bAbstract)
|
void |
addSootMethod(int modifiers)
Get the SootMethod representing this accessor method with the given modifiers. |
void |
registerMethod(soot.SootMethod sm)
Used to register the method's category with the static MethodCategory class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AccessorDispatch
public AccessorDispatch(java.lang.String name,
MethodInstance mi,
ClassType target,
Position pos)
addSootMethod
public void addSootMethod(int modifiers)
- Description copied from class:
AccessorMethod
- Get the SootMethod representing this accessor method with the given modifiers. This method also
adds the generated method to the target class.
- Specified by:
addSootMethod
in class AccessorMethod
- Parameters:
modifiers
- Modifiers to declare the method with - compare soot.Modifier
addDispatch
protected void addDispatch(int modifiers,
soot.SootClass sc,
boolean bAbstract)
registerMethod
public void registerMethod(soot.SootMethod sm)
- Description copied from class:
AccessorMethod
- Used to register the method's category with the static MethodCategory class.
The default implementation (registering field get/set methods and dispatches) should be
sufficient for most purposes.
- Specified by:
registerMethod
in class AccessorMethod