40 const std::string
id = inputStorage.
readString();
43 if (!libsumo::Junction::handleVariable(
id, variable, &server, &inputStorage)) {
58 std::string warning =
"";
71 StoHelp::readCompound(inputStorage, 2,
"A compound object of size 2 is needed for setting a parameter.");
72 const std::string name =
StoHelp::readTypedString(inputStorage,
"The name of the parameter must be given as a string.");
73 const std::string value =
StoHelp::readTypedString(inputStorage,
"The value of the parameter must be given as a string.");
74 libsumo::Junction::setParameter(
id, name, value);
std::string toHex(const T i, std::streamsize numDigits=0)
static bool processSet(TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage)
Processes a set value command (Command 0xc9: Set Junction Variable)
static bool processGet(TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage)
Processes a get value command (Command 0xa9: Get Junction Variable)
TraCI server used to control sumo by a remote TraCI client.
void writeStatusCmd(int commandId, int status, const std::string &description, tcpip::Storage &outputStorage)
Writes a status command to the given storage.
tcpip::Storage & getWrapperStorage()
void initWrapper(const int domainID, const int variable, const std::string &objID)
bool writeErrorStatusCmd(int commandId, const std::string &description, tcpip::Storage &outputStorage)
Writes a status command to the given storage with status = RTYPE_ERR.
void writeResponseWithLength(tcpip::Storage &outputStorage, tcpip::Storage &tempMsg)
static int readCompound(tcpip::Storage &ret, int expectedSize=-1, const std::string &error="")
static std::string readTypedString(tcpip::Storage &ret, const std::string &error="")
An error which allows to continue.
virtual std::string readString()
virtual int readUnsignedByte()
TRACI_CONST int CMD_SET_JUNCTION_VARIABLE
TRACI_CONST int CMD_GET_JUNCTION_VARIABLE
TRACI_CONST int VAR_PARAMETER
TRACI_CONST int RESPONSE_GET_JUNCTION_VARIABLE