Class RoutingAgent<S extends State,E>

All Implemented Interfaces:
Agent, ModelEntity
Direct Known Subclasses:
DynamicElevator, DynamicVisitor, SimpleAgent

public abstract class RoutingAgent<S extends State,E> extends BasicAgent<S,E>
Extension of an AbstractAgent to enable massage routing.

When using message routing, there is no direct connection between source and destination. Rather the address is specified in the message envelope. This can be used to route the message to the right destination. So the agent needs only one inport and one outport. These are connected to the parent domain which does the actual routing. Therefore, the parent must be a RoutingDomain.

Note: Connection of ports is done automatically when adding this agent to a RoutingDomain.

See Also:
  • Constructor Details

    • RoutingAgent

      public RoutingAgent(EventQueue<E> queue, S s)
    • RoutingAgent

      public RoutingAgent(S s)