Eclipse SUMO - Simulation of Urban MObility
Loading...
Searching...
No Matches
libsumo::StorageHelper Class Reference

#include <StorageHelper.h>

Static Public Member Functions

static void readBestLanesVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCIBestLanesData > &result, const std::string &error="")
 
static bool readBool (tcpip::Storage &ret, const std::string &error="")
 
static void readCollisionVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCICollision > &result, const std::string &error="")
 
static int readCompound (tcpip::Storage &ret, int expectedSize=-1, const std::string &error="")
 
static void readConnection (tcpip::Storage &inputStorage, libsumo::TraCIConnection &connection, const std::string &error="")
 
static void readConstraintVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCISignalConstraint > &result, const std::string &error="")
 
static void readJunctionFoeVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCIJunctionFoe > &result, const std::string &error="")
 
static void readLinkVectorVector (tcpip::Storage &inputStorage, std::vector< std::vector< libsumo::TraCILink > > &result, const std::string &error="")
 
static void readLogic (tcpip::Storage &inputStorage, libsumo::TraCILogic &logic, const std::string &error="")
 
static void readPolygon (tcpip::Storage &ret, libsumo::TraCIPositionVector &poly)
 
static void readReservation (tcpip::Storage &inputStorage, libsumo::TraCIReservation &result, const std::string &error="")
 
static void readStage (tcpip::Storage &inputStorage, libsumo::TraCIStage &stage, const std::string &error="")
 
static void readStopVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCINextStopData > &result, const std::string &error="")
 
static void readTLSDataVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCINextTLSData > &result, const std::string &error="")
 
static int readTypedByte (tcpip::Storage &ret, const std::string &error="")
 
static const libsumo::TraCIColor readTypedColor (tcpip::Storage &ret, const std::string &error="")
 
static double readTypedDouble (tcpip::Storage &ret, const std::string &error="")
 
static std::vector< double > readTypedDoubleList (tcpip::Storage &ret, const std::string &error="")
 
static int readTypedInt (tcpip::Storage &ret, const std::string &error="")
 
static const libsumo::TraCIPositionVector readTypedPolygon (tcpip::Storage &ret, const std::string &error="")
 
static const libsumo::TraCIPosition readTypedPosition2D (tcpip::Storage &ret, const std::string &error="")
 
static std::string readTypedString (tcpip::Storage &ret, const std::string &error="")
 
static std::vector< std::string > readTypedStringList (tcpip::Storage &ret, const std::string &error="")
 
static int readTypedUnsignedByte (tcpip::Storage &ret, const std::string &error="")
 
static void readVehicleDataVector (tcpip::Storage &inputStorage, std::vector< libsumo::TraCIVehicleData > &result, const std::string &error="")
 
static std::shared_ptr< tcpip::StoragetoStorage (const TraCIResult &v)
 
static void writeCompound (tcpip::Storage &content, int size)
 
static void writeConstraint (tcpip::Storage &content, const libsumo::TraCISignalConstraint &c)
 
static void writePolygon (tcpip::Storage &content, const libsumo::TraCIPositionVector &shape)
 
static void writeStage (tcpip::Storage &content, const libsumo::TraCIStage &stage)
 
static void writeTypedByte (tcpip::Storage &content, int value)
 
static void writeTypedDouble (tcpip::Storage &content, double value)
 
static void writeTypedInt (tcpip::Storage &content, int value)
 
static void writeTypedString (tcpip::Storage &content, const std::string &value)
 
static void writeTypedStringList (tcpip::Storage &content, const std::vector< std::string > &value)
 
static void writeTypedUnsignedByte (tcpip::Storage &content, int value)
 

Detailed Description

Definition at line 32 of file StorageHelper.h.

Member Function Documentation

◆ readBestLanesVector()

static void libsumo::StorageHelper::readBestLanesVector ( tcpip::Storage inputStorage,
std::vector< libsumo::TraCIBestLanesData > &  result,
const std::string &  error = "" 
)
inlinestatic

◆ readBool()

static bool libsumo::StorageHelper::readBool ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 217 of file StorageHelper.h.

