50 #ifdef CHECK_MEMORY_LEAKS
52 #endif // CHECK_MEMORY_LEAKS
59 : myVehicleTypes(), myDefaultVTypeMayBeDeleted(true),
60 myRoutesOutput(0), myRouteAlternativesOutput(0), myTypesOutput(0),
61 myReadRouteNo(0), myDiscardedRouteNo(0), myWrittenRouteNo(0),
62 myHaveRestrictions(false),
63 myNumInternalEdges(0) {
104 std::map<std::string, SUMOVehicleParameter::Stop*>::const_iterator it =
myBusStops.find(
id);
106 WRITE_ERROR(
"The bus stop '" +
id +
"' occurs at least twice.");
120 RONet::openOutput(
const std::string& filename,
const std::string altFilename,
const std::string typeFilename) {
121 if (filename !=
"") {
124 myRoutesOutput->
writeAttr(
"xmlns:xsi",
"http://www.w3.org/2001/XMLSchema-instance").
writeAttr(
"xsi:noNamespaceSchemaLocation",
"http://sumo-sim.org/xsd/routes_file.xsd");
126 if (altFilename !=
"") {
131 if (typeFilename !=
"") {
133 myTypesOutput->
writeXMLHeader(
"routes",
"xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"http://sumo-sim.org/xsd/routes_file.xsd\"");
168 return it2->second->get();
208 WRITE_ERROR(
"The vehicle type '" + type->
id +
"' occurs at least twice.");
233 WRITE_ERROR(
"The vehicle '" +
id +
"' occurs at least twice.");
254 myPersons.insert(std::pair<const SUMOTime, const std::string>(depart, desc));
263 std::string noRouteMsg =
"The vehicle '" + veh->
getID() +
"' has no valid route.";
276 if (current == 0 || current->
size() == 0) {
282 if (options.
getBool(
"remove-loops")) {
285 if (current->
size() == 0) {
287 mh->
inform(noRouteMsg +
" (after removing loops)");
299 std::vector<std::string> toRemove;
307 if (depart >= time +
DELTA_T) {
325 toRemove.push_back(i->first);
328 for (std::vector<std::string>::const_iterator i = toRemove.begin(); i != toRemove.end(); ++i) {
344 PersonMap::iterator person =
myPersons.begin();
347 if (vehicleTime > time && personTime > time) {
348 lastTime =
MIN2(vehicleTime, personTime);
351 if (vehicleTime < personTime) {
353 if (lastTime != vehicleTime && lastTime != -1) {
355 if (options.
getInt(
"stats-period") >= 0 && ((
int) vehicleTime % options.
getInt(
"stats-period")) == 0) {
359 lastTime = vehicleTime;
406 const std::map<std::string, ROEdge*>&