49 #pragma warning(disable: 4355) 53 MEVehicle(pars, route, type, speedFactor),
75 ret->
mkItem(
"waiting time [s]",
true,
115 std::ostringstream str;
116 for (std::vector<MSDevice*>::const_iterator i =
myDevices.begin(); i !=
myDevices.end(); ++i) {
120 str << (*i)->getID().substr(0, (*i)->getID().find(
getID()));
122 ret->
mkItem(
"devices",
false, str.str());
146 ret->
mkItem(
"Type Information:",
false,
"");
176 switch (activeScheme) {
223 for (; i != r.
end(); ++i) {
240 std::string result =
"";
double getBlockTimeSeconds() const
Returns the time at which the vehicle was blocked on the current segment.
const MSVehicleType * myType
This Vehicle's type.
A vehicle from the mesoscopic point of view.
std::string getStopInfo() const
retrieve information about the current stop state
static void drawBoxLines(const PositionVector &geom, const std::vector< double > &rots, const std::vector< double > &lengths, double width, int cornerDetail=0, double offset=0)
Draws thick lines.
void drawAction_drawVehicleAsBoxPlus() const
Stores the information about how to visualize structures.
const SUMOVehicleParameter & getParameter() const
Returns the vehicle's parameter (including departure definition)
std::string time2string(SUMOTime t)
GUIParameterTableWindow * getTypeParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own type parameter window.
SUMOTime getDepartDelay() const
Returns the depart delay.
bool isSelected(GUIGlObjectType type, GUIGlID id)
Returns the information whether the object with the given type and id is selected.
const SUMOVehicleParameter * myParameter
This Vehicle's parameter.
The base class for microscopic and mesoscopic vehicles.
double getEventTimeSeconds() const
Returns the earliest leave time for the current segment.
const std::vector< double > & getShapeRotations() const
int getPersonCapacity() const
Get this vehicle type's person capacity.
double getNaviDegree() const
return the current angle in navigational degrees
int getNumberReroutes() const
Returns the number of new routes this vehicle got.
int getContainerCapacity() const
Get this vehicle type's container capacity.
The car-following model and parameter.
Representation of a lane in the micro simulation (gui-version)
double getChosenSpeedFactor() const
Returns the precomputed factor by which the driver wants to be faster than the speed limit...
double getMaxSpeed() const
Returns the maximum speed.
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
GUIMEVehicle(SUMOVehicleParameter *pars, const MSRoute *route, const MSVehicleType *type, const double speedFactor)
Constructor.
MESegment * getSegment() const
Returns the current segment the vehicle is on.
const MSEdge * getEdge() const
Returns the edge the vehicle is currently at.
~GUIMEVehicle()
destructor
ConstMSEdgeVector::const_iterator MSRouteIterator
bool isStopped() const
Returns whether the vehicle is at a stop.
void selectBlockingFoes() const
adds the blocking foes to the current selection
double getColorValue(int activeScheme) const
gets the color value according to the current scheme index
A MSVehicle extended by some values for usage within the gui.
const PositionVector & getShape() const
double getMinGap() const
Get the free space in front of vehicles of this class.
static std::string getName(const SUMOEmissionClass c)
Checks whether the string describes a known vehicle class.
StringBijection< SUMOVehicleClass > SumoVehicleClassStrings(sumoVehicleClassStringInitializer, SVC_CUSTOM2, false)
const SUMOVTypeParameter & getParameter() const
std::string line
The vehicle's line (mainly for public transport)
double getVehicleMaxSpeed(const SUMOVehicle *const veh) const
Returns the maximum speed the vehicle may use on this edge.
bool drawAction_drawCarriageClass(const GUIVisualizationSettings &s, SUMOVehicleShape guiShape, bool asImage) const
draws the given guiShape if it has distinc carriages/modules and eturns true if so ...
Structure representing possible vehicle parameter.
SUMOVehicleShape
Definition of vehicle classes to differ between different appearences.
double getLastEntryTimeSeconds() const
Returns the entry time for the current segment.
const std::map< std::string, std::string > & getMap() const
Returns the inner key/value map.
const std::vector< double > & getShapeLengths() const
const std::string & getID() const
Returns the name of the vehicle type.
double getLength() const
Get vehicle's length [m].
bool isParking() const
Returns whether the vehicle is parking.
GUIGlID getGlID() const
Returns the numerical id of the object.
double getLastLaneChangeOffset() const
Returns the time since the last lane change in seconds.
double getPositionOnLane() const
Get the vehicle's position along the lane.
double getCurrentLinkPenaltySeconds() const
Returns the delay that is accrued due to option –meso-tls-penalty or –meso-minor-penalty.
MSRouteIterator begin() const
Returns the begin of the list of edges to pass.
double getSpeed() const
Returns the vehicle's estimated speed assuming no delays.
const std::string & getID() const
Returns the name of the vehicle.
void mkItem(const char *name, bool dynamic, ValueSource< unsigned > *src)
Adds a row which obtains its value from an unsigned-ValueSource.
GUISelectedStorage gSelected
A global holder of selected objects.
void closeBuilding()
Closes the building of the table.
const MSEdge & getEdge() const
Returns the edge this segment belongs to.
std::vector< MSDevice * > myDevices
The devices this vehicle has.
A window containing a gl-object's parameter.
SUMOEmissionClass getEmissionClass() const
Get this vehicle type's emission class.
MSRouteIterator end() const
Returns the end of the list of edges to pass.
void drawRouteHelper(const MSRoute &r, double exaggeration) const
Draws the route.
SUMOVehicleClass getVehicleClass() const
Get this vehicle type's vehicle class.
double getWaitingSeconds() const
Returns the number of seconds waited (speed was lesser than 0.1m/s)