![]() |
SUMO - Simulation of Urban MObility
|
#include <TrafficLight.h>
Static Public Member Functions | |
static std::vector< TraCILogic > | getCompleteRedYellowGreenDefinition (const std::string &tlsID) |
static std::vector< std::string > | getControlledJunctions (const std::string &tlsID) |
static std::vector< std::string > | getControlledLanes (const std::string &tlsID) |
static std::vector< std::vector< TraCILink > > | getControlledLinks (const std::string &tlsID) |
static int | getIDCount () |
static std::vector< std::string > | getIDList () |
static double | getNextSwitch (const std::string &tlsID) |
static std::string | getParameter (const std::string &tlsID, const std::string ¶mName) |
static int | getPhase (const std::string &tlsID) |
static double | getPhaseDuration (const std::string &tlsID) |
static std::string | getProgram (const std::string &tlsID) |
static std::string | getRedYellowGreenState (const std::string &tlsID) |
static bool | handleVariable (const std::string &objID, const int variable, VariableWrapper *wrapper) |
static LIBSUMO_SUBSCRIPTION_API std::shared_ptr< VariableWrapper > | makeWrapper () |
static void | setCompleteRedYellowGreenDefinition (const std::string &tlsID, const TraCILogic &logic) |
static void | setParameter (const std::string &tlsID, const std::string ¶mName, const std::string &value) |
static void | setPhase (const std::string &tlsID, const int index) |
static void | setPhaseDuration (const std::string &tlsID, const double phaseDuration) |
static void | setProgram (const std::string &tlsID, const std::string &programID) |
static void | setRedYellowGreenState (const std::string &tlsID, const std::string &state) |
Private Member Functions | |
TrafficLight ()=delete | |
invalidated standard constructor More... | |
Static Private Member Functions | |
static MSTLLogicControl::TLSLogicVariants & | getTLS (const std::string &id) |
Static Private Attributes | |
static ContextSubscriptionResults | myContextSubscriptionResults |
static SubscriptionResults | mySubscriptionResults |
Definition at line 54 of file TrafficLight.h.
|
privatedelete |
invalidated standard constructor
|
static |
Definition at line 65 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getAllLogics(), getTLS(), STEPS2TIME, and libsumo::TraCILogic::subParameter.
Referenced by TraCIServerAPI_TrafficLight::processGet().
|
static |
Definition at line 81 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), MSTrafficLightLogic::getLinks(), and getTLS().
Referenced by handleVariable().
|
static |
Definition at line 94 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), MSTrafficLightLogic::getLaneVectors(), and getTLS().
Referenced by handleVariable().
|
static |
Definition at line 107 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), Named::getID(), MSLink::getLane(), MSTrafficLightLogic::getLaneVectors(), MSTrafficLightLogic::getLinks(), getTLS(), and MSLink::getViaLane().
Referenced by TraCIServerAPI_TrafficLight::processGet().
|
static |
Definition at line 53 of file TrafficLight.cpp.
References getIDList().
Referenced by handleVariable().
|
static |
Definition at line 47 of file TrafficLight.cpp.
References MSTLLogicControl::getAllTLIds(), MSNet::getInstance(), and MSNet::getTLSControl().
Referenced by getIDCount(), and handleVariable().
|
static |
Definition at line 149 of file TrafficLight.cpp.
References getTLS(), and STEPS2TIME.
Referenced by handleVariable().
|
static |
Definition at line 155 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), Parameterised::getParameter(), and getTLS().
Referenced by TraCIServerAPI_TrafficLight::processGet().
|
static |
Definition at line 137 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), MSTrafficLightLogic::getCurrentPhaseIndex(), and getTLS().
Referenced by handleVariable().
|
static |
Definition at line 143 of file TrafficLight.cpp.
References getTLS(), and STEPS2TIME.
Referenced by handleVariable().
|
static |
Definition at line 131 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), MSTrafficLightLogic::getProgramID(), and getTLS().
Referenced by handleVariable().
|
static |
Definition at line 59 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), MSTrafficLightLogic::getCurrentPhaseDef(), MSPhaseDefinition::getState(), and getTLS().
Referenced by handleVariable().
|
staticprivate |
Definition at line 228 of file TrafficLight.cpp.
References MSTLLogicControl::get(), MSNet::getInstance(), and MSNet::getTLSControl().
Referenced by getCompleteRedYellowGreenDefinition(), getControlledJunctions(), getControlledLanes(), getControlledLinks(), getNextSwitch(), getParameter(), getPhase(), getPhaseDuration(), getProgram(), getRedYellowGreenState(), setCompleteRedYellowGreenDefinition(), setParameter(), setPhase(), setPhaseDuration(), setProgram(), and setRedYellowGreenState().
|
static |
Definition at line 243 of file TrafficLight.cpp.
References getControlledJunctions(), getControlledLanes(), getIDCount(), getIDList(), getNextSwitch(), getPhase(), getPhaseDuration(), getProgram(), getRedYellowGreenState(), ID_COUNT, TL_CONTROLLED_JUNCTIONS, TL_CONTROLLED_LANES, TL_CURRENT_PHASE, TL_CURRENT_PROGRAM, TL_NEXT_SWITCH, TL_PHASE_DURATION, TL_RED_YELLOW_GREEN_STATE, TRACI_ID_LIST, libsumo::VariableWrapper::wrapDouble(), libsumo::VariableWrapper::wrapInt(), libsumo::VariableWrapper::wrapString(), and libsumo::VariableWrapper::wrapStringList().
Referenced by makeWrapper(), and TraCIServerAPI_TrafficLight::processGet().
|
static |
Definition at line 237 of file TrafficLight.cpp.
References handleVariable(), myContextSubscriptionResults, and mySubscriptionResults.
|
static |
Definition at line 199 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::addLogic(), libsumo::TraCILogic::currentPhaseIndex, libsumo::TraCIPhase::duration, MSNet::getInstance(), MSTLLogicControl::TLSLogicVariants::getLogic(), getTLS(), libsumo::TraCIPhase::maxDur, libsumo::TraCIPhase::minDur, libsumo::TraCIPhase::next, libsumo::TraCILogic::phases, libsumo::TraCILogic::programID, libsumo::TraCIPhase::state, libsumo::TraCILogic::subParameter, TIME2STEPS, and TLTYPE_STATIC.
Referenced by TraCIServerAPI_TrafficLight::processSet().
|
static |
Definition at line 219 of file TrafficLight.cpp.
References MSTLLogicControl::TLSLogicVariants::getActive(), getTLS(), LIBSUMO_SUBSCRIPTION_IMPLEMENTATION, and Parameterised::setParameter().
Referenced by TraCIServerAPI_TrafficLight::processSet().
|
static |
Definition at line 167 of file TrafficLight.cpp.
References MSTrafficLightLogic::changeStepAndDuration(), MSPhaseDefinition::duration, MSTLLogicControl::TLSLogicVariants::getActive(), MSNet::getCurrentTimeStep(), MSNet::getInstance(), MSTrafficLightLogic::getPhase(), MSTrafficLightLogic::getPhaseNumber(), getTLS(), and toString().
Referenced by TraCIServerAPI_TrafficLight::processSet().
|
static |
Definition at line 190 of file TrafficLight.cpp.
References MSTrafficLightLogic::changeStepAndDuration(), MSTLLogicControl::TLSLogicVariants::getActive(), MSTrafficLightLogic::getCurrentPhaseIndex(), MSNet::getCurrentTimeStep(), MSNet::getInstance(), getTLS(), and TIME2STEPS.
Referenced by TraCIServerAPI_TrafficLight::processSet().
|
static |
Definition at line 180 of file TrafficLight.cpp.
References MSNet::getInstance(), getTLS(), and MSTLLogicControl::TLSLogicVariants::switchTo().
Referenced by TraCIServerAPI_TrafficLight::processSet().
|
static |
Definition at line 161 of file TrafficLight.cpp.
References MSNet::getInstance(), getTLS(), and MSTLLogicControl::TLSLogicVariants::setStateInstantiatingOnline().
Referenced by TraCIServerAPI_TrafficLight::processSet().
|
staticprivate |
Definition at line 92 of file TrafficLight.h.
Referenced by makeWrapper().
|
staticprivate |
Definition at line 91 of file TrafficLight.h.
Referenced by makeWrapper().