40 const std::string
id = inputStorage.
readString();
43 if (!libsumo::InductionLoop::handleVariable(
id, variable, &server, &inputStorage)) {
46 std::vector<libsumo::TraCIVehicleData> vd = libsumo::InductionLoop::getVehicleData(
id);
69 "Get Induction Loop Variable: unsupported variable " +
toHex(variable, 2)
70 +
" specified", outputStorage);
85 std::string warning =
"";
103 libsumo::InductionLoop::overrideTimeSinceDetection(
id, time);
107 StoHelp::readCompound(inputStorage, 2,
"A compound object of size 2 is needed for setting a parameter.");
108 const std::string name =
StoHelp::readTypedString(inputStorage,
"The name of the parameter must be given as a string.");
109 const std::string value =
StoHelp::readTypedString(inputStorage,
"The value of the parameter must be given as a string.");
110 libsumo::InductionLoop::setParameter(
id, name, value);
std::string toHex(const T i, std::streamsize numDigits=0)
static bool processGet(TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage)
Processes a get value command (Command 0xa0: Get Induction Loop Variable)
static bool processSet(TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage)
Processes a set value command (Command 0xc0: Set Induction Loop 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.
bool readTypeCheckingDouble(tcpip::Storage &inputStorage, double &into)
Reads the value type and a double, verifying the type.
void writeResponseWithLength(tcpip::Storage &outputStorage, tcpip::Storage &tempMsg)
static void writeTypedDouble(tcpip::Storage &content, double value)
static int readCompound(tcpip::Storage &ret, int expectedSize=-1, const std::string &error="")
static void writeCompound(tcpip::Storage &content, int size)
static std::string readTypedString(tcpip::Storage &ret, const std::string &error="")
static void writeTypedInt(tcpip::Storage &content, int value)
static void writeTypedString(tcpip::Storage &content, const std::string &value)
An error which allows to continue.
virtual std::string readString()
virtual int readUnsignedByte()
StorageType::size_type size() const
virtual void writeStorage(tcpip::Storage &store)
TRACI_CONST int LAST_STEP_VEHICLE_DATA
TRACI_CONST int VAR_PARAMETER
TRACI_CONST int RESPONSE_GET_INDUCTIONLOOP_VARIABLE
TRACI_CONST int CMD_SET_INDUCTIONLOOP_VARIABLE
TRACI_CONST int VAR_VIRTUAL_DETECTION
TRACI_CONST int CMD_GET_INDUCTIONLOOP_VARIABLE
mirrors MSInductLoop::VehicleData