42 #ifdef CHECK_MEMORY_LEAKS 44 #endif // CHECK_MEMORY_LEAKS 60 fclass = fclass.substr(0, fclass.find_first_of(
"@"));
OutputDevice & writeAttr(const SumoXMLAttr attr, const T &val)
writes a named attribute
virtual Position getPosition(const SUMOReal offset=0) const =0
Return current position (x/y, cartesian)
virtual bool isOnRoad() const =0
Returns the information whether the vehicle is on a road (is simulated)
Representation of a vehicle in the micro simulation.
virtual SUMOReal getAngle() const =0
Get the vehicle's angle.
constVehIt loadedVehBegin() const
Returns the begin of the internal vehicle map.
static Emissions computeAll(const SUMOEmissionClass c, const double v, const double a, const double slope)
Returns the amount of all emitted pollutants given the vehicle type and state (in mg/s or ml/s for fu...
std::string time2string(SUMOTime t)
Storage for collected values of all emission types.
static MSNet * getInstance()
Returns the pointer to the unique instance of MSNet (singleton).
SUMOReal x() const
Returns the x-position.
static SUMOReal computeNoise(SUMOEmissionClass c, double v, double a)
Returns the noise produced by the a vehicle of the given type at the given speed. ...
const std::string & getID() const
Returns the id.
void setPrecision(unsigned int precision=OUTPUT_ACCURACY)
Sets the precison or resets it to default.
virtual SUMOReal getPositionOnLane() const =0
Get the vehicle's position along the lane.
Representation of a vehicle.
virtual SUMOReal getSpeed() const =0
Returns the vehicle's current speed.
MSVehicleControl & getVehicleControl()
Returns the vehicle control.
static std::string getName(const SUMOEmissionClass c)
Checks whether the string describes a known vehicle class.
virtual const MSVehicleType & getVehicleType() const =0
Returns the vehicle's type.
static SUMOReal naviDegree(const SUMOReal angle)
virtual const MSRoute & getRoute() const =0
Returns the current route.
SUMOReal y() const
Returns the y-position.
const std::string & getID() const
Returns the name of the vehicle type.
virtual const std::string & getID() const =0
Get the vehicle's ID.
std::map< std::string, SUMOVehicle * >::const_iterator constVehIt
Definition of the internal vehicles map iterator.
SUMOReal getWaitingSeconds() const
Returns the number of seconds waited (speed was lesser than 0.1m/s)
virtual SUMOReal getAcceleration() const =0
Returns the vehicle's acceleration.
static void write(OutputDevice &of, SUMOTime timestep, int precision)
Writes the complete network state of the given edges into the given device.
Static storage of an output device and its base (abstract) implementation.
bool closeTag()
Closes the most recently opened tag.
constVehIt loadedVehEnd() const
Returns the end of the internal vehicle map.
The class responsible for building and deletion of vehicles.
virtual SUMOReal getSlope() const =0
Returns the slope of the road at vehicle's position.
SUMOEmissionClass getEmissionClass() const
Get this vehicle type's emission class.
MSLane * getLane() const
Returns the lane the vehicle is on.
OutputDevice & openTag(const std::string &xmlElement)
Opens an XML tag.