References tcpip::Storage::readUnsignedByte(), and libsumo::TYPE_UBYTE.

Referenced by TraCIServerAPI_Polygon::processSet(), readBestLanesVector(), readConnection(), and readJunctionFoeVector().

Here is the caller graph for this function:

◆ readCollisionVector()

static void libsumo::StorageHelper::readCollisionVector ( tcpip::Storage inputStorage,
std::vector< libsumo::TraCICollision > &  result,
const std::string &  error = "" 
)
inlinestatic

◆ readCompound()

static int libsumo::StorageHelper::readCompound ( tcpip::Storage ret,
int  expectedSize = -1,
const std::string &  error = "" 
)
inlinestatic

◆ readConnection()

static void libsumo::StorageHelper::readConnection ( tcpip::Storage inputStorage,
libsumo::TraCIConnection connection,
const std::string &  error = "" 
)
inlinestatic

◆ readConstraintVector()

static void libsumo::StorageHelper::readConstraintVector ( tcpip::Storage inputStorage,
std::vector< libsumo::TraCISignalConstraint > &  result,
const std::string &  error = "" 
)
inlinestatic

◆ readJunctionFoeVector()

static void libsumo::StorageHelper::readJunctionFoeVector ( tcpip::Storage inputStorage,
std::vector< libsumo::TraCIJunctionFoe > &  result,
const std::string &  error = "" 
)
inlinestatic

◆ readLinkVectorVector()

static void libsumo::StorageHelper::readLinkVectorVector ( tcpip::Storage inputStorage,
std::vector< std::vector< libsumo::TraCILink > > &  result,
const std::string &  error = "" 
)
inlinestatic

Definition at line 325 of file StorageHelper.h.

References readTypedInt(), and readTypedStringList().

Referenced by libtraci::Connection::readVariables().

Here is the caller graph for this function:

◆ readLogic()

static void libsumo::StorageHelper::readLogic ( tcpip::Storage inputStorage,
libsumo::TraCILogic logic,
const std::string &  error = "" 
)
inlinestatic

◆ readPolygon()

static void libsumo::StorageHelper::readPolygon ( tcpip::Storage ret,
libsumo::TraCIPositionVector poly 
)
inlinestatic

Definition at line 203 of file StorageHelper.h.

References tcpip::Storage::readDouble(), tcpip::Storage::readInt(), tcpip::Storage::readUnsignedByte(), libsumo::TraCIPositionVector::value, libsumo::TraCIPosition::x, libsumo::TraCIPosition::y, and libsumo::TraCIPosition::z.

Referenced by libtraci::Domain< GET, SET >::getPolygon(), readTypedPolygon(), and libtraci::Connection::readVariables().

Here is the caller graph for this function:

◆ readReservation()

static void libsumo::StorageHelper::readReservation ( tcpip::Storage inputStorage,
libsumo::TraCIReservation result,
const std::string &  error = "" 
)
inlinestatic

◆ readStage()

static void libsumo::StorageHelper::readStage ( tcpip::Storage inputStorage,
libsumo::TraCIStage stage,
const std::string &  error = "" 
)
inlinestatic

◆ readStopVector()

◆ readTLSDataVector()

static void libsumo::StorageHelper::readTLSDataVector ( tcpip::Storage inputStorage,
std::vector< libsumo::TraCINextTLSData > &  result,
const std::string &  error = "" 
)
inlinestatic

Definition at line 411 of file StorageHelper.h.

References libsumo::TraCINextTLSData::dist, libsumo::TraCINextTLSData::id, readTypedByte(), readTypedDouble(), readTypedInt(), readTypedString(), libsumo::TraCINextTLSData::state, and libsumo::TraCINextTLSData::tlIndex.

Referenced by libtraci::Connection::readVariables().

Here is the caller graph for this function:

◆ readTypedByte()

static int libsumo::StorageHelper::readTypedByte ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

◆ readTypedColor()

static const libsumo::TraCIColor libsumo::StorageHelper::readTypedColor ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 161 of file StorageHelper.h.

