org.jboss.remoting
Interface ClientInterceptor

All Known Implementing Classes:
ClientInvokerAdapter

public interface ClientInterceptor

Client is a convience method for invoking remote methods for a given subsystem

Version:
$Revision: 1.4 $
Author:
Jeff Haynie, Tom Elrod

Method Summary
 void addListener(InvokerLocator locator, String sessionId, InvokerCallbackHandler callbackHandler)
          If the client invoker has a client locator, call it to add the client's callback handler.
 void connect(InvokerLocator locator)
           
 void disconnect(InvokerLocator locator)
           
 List getCallbacks(InvokerLocator locator, String sessionId)
           
 Object invoke(InvocationRequest invocation)
          invoke the method remotely
 boolean isConnected(InvokerLocator locator)
           
 void removeListener(InvokerLocator locator, String sessionId, InvokerCallbackHandler callbackHandler)
          Removes callback handler as a callback listener from the server (and client in the case that it was setup to receive async callbacks).
 

Method Detail

isConnected

public boolean isConnected(InvokerLocator locator)
                    throws Exception
Throws:
Exception

connect

public void connect(InvokerLocator locator)
             throws Exception
Throws:
Exception

disconnect

public void disconnect(InvokerLocator locator)
                throws Exception
Throws:
Exception

invoke

public Object invoke(InvocationRequest invocation)
              throws Throwable
invoke the method remotely

Returns:
Throws:
Throwable

addListener

public void addListener(InvokerLocator locator,
                        String sessionId,
                        InvokerCallbackHandler callbackHandler)
                 throws Throwable
If the client invoker has a client locator, call it to add the client's callback handler. Then call the server to add a callback handler (regardless of client locator being null). This will allow for pull or push callbacks.

Parameters:
callbackHandler -
Throws:
Throwable

removeListener

public void removeListener(InvokerLocator locator,
                           String sessionId,
                           InvokerCallbackHandler callbackHandler)
                    throws Throwable
Removes callback handler as a callback listener from the server (and client in the case that it was setup to receive async callbacks). See addListener().

Parameters:
callbackHandler -
Throws:
Throwable

getCallbacks

public List getCallbacks(InvokerLocator locator,
                         String sessionId)
                  throws Throwable
Throws:
Throwable


Copyright © 2004 JBoss Inc. All Rights Reserved.