org.jboss.remoting.transport.local
Class LocalClientInvoker
java.lang.Object
org.jboss.remoting.AbstractInvoker (src)
org.jboss.remoting.transport.local.LocalClientInvoker
- All Implemented Interfaces:
- ClientInvoker (src) , Invoker (src)
- public class LocalClientInvoker
- extends AbstractInvoker (src)
- implements ClientInvoker (src)
LocalClientInvoker does not use any transport protocol for invoking
the ServerInvoker, instead will make call directly on it locally.
This increases performance since no serialization required as well
as needed for push callbacks where InvokerCallbackHandler is in
same JVM as the callback server.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LocalClientInvoker
public LocalClientInvoker(InvokerLocator (src) locator)
invoke
public java.lang.Object invoke(InvocationRequest (src) invocation)
throws java.lang.Throwable
- transport a request against a remote ServerInvoker
- Specified by:
invoke
in interface ClientInvoker (src)
- Parameters:
invocation
-
- Returns:
-
- Throws:
java.lang.Throwable
isConnected
public boolean isConnected()
- subclasses must provide this method to return true if their remote connection is connected and
false if disconnected. in some transports, such as SOAP, this method may always return true, since the
remote connectivity is done on demand and not kept persistent like other transports (such as socket-based
transport).
- Specified by:
isConnected
in interface ClientInvoker (src)
- Returns:
- boolean true if connected, false if not
connect
public void connect()
throws ConnectionFailedException (src)
- connect to the remote invoker
- Specified by:
connect
in interface ClientInvoker (src)
- Throws:
ConnectionFailedException (src)
disconnect
public void disconnect()
- disconnect from the remote invoker. Once disconnect called
will not be able to re-connect by calling connect since will
loose reference to server invoker.
- Specified by:
disconnect
in interface ClientInvoker (src)
setMarshaller
public void setMarshaller(Marshaller (src) marshaller)
- Specified by:
setMarshaller
in interface ClientInvoker (src)
getMarshaller
public Marshaller (src) getMarshaller()
- Specified by:
getMarshaller
in interface ClientInvoker (src)
setUnMarshaller
public void setUnMarshaller(UnMarshaller (src) unmarshaller)
- Specified by:
setUnMarshaller
in interface ClientInvoker (src)
getUnMarshaller
public UnMarshaller (src) getUnMarshaller()
- Specified by:
getUnMarshaller
in interface ClientInvoker (src)
setServerInvoker
public void setServerInvoker(ServerInvoker (src) svrInvoker)
- This will set the local reference to the server invoker.
This is needed to so can make calls directly against server.
- Parameters:
svrInvoker
-