References libsumo::TraCIColor::a, libsumo::TraCIColor::b, libsumo::TraCIColor::g, libsumo::TraCIColor::r, tcpip::Storage::readUnsignedByte(), and libsumo::TYPE_COLOR.

Referenced by TraCIServerAPI_Person::processSet(), TraCIServerAPI_POI::processSet(), TraCIServerAPI_Polygon::processSet(), TraCIServerAPI_Vehicle::processSet(), and TraCIServerAPI_VehicleType::setVariable().

Here is the caller graph for this function:

◆ readTypedDouble()

◆ readTypedDoubleList()

static std::vector< double > libsumo::StorageHelper::readTypedDoubleList ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 140 of file StorageHelper.h.

References tcpip::Storage::readDoubleList(), tcpip::Storage::readUnsignedByte(), and libsumo::TYPE_DOUBLELIST.

Referenced by TraCIServerAPI_Polygon::processSet().

Here is the caller graph for this function:

◆ readTypedInt()

◆ readTypedPolygon()

static const libsumo::TraCIPositionVector libsumo::StorageHelper::readTypedPolygon ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 183 of file StorageHelper.h.

References readPolygon(), tcpip::Storage::readUnsignedByte(), and libsumo::TYPE_POLYGON.

Referenced by TraCIServerAPI_GUI::processSet(), and TraCIServerAPI_Polygon::processSet().

Here is the caller graph for this function:

◆ readTypedPosition2D()

static const libsumo::TraCIPosition libsumo::StorageHelper::readTypedPosition2D ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 173 of file StorageHelper.h.

References libsumo::POSITION_2D, tcpip::Storage::readDouble(), tcpip::Storage::readUnsignedByte(), libsumo::TraCIPosition::x, and libsumo::TraCIPosition::y.

Referenced by TraCIServerAPI_GUI::processSet(), and TraCIServerAPI_POI::processSet().

Here is the caller graph for this function:

◆ readTypedString()

static std::string libsumo::StorageHelper::readTypedString ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 147 of file StorageHelper.h.

References tcpip::Storage::readString(), tcpip::Storage::readUnsignedByte(), and libsumo::TYPE_STRING.

Referenced by libtraci::Domain< GET, SET >::getTraCIStage(), LIBSUMO_NAMESPACE::Edge::handleVariable(), LIBSUMO_NAMESPACE::Lane::handleVariable(), LIBSUMO_NAMESPACE::Person::handleVariable(), LIBSUMO_NAMESPACE::Simulation::handleVariable(), LIBSUMO_NAMESPACE::TrafficLight::handleVariable(), LIBSUMO_NAMESPACE::Vehicle::handleVariable(), TraCIServerAPI_Vehicle::insertReplaceStop(), TraCIServerAPI_GUI::processGet(), TraCIServerAPI_Simulation::processGet(), TraCIServerAPI_TrafficLight::processGet(), TraCIServerAPI_GUI::processSet(), TraCIServerAPI_BusStop::processSet(), TraCIServerAPI_Calibrator::processSet(), TraCIServerAPI_ChargingStation::processSet(), TraCIServerAPI_Edge::processSet(), TraCIServerAPI_InductionLoop::processSet(), TraCIServerAPI_Junction::processSet(), TraCIServerAPI_Lane::processSet(), TraCIServerAPI_LaneArea::processSet(), TraCIServerAPI_MultiEntryExit::processSet(), TraCIServerAPI_OverheadWire::processSet(), TraCIServerAPI_ParkingArea::processSet(), TraCIServerAPI_Person::processSet(), TraCIServerAPI_POI::processSet(), TraCIServerAPI_Polygon::processSet(), TraCIServerAPI_Rerouter::processSet(), TraCIServerAPI_Route::processSet(), TraCIServerAPI_RouteProbe::processSet(), TraCIServerAPI_Simulation::processSet(), TraCIServerAPI_TrafficLight::processSet(), TraCIServerAPI_VariableSpeedSign::processSet(), TraCIServerAPI_Vehicle::processSet(), readBestLanesVector(), readCollisionVector(), readConnection(), readConstraintVector(), readJunctionFoeVector(), readLogic(), readReservation(), readStage(), readStopVector(), readTLSDataVector(), readVehicleDataVector(), and TraCIServerAPI_VehicleType::setVariable().

