| java.lang.Object org.ow2.easybeans.proxy.client.AbsInvocationHandler org.ow2.easybeans.proxy.client.LocalCallInvocationHandler
All known Subclasses: org.ow2.easybeans.proxy.client.EJBLocalHomeInvocationHandler,
LocalCallInvocationHandler | public class LocalCallInvocationHandler extends AbsInvocationHandler implements Externalizable(Code) | | Object acting as the proxy for local interfaces calls.
author: Florent Benoit |
Method Summary | |
protected Throwable | convertThrowable(Throwable throwable) Convert the received exception to the correct type for the remote case.
Parameters: throwable - the exception to analyze. | protected Integer | getEmbeddedID() Gets the embedded ID. | public Object | invoke(Object proxy, Method method, Object[] args) Processes a method invocation on a proxy instance and returns the result.
This method will be invoked on an invocation handler when a method is
invoked on a proxy instance that it is associated with.
Parameters: proxy - the proxy instance that the method was invoked on Parameters: method - the Method instance corresponding to theinterface method invoked on the proxy instance. | public void | readExternal(ObjectInput in) Build our content. | public void | setInterfaceClass(Class> clz) Sets the interface that represents this handler. | public void | writeExternal(ObjectOutput out) Save our content. |
LocalCallInvocationHandler | public LocalCallInvocationHandler(Integer embeddedID, String containerId, String factoryName, boolean useID)(Code) | | Build a new Invocation handler.
Parameters: embeddedID - the Embedded server ID. Parameters: containerId - the id of the container that will be called on theremote side. Parameters: factoryName - the name of the remote factory. Parameters: useID - true if all instance build with this ref are unique(stateful), false if it references the same object (stateless) |
LocalCallInvocationHandler | public LocalCallInvocationHandler()(Code) | | Default constructor (used for serialization).
|
convertThrowable | protected Throwable convertThrowable(Throwable throwable)(Code) | | Convert the received exception to the correct type for the remote case.
Parameters: throwable - the exception to analyze. the converted exception or the original exception |
getEmbeddedID | protected Integer getEmbeddedID()(Code) | | Gets the embedded ID.
the embedded ID. |
invoke | public Object invoke(Object proxy, Method method, Object[] args) throws Exception(Code) | | Processes a method invocation on a proxy instance and returns the result.
This method will be invoked on an invocation handler when a method is
invoked on a proxy instance that it is associated with.
Parameters: proxy - the proxy instance that the method was invoked on Parameters: method - the Method instance corresponding to theinterface method invoked on the proxy instance. The declaringclass of the Method object will be the interfacethat the method was declared in, which may be a superinterface ofthe proxy interface that the proxy class inherits the methodthrough. Parameters: args - an array of objects containing the values of the argumentspassed in the method invocation on the proxy instance, ornull if interface method takes no arguments.Arguments of primitive types are wrapped in instances of theappropriate primitive wrapper class, such asjava.lang.Integer or java.lang.Boolean . the value to return from the method invocation on the proxyinstance. throws: Exception - the exception to throw from the method invocation onthe proxy instance. |
setInterfaceClass | public void setInterfaceClass(Class> clz)(Code) | | Sets the interface that represents this handler.
Parameters: clz - the instance of the interface. |
writeExternal | public void writeExternal(ObjectOutput out) throws IOException(Code) | | Save our content.
Parameters: out - the stream to write the object to throws: IOException - Includes any I/O exceptions that may occur |
|
|