42std::vector<std::string>
44 std::vector<std::string> ids;
46 ids.push_back(item.first);
48 std::sort(ids.begin(), ids.end());
53BusStop::getIDCount() {
54 return (
int)getIDList().size();
65 return getBusStop(stopID)->getBeginLanePosition();
70 return getBusStop(stopID)->getEndLanePosition();
80 return (
int)
getBusStop(stopID)->getStoppedVehicles().size();
83std::vector<std::string>
85 std::vector<std::string> result;
87 result.push_back(veh->getID());
94 return (
int)
getBusStop(stopID)->getNumWaitingPersons();
97std::vector<std::string>
99 std::vector<std::string> result;
100 getBusStop(stopID)->getWaitingPersonIDs(result);
106BusStop::getParameter(
const std::string& stopID,
const std::string& param) {
107 return getBusStop(stopID)->getParameter(param,
"");
113BusStop::setParameter(
const std::string& stopID,
const std::string& key,
const std::string&
value) {
114 getBusStop(stopID)->setParameter(key,
value);
127std::shared_ptr<VariableWrapper>
137 return wrapper->wrapStringList(objID, variable, getIDList());
139 return wrapper->wrapInt(objID, variable, getIDCount());
141 return wrapper->wrapString(objID, variable,
getLaneID(objID));
143 return wrapper->wrapDouble(objID, variable,
getStartPos(objID));
145 return wrapper->wrapDouble(objID, variable,
getEndPos(objID));
147 return wrapper->wrapString(objID, variable,
getName(objID));
151 return wrapper->wrapStringList(objID, variable,
getVehicleIDs(objID));
155 return wrapper->wrapStringList(objID, variable,
getPersonIDs(objID));
158 return wrapper->wrapString(objID, variable, getParameter(objID, paramData->
readString()));
161 return wrapper->wrapStringPair(objID, variable, getParameterWithKey(objID, paramData->
readString()));
const std::string invalid_return< std::string >::value
@ SUMO_TAG_BUS_STOP
A bus stop.
#define LIBSUMO_SUBSCRIPTION_IMPLEMENTATION(CLASS, DOM)
#define LIBSUMO_GET_PARAMETER_WITH_KEY_IMPLEMENTATION(CLASS)
C++ TraCI client API implementation.
LIBSUMO_ID_PARAMETER_API static LIBSUMO_SUBSCRIPTION_API std::shared_ptr< VariableWrapper > makeWrapper()
static ContextSubscriptionResults myContextSubscriptionResults
static int getVehicleCount(const std::string &stopID)
static double getEndPos(const std::string &stopID)
static MSStoppingPlace * getBusStop(const std::string &id)
static std::string getName(const std::string &stopID)
static int getPersonCount(const std::string &stopID)
static double getStartPos(const std::string &stopID)
static bool handleVariable(const std::string &objID, const int variable, VariableWrapper *wrapper, tcpip::Storage *paramData)
static std::vector< std::string > getVehicleIDs(const std::string &stopID)
static std::vector< std::string > getPersonIDs(const std::string &stopID)
static SubscriptionResults mySubscriptionResults
static std::string getLaneID(const std::string &stopID)
static MSNet * getInstance()
Returns the pointer to the unique instance of MSNet (singleton).
Representation of a vehicle.
static MSStoppingPlace * getStoppingPlace(const std::string &id, const SumoXMLTag type)
virtual std::string readString()
virtual int readUnsignedByte()
TRACI_CONST int VAR_STOP_STARTING_VEHICLES_NUMBER
TRACI_CONST int TRACI_ID_LIST
std::map< std::string, libsumo::SubscriptionResults > ContextSubscriptionResults
TRACI_CONST int VAR_POSITION
std::map< std::string, libsumo::TraCIResults > SubscriptionResults
{object->{variable->value}}
TRACI_CONST int VAR_BUS_STOP_WAITING_IDS
TRACI_CONST int VAR_PARAMETER
TRACI_CONST int VAR_LANEPOSITION
TRACI_CONST int VAR_LANE_ID
TRACI_CONST int VAR_PARAMETER_WITH_KEY
TRACI_CONST int VAR_STOP_STARTING_VEHICLES_IDS
TRACI_CONST int VAR_BUS_STOP_WAITING