Here is the caller graph for this function:

◆ readTypedStringList()

◆ readTypedUnsignedByte()

static int libsumo::StorageHelper::readTypedUnsignedByte ( tcpip::Storage ret,
const std::string &  error = "" 
)
inlinestatic

Definition at line 126 of file StorageHelper.h.

References tcpip::Storage::readUnsignedByte(), and libsumo::TYPE_UBYTE.

Referenced by TraCIServerAPI_Simulation::commandPositionConversion(), TraCIServerAPI_POI::processSet(), TraCIServerAPI_Vehicle::processSet(), and readBestLanesVector().

Here is the caller graph for this function:

◆ readVehicleDataVector()

static void libsumo::StorageHelper::readVehicleDataVector ( tcpip::Storage inputStorage,
std::vector< libsumo::TraCIVehicleData > &  result,
const std::string &  error = "" 
)
inlinestatic

Definition at line 251 of file StorageHelper.h.

References libsumo::TraCIVehicleData::entryTime, libsumo::TraCIVehicleData::id, libsumo::TraCIVehicleData::leaveTime, libsumo::TraCIVehicleData::length, readTypedDouble(), readTypedInt(), readTypedString(), and libsumo::TraCIVehicleData::typeID.

Referenced by libtraci::Connection::readVariables().

Here is the caller graph for this function:

◆ toStorage()

static std::shared_ptr< tcpip::Storage > libsumo::StorageHelper::toStorage ( const TraCIResult v)
inlinestatic

◆ writeCompound()

◆ writeConstraint()

◆ writePolygon()

static void libsumo::StorageHelper::writePolygon ( tcpip::Storage content,
const libsumo::TraCIPositionVector shape 
)
inlinestatic

◆ writeStage()

◆ writeTypedByte()

static void libsumo::StorageHelper::writeTypedByte ( tcpip::Storage content,
int  value 
)
inlinestatic

Definition at line 424 of file StorageHelper.h.

References libsumo::TYPE_BYTE, tcpip::Storage::writeByte(), and tcpip::Storage::writeUnsignedByte().

Referenced by toStorage(), TraCIServer::wrapBestLanesDataVector(), TraCIServer::wrapNextTLSDataVector(), writeConstraint(), and TraCIServerAPI_TrafficLight::writeConstraint().

Here is the caller graph for this function:

◆ writeTypedDouble()

static void libsumo::StorageHelper::writeTypedDouble ( tcpip::Storage content,
double  value 
)
inlinestatic

◆ writeTypedInt()

◆ writeTypedString()

◆ writeTypedStringList()

static void libsumo::StorageHelper::writeTypedStringList ( tcpip::Storage content,
const std::vector< std::string > &  value 
)
inlinestatic

Definition at line 449 of file StorageHelper.h.

References libsumo::TYPE_STRINGLIST, tcpip::Storage::writeStringList(), and tcpip::Storage::writeUnsignedByte().

Referenced by TraCIServer::wrapBestLanesDataVector(), TraCIServer::wrapLinkVectorVector(), TraCIServer::wrapLogicVector(), TraCIServer::wrapReservationVector(), writeConstraint(), TraCIServerAPI_TrafficLight::writeConstraint(), and writeStage().

Here is the caller graph for this function:

◆ writeTypedUnsignedByte()

static void libsumo::StorageHelper::writeTypedUnsignedByte ( tcpip::Storage content,
int  value 
)
inlinestatic

Definition at line 429 of file StorageHelper.h.

References libsumo::TYPE_UBYTE, and tcpip::Storage::writeUnsignedByte().

Referenced by TraCIServer::wrapBestLanesDataVector(), TraCIServer::wrapConnectionVector(), and TraCIServer::wrapJunctionFoeVector().

Here is the caller graph for this function:

The documentation for this class was generated from the following file: