org.jboss.ejb3.proxy.handler.session.service
Class ServiceProxyInvocationHandlerBase

java.lang.Object
  extended by org.jboss.ejb3.proxy.handler.ProxyInvocationHandlerBase
      extended by org.jboss.ejb3.proxy.handler.session.service.ServiceProxyInvocationHandlerBase
All Implemented Interfaces:
java.io.Serializable, java.lang.reflect.InvocationHandler, ProxyInvocationHandler, SessionProxyInvocationHandler
Direct Known Subclasses:
ServiceLocalProxyInvocationHandler, ServiceRemoteProxyInvocationHandler

public abstract class ServiceProxyInvocationHandlerBase
extends ProxyInvocationHandlerBase
implements SessionProxyInvocationHandler, java.io.Serializable

ServiceProxyInvocationHandlerBase Abstract base from which all JBoss Service Proxy InvocationHandlers may extend. Implements the notion of equality based solely on the name of the target container

See Also:
Serialized Form

Constructor Summary
protected ServiceProxyInvocationHandlerBase(java.lang.String containerName, java.lang.String containerGuid, org.jboss.aop.advice.Interceptor[] interceptors)
          Constructor
 
Method Summary
 java.lang.Object getAsynchronousProxy(java.lang.Object proxy)
           
protected  ServiceProxyInvocationHandlerBase getInvocationHandler(java.lang.Object proxy)
           
 java.lang.Object invoke(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args)
          Required "invoke" as defined by InvocationHandler interface
protected  boolean invokeEquals(java.lang.Object proxy, java.lang.Object argument)
          Handles invocation of "equals(Object)" upon a @Service Proxy Since this is a Singleton, if and only if the destination targets are to the same container, we'll consider the two Proxies equal
protected  int invokeHashCode(java.lang.Object proxy)
          Handles invocation of "hashCode()" upon the proxy
 
Methods inherited from class org.jboss.ejb3.proxy.handler.ProxyInvocationHandlerBase
getContainer, getContainerGuid, getContainerLocally, getContainerName, getInterceptors, handleInvocationDirectly, invoke, setContainerName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServiceProxyInvocationHandlerBase

protected ServiceProxyInvocationHandlerBase(java.lang.String containerName,
                                            java.lang.String containerGuid,
                                            org.jboss.aop.advice.Interceptor[] interceptors)
Constructor

Parameters:
containerName - The name of the target Container
containerGuid - The globally-unique name of the container
interceptors - The interceptors to apply to invocations upon this handler
Method Detail

invoke

public java.lang.Object invoke(java.lang.Object proxy,
                               java.lang.reflect.Method method,
                               java.lang.Object[] args)
                        throws java.lang.Throwable
Required "invoke" as defined by InvocationHandler interface

Specified by:
invoke in interface java.lang.reflect.InvocationHandler
Throws:
java.lang.Throwable

invokeEquals

protected boolean invokeEquals(java.lang.Object proxy,
                               java.lang.Object argument)
Handles invocation of "equals(Object)" upon a @Service Proxy Since this is a Singleton, if and only if the destination targets are to the same container, we'll consider the two Proxies equal

Specified by:
invokeEquals in class ProxyInvocationHandlerBase
Parameters:
proxy -
args -
Returns:

invokeHashCode

protected int invokeHashCode(java.lang.Object proxy)
Handles invocation of "hashCode()" upon the proxy

Specified by:
invokeHashCode in class ProxyInvocationHandlerBase
Parameters:
proxy -
Returns:

getInvocationHandler

protected ServiceProxyInvocationHandlerBase getInvocationHandler(java.lang.Object proxy)

getAsynchronousProxy

public java.lang.Object getAsynchronousProxy(java.lang.Object proxy)