com.azalient.api.sim.agents
Interface IRouteFinder

All Known Subinterfaces:
IMotor, IPersonTrip, ITransport, ITransportTrip, ITrip, IVehicle, IVehicleTrip

public interface IRouteFinder

An interface to an object that can determine a route, which may be an agent, or if the agent has not yet been created, the trip. The agent is used if it exists, because it holds more context, and as such will make a more informed choice.


Method Summary
 boolean arrivesHere(ILink approach)
          Return true if the trip arrives here
 int routeExitIndex(ITwig twig)
          Return [1..N] exit index, or 0 if there is a route choice at the end of this link and there is no route to destination.
 

Method Detail

routeExitIndex

int routeExitIndex(ITwig twig)
Return [1..N] exit index, or 0 if there is a route choice at the end of this link and there is no route to destination. If this link has only a single exit, then this will always return 1.
This uses the router for Vehicles and Service definition for Transport


arrivesHere

boolean arrivesHere(ILink approach)
Return true if the trip arrives here