Package de.tudresden.sumo.cmd
Class Simulation
java.lang.Object
de.tudresden.sumo.cmd.Simulation
The Class Simulation.
- Author:
- Mario Krumnow, Evamarie Wiessner
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionstatic SumoCommandclearPending(String routeID) Clear pending.static SumoCommandconvert2D.static SumoCommandconvert3D.static SumoCommandconvertGeo(double x, double y, boolean fromGeo) convertGeo.static SumoCommandconvertRoad(double x, double y, boolean isGeo, String vClass) convertRoad.static SumoCommandfindIntermodalRoute(String fromEdge, String toEdge, String modes, double depart, int routingMode, double speed, double walkingFactor, double departPos, double arrivalPos, double departPosLat, String pType, String vType, String destStop) findIntermodalRoute.static SumoCommandfindRoute.static SumoCommandReturns a list of IDs of vehicles which arrived in this time step.static SumoCommandReturns the number of vehicles which arrived in this time step.static SumoCommandReturns the current waiting time on bus stops(in ms).static SumoCommandgetCollidingVehiclesNumber().static SumoCommandgetCollidingVehiclesNumber().static SumoCommandgetCurrentTime.static SumoCommandgetDeltaT.static SumoCommandReturns a list of IDs of vehicles which departed in this time step.static SumoCommandReturns the number of vehicles which departed in this time step.static SumoCommandgetDistance2D(double x1, double y1, double x2, double y2, boolean isGeo, boolean isDriving) static SumoCommandgetDistanceRoad(String edgeID1, double pos1, String edgeID2, double pos2, boolean isDriving) static SumoCommandgetEmergencyStoppingVehiclesIDList().static SumoCommandgetEmergencyStoppingVehiclesNumber().static SumoCommandReturns a list of IDs of vehicles which ended to be teleported in this time step.static SumoCommandReturns the number of vehicles which ended to be teleported in this time step.static SumoCommandReturns a list of IDs of vehicles which were loaded in this time step.static SumoCommandReturn the number of vehicles which were loaded in this time step.static SumoCommandReturns the number of vehicles which are in the net plus the ones still waiting to start.static SumoCommandReturns the boundary box of the simulation network.static SumoCommandgetParkingEndingVehiclesIDList().static SumoCommandgetParkingEndingVehiclesNumber().static SumoCommandgetParkingStartingVehiclesIDList().static SumoCommandgetParkingStartingVehiclesNumber().static SumoCommandReturns a list of IDs of vehicles which started to teleport in this time step.static SumoCommandReturns the number of vehicles which started to teleport in this time step.static SumoCommandgetStopEndingVehiclesIDList().static SumoCommandgetStopEndingVehiclesNumber().static SumoCommandgetStopStartingVehiclesIDList().static SumoCommandgetStopStartingVehiclesIDList().static SumoCommandgetTime()getTime.static SumoCommandsave state.
- 
Constructor Details- 
Simulationpublic Simulation()
 
- 
- 
Method Details- 
convert2Dconvert2D.- Parameters:
- edgeID- edge id
- pos- pos
- laneIndex- index
- toGeo- geo
- Returns:
- SumoCommand
 
- 
convert3Dconvert3D.- Parameters:
- edgeID- edge id
- pos- pos
- laneIndex- index
- toGeo- geo
- Returns:
- SumoCommand
 
- 
convertGeoconvertGeo.- Parameters:
- x- x
- y- y
- fromGeo- geo
- Returns:
- SumoCommand
 
- 
convertRoadconvertRoad.- Parameters:
- x- x
- y- y
- isGeo- geo
- vClass- the v class
- Returns:
- SumoCommand
 
- 
getArrivedIDListReturns a list of IDs of vehicles which arrived in this time step.- Returns:
- list of vehicles
 
- 
getArrivedNumberReturns the number of vehicles which arrived in this time step.- Returns:
- number of vehicles
 
- 
getBusStopWaitingReturns the current waiting time on bus stops(in ms).- Returns:
- waiting time
 
- 
getParkingEndingVehiclesIDListgetParkingEndingVehiclesIDList().- Returns:
- number of vehicles
 
- 
getParkingEndingVehiclesNumbergetParkingEndingVehiclesNumber().- Returns:
- number of vehicles
 
- 
getParkingStartingVehiclesIDListgetParkingStartingVehiclesIDList().- Returns:
- number of vehicles
 
- 
getParkingStartingVehiclesNumbergetParkingStartingVehiclesNumber().- Returns:
- number of vehicles
 
- 
getStopEndingVehiclesIDListgetStopEndingVehiclesIDList().- Returns:
- number of vehicles
 
