KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > mule > umo > routing > UMOResponseMessageRouter


1 /*
2  * $Id: UMOResponseMessageRouter.java 3798 2006-11-04 04:07:14Z aperepel $
3  * --------------------------------------------------------------------------------------
4  * Copyright (c) MuleSource, Inc. All rights reserved. http://www.mulesource.com
5  *
6  * The software in this package is published under the terms of the MuleSource MPL
7  * license, a copy of which has been included with this distribution in the
8  * LICENSE.txt file.
9  */

10
11 package org.mule.umo.routing;
12
13 import org.mule.umo.UMOEvent;
14 import org.mule.umo.UMOException;
15 import org.mule.umo.UMOMessage;
16 import org.mule.umo.endpoint.UMOEndpoint;
17
18 import java.util.List JavaDoc;
19
20 /**
21  * <code>UMOResponseMessageRouter</code> is a router that can be used to control
22  * how the response in a request/response message flow is created. Main usecase is to
23  * aggregate a set of asynchonous events into a single response
24  *
25  * @author <a HREF="mailto:ross.mason@symphonysoft.com">Ross Mason</a>
26  * @version $Revision: 3798 $
27  */

28
29 public interface UMOResponseMessageRouter extends UMORouterCollection
30 {
31     void route(UMOEvent event) throws RoutingException;
32
33     UMOMessage getResponse(UMOMessage message) throws UMOException;
34
35     UMOResponseRouter removeRouter(UMOResponseRouter router);
36
37     void addEndpoint(UMOEndpoint endpoint);
38
39     boolean removeEndpoint(UMOEndpoint endpoint);
40
41     List JavaDoc getEndpoints();
42
43     /**
44      * @param name the Endpoint identifier
45      * @return the Endpoint or null if the endpointUri is not registered
46      * @see UMOResponseMessageRouter
47      */

48     UMOEndpoint getEndpoint(String JavaDoc name);
49
50     void setEndpoints(List JavaDoc endpoints);
51
52     public int getTimeout();
53
54     public void setTimeout(int timeout);
55 }
56
Popular Tags