40 #ifdef CHECK_MEMORY_LEAKS
42 #endif // CHECK_MEMORY_LEAKS
49 :
ROEdge(id, from, to, index, priority) {}
77 (*i).second->add(begTime, endTime, probability);
92 if ((veh == 0 || !(*i).first->prohibits(veh)) && (*i).second->describesTime(time)) {
93 dist.
add((*i).second->getValue(time), (*i).first);
119 for (i = 0; i < defs.size(); ++i) {
127 for (
size_t j = 0; j < defs.size(); ++j) {
128 value += tmp[i * defs.size() + j];
FollowerUsageCont myFollowingDefs
Storage for the probabilities of using a certain follower over time.
Represents a generic random distribution.
void addFollower(ROEdge *s, std::string dir="")
Adds information about a connected edge.
bool add(SUMOReal prob, T val, bool checkDuplicates=true)
Adds a value with an assigned probability to the distribution.
ROJTREdge(const std::string &id, RONode *from, RONode *to, unsigned int index, const int priority)
Constructor.
ROJTREdge * chooseNext(const ROVehicle *const veh, SUMOTime time) const
Returns the next edge to use.
void setTurnDefaults(const std::vector< SUMOReal > &defs)
Sets the turning definition defaults.
std::vector< SUMOReal > myParsedTurnings
The defaults for turnings.
const std::string & getID() const
Returns the id.
A vehicle as used by router.
bool allFollowersProhibit(const ROVehicle *const vehicle) const
Returns whether this edge succeding edges prohibit the given vehicle to pass them.
T get(MTRand *which=0) const
Draw a sample of the distribution.
An edge the jtr-router may route through.
A basic edge for routing applications.
std::vector< ROEdge * > myFollowingEdges
List of edges that may be approached from this edge.
SUMOReal getOverallProb() const
Return the sum of the probabilites assigned to the members.
bool prohibits(const ROVehicle *const vehicle) const
Returns whether this edge prohibits the given vehicle to pass it.
Base class for nodes used by the router.
virtual void addFollower(ROEdge *s, std::string dir="")
Adds information about a connected edge.
void addFollowerProbability(ROJTREdge *follower, SUMOTime begTime, SUMOTime endTime, SUMOReal probability)
adds the information about the percentage of using a certain follower