- 
getCollidingVehiclesNumbergetCollidingVehiclesNumber().- Returns:
- Return number of vehicles involved in a collision (typically 2 per collision).
 
- 
getCollidingVehiclesIDListgetCollidingVehiclesNumber().- Returns:
- Return Ids of vehicles involved in a collision (typically 2 per collision)
 
- 
getEmergencyStoppingVehiclesNumbergetEmergencyStoppingVehiclesNumber().- Returns:
- Return number of vehicles that performed an emergency stop in the last step
 
- 
getEmergencyStoppingVehiclesIDListgetEmergencyStoppingVehiclesIDList().- Returns:
- Return Ids of vehicles that peformed an emergency stop in the last step
 
- 
getStopEndingVehiclesNumbergetStopEndingVehiclesNumber().- Returns:
- number of vehicles
 
- 
getStopStartingVehiclesIDListgetStopStartingVehiclesIDList().- Returns:
- list of vehicles
 
- 
getStopStartingVehiclesNumbergetStopStartingVehiclesIDList().- Returns:
- list of vehicles
 
- 
getCurrentTimegetCurrentTime.- Returns:
- current time in ms (integer). Note: this method only supports a simulation time up to 24 days and is only kept for legacy reasons
 
- 
getTimegetTime.- Returns:
- current time in s (double)
 
- 
getDeltaTgetDeltaT.- Returns:
- delat time
 
- 
getDepartedIDListReturns a list of IDs of vehicles which departed in this time step.- Returns:
- list of IDs of vehicles which departed in this time step.
 
- 
getDepartedNumberReturns the number of vehicles which departed in this time step.- Returns:
- the number of vehicles which departed in this time step.
 
- 
getDistance2Dpublic static SumoCommand getDistance2D(double x1, double y1, double x2, double y2, boolean isGeo, boolean isDriving) - Parameters:
- x1- x1
- y1- y1
- x2- x2
- y2- y2
- isGeo- is geo
- isDriving- is driving
- Returns:
- distance
 
- 
getDistanceRoadpublic static SumoCommand getDistanceRoad(String edgeID1, double pos1, String edgeID2, double pos2, boolean isDriving) - Parameters:
- edgeID1- first edge
- pos1- first position
- edgeID2- second edge
- pos2- second position
- isDriving- is drinving
- Returns:
- the distance in [m]
 
- 
getEndingTeleportIDListReturns a list of IDs of vehicles which ended to be teleported in this time step.- Returns:
- SumoCommand
 
- 
getEndingTeleportNumberReturns the number of vehicles which ended to be teleported in this time step.- Returns:
- SumoCommand
 
- 
getLoadedIDListReturns a list of IDs of vehicles which were loaded in this time step.- Returns:
- SumoCommand
 
- 
getLoadedNumberReturn the number of vehicles which were loaded in this time step. * @return SumoCommand- Returns:
- SumoCommand
 
- 
getMinExpectedNumberReturns the number of vehicles which are in the net plus the ones still waiting to start.- Returns:
- SumoCommand
 
- 
getNetBoundaryReturns the boundary box of the simulation network.- Returns:
- SumoCommand
 
- 
getStartingTeleportIDListReturns a list of IDs of vehicles which started to teleport in this time step.- Returns:
- SumoCommand
 
- 
getStartingTeleportNumberReturns the number of vehicles which started to teleport in this time step.- Returns:
- SumoCommand
 
- 
clearPendingClear pending.- Parameters:
- routeID- route id
- Returns:
- SumoCommand
 
- 
saveStatesave state.- Parameters:
- filename- the filename
- Returns:
- SumoCommand
 
- 
findRoutepublic static SumoCommand findRoute(String fromEdge, String toEdge, String vType, double depart, int routingMode) findRoute.- Parameters:
- fromEdge- first edge
- toEdge- second edge
- vType- vehicle type
- depart- depart
- routingMode- routing mode
- Returns:
- the route
 
- 
findIntermodalRoutepublic static SumoCommand findIntermodalRoute(String fromEdge, String toEdge, String modes, double depart, int routingMode, double speed, double walkingFactor, double departPos, double arrivalPos, double departPosLat, String pType, String vType, String destStop) findIntermodalRoute.- Parameters:
- fromEdge- first edge
- toEdge- second edge
- modes- modes
- depart- depart
- routingMode- routing mode
- speed- speed
- walkingFactor- walkingFactor
- departPos- departPos
- arrivalPos- arrivalPos
- departPosLat- departPosLat
- pType- pType
- vType- vType
- destStop- destStop
- Returns:
- the route
 
 
-