JBoss Remoting 3.1.0.Beta2

org.jboss.remoting3
Interface RequestListener<I,O>

Type Parameters:
I - the request type
O - the reply type
All Superinterfaces:
EventListener

public interface RequestListener<I,O>
extends EventListener

A request listener. Implementations of this interface will reply to client requests.

This interface is part of the Remoting 3 public API, and is intended to be implemented by users of this API. Abstract members will generally not be added to such types so as to avoid backwards compatibility problems.


Method Summary
 void handleRequest(RequestContext<O> context, I request)
          Handle a request.
 

Method Detail

handleRequest

void handleRequest(RequestContext<O> context,
                   I request)
                   throws RemoteExecutionException
Handle a request. If this method throws RemoteExecutionException, then that exception is passed back to the caller and the request is marked as complete. Otherwise, the request listener must send back either a reply (using the sendReply() method on the RequestContext) or an exception (using the sendException() method on the RequestContext).

Parameters:
context - the context on which a reply may be sent
request - the received request
Throws:
RemoteExecutionException - if the execution failed in some way

JBoss Remoting 3.1.0.Beta2

Copyright © 2010 JBoss, a division of Red Hat, Inc.