 |
Eclipse SUMO - Simulation of Urban MObility
|
Go to the documentation of this file.
19 #ifndef MSDevice_Routing_h
20 #define MSDevice_Routing_h
162 void setParameter(
const std::string& key,
const std::string& value);
Representation of a vehicle or person.
A device that performs vehicle rerouting based on current edge speeds.
Representation of a lane in the micro simulation.
SUMOTime getPeriod() const
Static storage of an output device and its base (abstract) implementation.
~MSDevice_Routing()
Destructor.
const std::string deviceName() const
return the name for this type of device
Representation of a vehicle.
SUMOTime myLastRouting
The last time a routing took place.
WrappingCommand< MSDevice_Routing > * myRerouteCommand
The (optional) command responsible for rerouting.
MSDevice_Routing & operator=(const MSDevice_Routing &)
Invalidated assignment operator.
static bool checkOptions(OptionsCont &oc)
checks MSDevice_Routing-options
void saveState(OutputDevice &out) const
Saves the state of the device.
void setParameter(const std::string &key, const std::string &value)
try to set the given parameter for this device. Throw exception for unsupported key
SUMOTime wrappedRerouteCommandExecute(SUMOTime currentTime)
Performs rerouting after a period.
A storage for options typed value containers)
void loadState(const SUMOSAXAttributes &attrs)
Loads the state of the device from the given description.
bool notifyEnter(SUMOTrafficObject &veh, MSMoveReminder::Notification reason, const MSLane *enteredLane=0)
Computes a new route on vehicle insertion.
void skipRouting(const SUMOTime currentTime)
Labels the current time step as "unroutable".
SUMOTime myPreInsertionPeriod
The period with which a vehicle shall be rerouted before insertion.
static void insertOptions(OptionsCont &oc)
Inserts MSDevice_Routing-options.
SUMOTime myPeriod
The period with which a vehicle shall be rerouted.
void reroute(const SUMOTime currentTime, const bool onInit=false)
initiate the rerouting, create router / thread pool on first use
SUMOTime mySkipRouting
The time for which routing may be skipped because we cannot be inserted.
static void buildVehicleDevices(SUMOVehicle &v, std::vector< MSVehicleDevice * > &into)
Build devices for the given vehicle, if needed.
Encapsulated SAX-Attributes.
Notification
Definition of a vehicle state.
MSDevice_Routing(SUMOVehicle &holder, const std::string &id, SUMOTime period, SUMOTime preInsertionPeriod)
Constructor.
std::string getParameter(const std::string &key) const
try to retrieve the given parameter from this device. Throw exception for unsupported key
SUMOTime preInsertionReroute(const SUMOTime currentTime)
Performs rerouting before insertion into the network.
Abstract in-vehicle device.