|
Invocation API 1.1.0.Final | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.invocation.proxy.AbstractClassFactory<T>
org.jboss.invocation.proxy.AbstractSubclassFactory<T>
org.jboss.invocation.proxy.AbstractProxyFactory<T>
T
- the superclass typepublic abstract class AbstractProxyFactory<T>
A subclass factory specializing in proxy generation.
Field Summary |
---|
Fields inherited from class org.jboss.invocation.proxy.AbstractSubclassFactory |
---|
reflectionMetadataSource |
Fields inherited from class org.jboss.invocation.proxy.AbstractClassFactory |
---|
classFile |
Constructor Summary | |
---|---|
protected |
AbstractProxyFactory(String className,
Class<T> superClass,
ClassLoader classLoader,
ProtectionDomain protectionDomain,
ReflectionMetadataSource reflectionMetadataSource)
Construct a new instance. |
Method Summary | |
---|---|
void |
afterClassLoad(Class<?> clazz)
Sets the accessible flag on the cached methods |
protected void |
cleanup()
Cleans up any resources left over from generating the class. |
protected void |
finalizeStaticConstructor()
This method must be called by subclasses after they have finished generating the class. |
List<Method> |
getCachedMethods()
Returns all Method objects that are cached by the proxy. |
protected void |
loadMethodIdentifier(Method methodToLoad,
org.jboss.classfilewriter.ClassMethod method)
Writes the bytecode to load an instance of Method for the given method onto the stack If loadMethod has not already been called for the given method then a static field to hold the method is added to the class, and code is added to the static constructor to initialize the field to the correct Method. |
Methods inherited from class org.jboss.invocation.proxy.AbstractClassFactory |
---|
buildClassDefinition, defineClass, generateClass, getClassLoader, getClassName, getProtectionDomain, getSuperClass, getSuperClassName, isProxyClassDefined, isProxyClassDefined, newInstance |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected AbstractProxyFactory(String className, Class<T> superClass, ClassLoader classLoader, ProtectionDomain protectionDomain, ReflectionMetadataSource reflectionMetadataSource)
className
- the class namesuperClass
- the superclassclassLoader
- the defining class loaderprotectionDomain
- the protection domainMethod Detail |
---|
protected void finalizeStaticConstructor()
public void afterClassLoad(Class<?> clazz)
afterClassLoad
in class AbstractClassFactory<T>
clazz
- The newly loaded classpublic List<Method> getCachedMethods()
InvocationHandler
when the corresponding proxy action is invoked
protected void cleanup()
cleanup
in class AbstractSubclassFactory<T>
protected void loadMethodIdentifier(Method methodToLoad, org.jboss.classfilewriter.ClassMethod method)
methodToLoad
- the method to loadmethod
- the subclass method to populate
|
Invocation API 1.1.0.Final | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |