SUMO - Simulation of Urban MObility
|
A model of the street in the city. More...
#include <AGStreet.h>
Public Member Functions | |
AGStreet (const ROEdge *edge, SUMOReal popD=0, SUMOReal workD=0) | |
SUMOReal | getLength () const |
Provides the length of this edge. | |
const std::string & | getName () const |
Provides the id of this edge. | |
int | getPopulation () const |
Provides the number of persons living in this street. | |
int | getWorkplaceNumber () const |
Provides the number of work places in this street. | |
void | print () const |
Prints a summary of the properties of this street to standard output. | |
void | setPopulation (const int &pop) |
Modifies the number of persons living in this street. | |
void | setWorkplaceNumber (const int &work) |
Modifies the number of work places in this street. | |
Private Attributes | |
const ROEdge * | edge |
int | pop |
int | work |
Friends | |
class | AGPosition |
A model of the street in the city.
AGStreet represents a street in the city. It contains all model relevant properties and is associated with a ROEdge of the routing network.
Definition at line 57 of file AGStreet.h.
AGStreet::AGStreet | ( | const ROEdge * | edge, |
SUMOReal | popD = 0 , |
||
SUMOReal | workD = 0 |
||
) |
Definition at line 43 of file AGStreet.cpp.
References ROEdge::getLength(), pop, and work.
SUMOReal AGStreet::getLength | ( | ) | const |
Provides the length of this edge.
Definition at line 59 of file AGStreet.cpp.
References edge, and ROEdge::getLength().
Referenced by AGPosition::compute2dPosition(), AGPosition::print(), and AGPosition::randomPositionInStreet().
const std::string & AGStreet::getName | ( | ) | const |
Provides the id of this edge.
Definition at line 66 of file AGStreet.cpp.
References edge, and ROEdge::getID().
Referenced by AGActivityTripWriter::addTrip().
int AGStreet::getPopulation | ( | ) | const |
Provides the number of persons living in this street.
Definition at line 73 of file AGStreet.cpp.
References pop.
int AGStreet::getWorkplaceNumber | ( | ) | const |
Provides the number of work places in this street.
Definition at line 87 of file AGStreet.cpp.
References work.
void AGStreet::print | ( | ) | const |
Prints a summary of the properties of this street to standard output.
Definition at line 52 of file AGStreet.cpp.
References edge, ROEdge::getID(), ROEdge::getLength(), pop, and work.
void AGStreet::setPopulation | ( | const int & | pop | ) |
Modifies the number of persons living in this street.
[in] | pop | the new number of inhabitants |
Definition at line 80 of file AGStreet.cpp.
References pop.
void AGStreet::setWorkplaceNumber | ( | const int & | work | ) |
Modifies the number of work places in this street.
[in] | work | the new number of work places |
Definition at line 94 of file AGStreet.cpp.
References work.
friend class AGPosition [friend] |
Definition at line 103 of file AGStreet.h.
const ROEdge* AGStreet::edge [private] |
Definition at line 105 of file AGStreet.h.
Referenced by AGPosition::compute2dPosition(), getLength(), getName(), and print().
int AGStreet::pop [private] |
Definition at line 106 of file AGStreet.h.
Referenced by AGStreet(), getPopulation(), print(), and setPopulation().
int AGStreet::work [private] |
Definition at line 107 of file AGStreet.h.
Referenced by AGStreet(), getWorkplaceNumber(), print(), and setWorkplaceNumber().