40 #ifdef CHECK_MEMORY_LEAKS
42 #endif // CHECK_MEMORY_LEAKS
48 using namespace traci;
57 std::string warning =
"";
99 std::vector<MSTrafficLightLogic*> logics = vars.
getAllLogics();
102 unsigned int cnt = 0;
104 tempContent.
writeInt((
int) logics.size());
106 for (
unsigned int i = 0; i < logics.size(); ++i) {
126 tempContent.
writeInt((
int) phaseNo);
128 for (
unsigned int j = 0; j < phaseNo; ++j) {
139 const std::string& state = phase.
getState();
153 std::vector<std::string> laneIDs;
154 for (MSTrafficLightLogic::LaneVectorVector::const_iterator i = lanes.begin(); i != lanes.end(); ++i) {
156 for (MSTrafficLightLogic::LaneVector::const_iterator j = llanes.begin(); j != llanes.end(); ++j) {
157 laneIDs.push_back((*j)->getID());
169 unsigned int cnt = 0;
171 unsigned int no = (
unsigned int) lanes.size();
173 for (
unsigned int i = 0; i < no; ++i) {
178 unsigned int no2 = (
unsigned int) llanes.size();
181 for (
unsigned int j = 0; j < no2; ++j) {
183 std::vector<std::string> def;
185 def.push_back(llanes[j]->getID());
189 #ifdef HAVE_INTERNAL_LANES
190 def.push_back(link->getViaLane() != 0 ? link->getViaLane()->getID() :
"");
235 std::string warning =
"";
258 int index = inputStorage.
readInt();
272 std::string subID = inputStorage.
readString();
286 int duration = inputStorage.
readInt();
297 std::string state = inputStorage.
readString();
300 std::vector<MSPhaseDefinition*> phases;
301 phases.push_back(phase);
303 vars.
addLogic(
"online", logic,
true,
true);
324 std::string subid = inputStorage.
readString();
341 int index = inputStorage.
readInt();
346 int phaseNo = inputStorage.
readInt();
348 if (index >= phaseNo) {
353 std::vector<MSPhaseDefinition*> phases;
354 for (
int j = 0; j < phaseNo; ++j) {
359 int duration = inputStorage.
readInt();
364 int minDuration = inputStorage.
readInt();
369 int maxDuration = inputStorage.
readInt();
374 std::string state = inputStorage.
readString();
376 phases.push_back(phase);
380 vars.
addLogic(subid, logic,
true,
true);