|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--stomp.enhance.AbstractEnhancer | +--stomp.enhance.ServiceEnhancer
This class can be used to transform a normal java class into a JDO-ready service-enabled class.
Constructor Summary | |
ServiceEnhancer(serp.bytecode.BCClass source)
|
Method Summary | |
protected void |
addGetSetMethods(serp.bytecode.BCField field,
serp.bytecode.BCClass delegate)
Adds special xGet and xSet methods for the given field to the bean class. |
protected serp.bytecode.BCClass |
createDelegate()
creates the delegate object which is going to have transactional ( and other ) services provided. |
protected serp.bytecode.BCClass |
createProxy()
Creates the proxy class and stores it internally. |
void |
enhance()
Creates all the necessary classes (proxy, interface, and delegate objects), and stores them internally. |
protected java.lang.Class |
getDelegateBaseClass()
|
protected java.lang.Class |
getDelegateProxyConstructorType()
|
java.lang.String |
getEnhancerAttribute()
|
protected java.lang.Class |
getProxyBaseClass()
|
static void |
main(java.lang.String[] args)
|
protected void |
makeProxyConstructor(serp.bytecode.BCMethod copy,
serp.bytecode.BCClass proxy)
takes an existing constructor method and converts it into a proxy constructor by changing the code inside. |
protected void |
makeProxyMethod(serp.bytecode.BCMethod method)
Changes the given method to one that delegates to the same method in the delegate object. |
boolean |
shouldEnhance()
|
Methods inherited from class stomp.enhance.AbstractEnhancer |
alreadyEnhanced, changeDelegateMethodInvocations, createCommonInterface, createInterface, debug, getFieldGetMethodName, getFieldSetMethodName, getMetaData, getProject, getServiceClasses, getSource, writeClass |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ServiceEnhancer(serp.bytecode.BCClass source) throws java.lang.ClassNotFoundException
Method Detail |
public void enhance()
AbstractEnhancer
enhance
in class AbstractEnhancer
public boolean shouldEnhance()
protected serp.bytecode.BCClass createDelegate() throws java.lang.ClassNotFoundException
createDelegate
in class AbstractEnhancer
java.lang.ClassNotFoundException
protected void addGetSetMethods(serp.bytecode.BCField field, serp.bytecode.BCClass delegate) throws java.lang.ClassNotFoundException
addGetSetMethods
in class AbstractEnhancer
java.lang.ClassNotFoundException
protected serp.bytecode.BCClass createProxy() throws java.lang.ClassNotFoundException
createProxy
in class AbstractEnhancer
java.lang.ClassNotFoundException
protected java.lang.Class getProxyBaseClass()
getProxyBaseClass
in class AbstractEnhancer
protected void makeProxyMethod(serp.bytecode.BCMethod method) throws java.lang.ClassNotFoundException
makeProxyMethod
in class AbstractEnhancer
java.lang.ClassNotFoundException
protected java.lang.Class getDelegateBaseClass()
getDelegateBaseClass
in class AbstractEnhancer
protected void makeProxyConstructor(serp.bytecode.BCMethod copy, serp.bytecode.BCClass proxy) throws java.lang.ClassNotFoundException
makeProxyConstructor
in class AbstractEnhancer
java.lang.ClassNotFoundException
protected java.lang.Class getDelegateProxyConstructorType()
getDelegateProxyConstructorType
in class AbstractEnhancer
public java.lang.String getEnhancerAttribute()
getEnhancerAttribute
in class AbstractEnhancer
public static void main(java.lang.String[] args) throws java.lang.ClassNotFoundException, java.io.IOException
java.lang.ClassNotFoundException
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |