org.jboss.proxy
Class GenericProxyFactory

java.lang.Object
  extended byorg.jboss.proxy.GenericProxyFactory

public class GenericProxyFactory
extends java.lang.Object

A generic factory of java.lang.reflect.Proxy that constructs a proxy that is a composite of ClientContainer/Interceptors/Invoker


Constructor Summary
GenericProxyFactory()
           
 
Method Summary
 java.lang.Object createProxy(java.lang.Object id, ObjectName (src)  targetName, Invoker (src)  invoker, java.lang.String jndiName, java.lang.String proxyBindingName, java.util.ArrayList interceptorClasses, java.lang.ClassLoader loader, java.lang.Class[] ifaces)
          Create a composite proxy for the given interfaces, invoker.
 java.lang.Object createProxy(java.lang.Object id, ObjectName (src)  targetName, Invoker (src)  invoker, java.lang.String jndiName, java.lang.String proxyBindingName, java.util.ArrayList interceptorClasses, java.lang.ClassLoader loader, java.lang.Class[] ifaces, java.util.HashMap ctx)
          Create a composite proxy for the given interfaces, invoker.
 java.lang.Object createProxy(java.lang.Object id, ObjectName (src)  targetName, ObjectName (src)  invokerName, java.lang.String jndiName, java.lang.String proxyBindingName, java.util.ArrayList interceptorClasses, java.lang.ClassLoader loader, java.lang.Class[] ifaces)
          Create a composite proxy for the given interfaces, invoker.
protected  void loadInterceptorChain(java.util.ArrayList chain, ClientContainer (src)  client)
          The loadInterceptorChain create instances of interceptor classes from the list of classes given by the chain array.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GenericProxyFactory

public GenericProxyFactory()
Method Detail

createProxy

public java.lang.Object createProxy(java.lang.Object id,
                                    ObjectName (src)  targetName,
                                    Invoker (src)  invoker,
                                    java.lang.String jndiName,
                                    java.lang.String proxyBindingName,
                                    java.util.ArrayList interceptorClasses,
                                    java.lang.ClassLoader loader,
                                    java.lang.Class[] ifaces)
Create a composite proxy for the given interfaces, invoker.

Parameters:
id - the cache id for the target object if any
targetName - the name of the server side service
invoker - the detached invoker stub to embed in the proxy
jndiName - the JNDI name the proxy will be bound under if not null
proxyBindingName - the invoker-proxy-binding name if not null
interceptorClasses - the Class objects for the interceptors
loader - the ClassLoader to associate the the Proxy
ifaces - the Class objects for the interfaces the Proxy implements

createProxy

public java.lang.Object createProxy(java.lang.Object id,
                                    ObjectName (src)  targetName,
                                    ObjectName (src)  invokerName,
                                    java.lang.String jndiName,
                                    java.lang.String proxyBindingName,
                                    java.util.ArrayList interceptorClasses,
                                    java.lang.ClassLoader loader,
                                    java.lang.Class[] ifaces)
Create a composite proxy for the given interfaces, invoker.

Parameters:
id - the cache id for the target object if any
targetName - the name of the server side service
invokerName - the name of the server side JMX invoker
jndiName - the JNDI name the proxy will be bound under if not null
proxyBindingName - the invoker-proxy-binding name if not null
interceptorClasses - the Class objects for the interceptors
loader - the ClassLoader to associate the the Proxy
ifaces - the Class objects for the interfaces the Proxy implements

createProxy

public java.lang.Object createProxy(java.lang.Object id,
                                    ObjectName (src)  targetName,
                                    Invoker (src)  invoker,
                                    java.lang.String jndiName,
                                    java.lang.String proxyBindingName,
                                    java.util.ArrayList interceptorClasses,
                                    java.lang.ClassLoader loader,
                                    java.lang.Class[] ifaces,
                                    java.util.HashMap ctx)
Create a composite proxy for the given interfaces, invoker.

Parameters:
id - the cache id for the target object if any
targetName - the name of the server side service
invoker - the detached invoker stub to embed in the proxy
jndiName - the JNDI name the proxy will be bound under if not null
proxyBindingName - the invoker-proxy-binding name if not null
interceptorClasses - the Class objects for the interceptors
loader - the ClassLoader to associate the the Proxy
ifaces - the Class objects for the interfaces the Proxy implements
ctx - any context to add the invocation context proxy

loadInterceptorChain

protected void loadInterceptorChain(java.util.ArrayList chain,
                                    ClientContainer (src)  client)
                             throws java.lang.Exception
The loadInterceptorChain create instances of interceptor classes from the list of classes given by the chain array.

Throws:
java.lang.Exception - if an error occurs