예제 #1
0
 public double GetLastStepOccupancy(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_INDUCTIONLOOP_VARIABLE,
              TraCIConstants.LAST_STEP_OCCUPANCY));
 }
예제 #2
0
 /// <summary>
 /// Sets a new maximum allowed speed on the lane in m/s.
 /// </summary>
 public TraCIResponse <object> SetMaxSpeed(string laneId, double maxSpeed)
 {
     return(TraCICommandHelper.ExecuteSetCommand <object, double>(
                Client,
                laneId,
                TraCIConstants.CMD_SET_LANE_VARIABLE,
                TraCIConstants.VAR_MAXSPEED,
                maxSpeed));
 }
예제 #3
0
 /// <summary>
 /// Returns the id of the edge this lane belongs to
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <string> GetEdgeId(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <string>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LANE_EDGE_ID));
 }
예제 #4
0
 /// <summary>
 /// Returns the estimated travel time for the last time step on the given lane [s]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetTravelTime(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_CURRENT_TRAVELTIME));
 }
예제 #5
0
 /// <summary>
 /// Sets a list of disallowed vehicle classes.
 /// </summary>
 public TraCIResponse <object> SetDisallowed(string laneId, List <string> disallowedVehicleClasses)
 {
     return(TraCICommandHelper.ExecuteSetCommand <object, List <string> >(
                Client,
                laneId,
                TraCIConstants.CMD_SET_LANE_VARIABLE,
                TraCIConstants.LANE_DISALLOWED,
                disallowedVehicleClasses));
 }
예제 #6
0
 /// <summary>
 /// Returns the list of ids of vehicles that were on this lane in the last simulation step
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <List <string> > GetLastStepVehicleIds(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <List <string> >(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LAST_STEP_VEHICLE_ID_LIST));
 }
예제 #7
0
 /// <summary>
 /// The mean length of vehicles which were on this lane in the last step [m]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetLastStepLength(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LAST_STEP_LENGTH));
 }
예제 #8
0
 public List <string> GetEdges(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <List <string> >(
              Client,
              id,
              TraCIConstants.CMD_GET_ROUTE_VARIABLE,
              TraCIConstants.VAR_EDGES));
 }
예제 #9
0
 public List <string> GetIdList()
 {
     return
         (TraCICommandHelper.ExecuteCommand <List <string> >(
              Client,
              "ignored",
              TraCIConstants.CMD_GET_ROUTE_VARIABLE,
              TraCIConstants.ID_LIST));
 }
예제 #10
0
 public Position2D GetPosition(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <Position2D>(
              Client,
              id,
              TraCIConstants.CMD_GET_POI_VARIABLE,
              TraCIConstants.VAR_POSITION));
 }
예제 #11
0
 public int GetIdCount()
 {
     return
         (TraCICommandHelper.ExecuteCommand <int>(
              Client,
              "ignored",
              TraCIConstants.CMD_GET_ROUTE_VARIABLE,
              TraCIConstants.ID_COUNT));
 }
예제 #12
0
 public Color GetColor(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <Color>(
              Client,
              id,
              TraCIConstants.CMD_GET_POI_VARIABLE,
              TraCIConstants.VAR_COLOR));
 }
예제 #13
0
 public string GetType(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <string>(
              Client,
              id,
              TraCIConstants.CMD_GET_POI_VARIABLE,
              TraCIConstants.VAR_TYPE));
 }
예제 #14
0
 public double GetLastStepMeanLength(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_INDUCTIONLOOP_VARIABLE,
              TraCIConstants.LAST_STEP_LENGTH));
 }
예제 #15
0
 /// <summary>
 /// Returns the mean speed of vehicles that were on this lane within the last simulation step [m/s]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetLastStepMeanSpeed(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LAST_STEP_MEAN_SPEED));
 }
예제 #16
0
 /// <summary>
 /// Returns the maximum speed allowed on this lane [m/s]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetMaxSpeed(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_MAXSPEED));
 }
예제 #17
0
 /// <summary>
 /// Returns the number of lanes within the scenario (the given Lane ID is ignored)
 /// </summary>
 /// <returns></returns>
 public TraCIResponse <int> GetIdCount()
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <int>(
              Client,
              "ignored",
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.ID_COUNT));
 }
예제 #18
0
 /// <summary>
 /// Returns this lane's shape
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <Polygon> GetShape(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <Polygon>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_SHAPE));
 }
예제 #19
0
 /// <summary>
 /// Returns the total lengths of vehicles on this lane during the last simulation step divided by the length of this lane
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetLastStepOccupancy(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LAST_STEP_OCCUPANCY));
 }
예제 #20
0
 /// <summary>
 /// Returns the width of the named lane [m]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetWidth(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_WIDTH));
 }
예제 #21
0
 /// <summary>
 /// Returns the waiting time for all vehicles on the lane [s]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetWaitingTime(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_WAITING_TIME));
 }
예제 #22
0
 /// <summary>
 /// Returns a list of ids of all lanes within the scenario (the given Lane ID is ignored)
 /// </summary>
 /// <returns></returns>
 public TraCIResponse <List <string> > GetIdList()
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <List <string> >(
              Client,
              "ignored",
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.ID_LIST));
 }
예제 #23
0
 /// <summary>
 /// Returns the total number of halting vehicles for the last time step on the given lane.
 /// A speed of less than 0.1 m/s is considered a halt.
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <int> GetLastStepHaltingNumber(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <int>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LAST_STEP_VEHICLE_HALTING_NUMBER));
 }
예제 #24
0
 /// <summary>
 /// Sum of fuel consumption on this lane in ml during this time step.
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetFuelConsumption(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_FUELCONSUMPTION));
 }
예제 #25
0
 /// <summary>
 /// Sets the length of the lane in m
 /// </summary>
 public TraCIResponse <object> SetLength(string laneId, double length)
 {
     return(TraCICommandHelper.ExecuteSetCommand <object, double>(
                Client,
                laneId,
                TraCIConstants.CMD_SET_LANE_VARIABLE,
                TraCIConstants.VAR_LENGTH,
                length));
 }
예제 #26
0
 /// <summary>
 /// Sum of noise generated on this lane in dBA.
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetNoiseEmission(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_NOISEEMISSION));
 }
예제 #27
0
 /// <summary>
 /// Returns the number of links outgoing from this lane [#]
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <byte> GetLinkNumber(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <byte>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LANE_LINK_NUMBER));
 }
예제 #28
0
 /// <summary>
 /// Sum of electricity consumption on this lane in kWh during this time step.
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <double> GetElectricityConsumption(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <double>(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.VAR_ELECTRICITYCONSUMPTION));
 }
예제 #29
0
 /// <summary>
 /// Returns the mml-definitions of vehicle classes allowed on this lane
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public TraCIResponse <List <string> > GetAllowed(string id)
 {
     return
         (TraCICommandHelper.ExecuteGetCommand <List <string> >(
              Client,
              id,
              TraCIConstants.CMD_GET_LANE_VARIABLE,
              TraCIConstants.LANE_ALLOWED));
 }
예제 #30
0
 public List <string> GetLastStepVehicleIds(string id)
 {
     return
         (TraCICommandHelper.ExecuteCommand <List <string> >(
              Client,
              id,
              TraCIConstants.CMD_GET_INDUCTIONLOOP_VARIABLE,
              TraCIConstants.LAST_STEP_VEHICLE_ID_LIST));
 }