org.jboss.soa.esb.services.routing
Class MessageRouter

java.lang.Object
  extended by org.jboss.soa.esb.services.routing.MessageRouter
Direct Known Subclasses:
ContentBasedRouter

public abstract class MessageRouter
extends java.lang.Object

Generic Message Router Interface.

Author:
kurt.stam@redhat.com

Field Summary
static java.lang.String DELIVER_MESSAGES
           
static java.lang.String ROUTING_DESTINATION_SERVICE_LIST
           
 
Constructor Summary
MessageRouter()
           
 
Method Summary
static void deliverMessages(java.util.Collection<java.lang.String> destinationServices, Message message)
          Sends the message on to the service with the name(s) we just obtained from the routing.
abstract  java.util.List<java.lang.String> route(Message message)
          Routes the message to the next destination.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ROUTING_DESTINATION_SERVICE_LIST

public static java.lang.String ROUTING_DESTINATION_SERVICE_LIST

DELIVER_MESSAGES

public static java.lang.String DELIVER_MESSAGES
Constructor Detail

MessageRouter

public MessageRouter()
Method Detail

route

public abstract java.util.List<java.lang.String> route(Message message)
Routes the message to the next destination.

Parameters:
message -
Returns:
List of Strings containing the services to which the message was routed.

deliverMessages

public static void deliverMessages(java.util.Collection<java.lang.String> destinationServices,
                                   Message message)
Sends the message on to the service with the name(s) we just obtained from the routing.

Parameters:
destinationServices - - Collection with the name of the destination services.
message - - the message that needs routing and delivery