SUMO - Simulation of Urban MObility
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TraCIServerAPI_Polygon Class Reference

APIs for getting/setting polygon values via TraCI. More...

#include <TraCIServerAPI_Polygon.h>

Static Public Member Functions

static bool getShape (const std::string &id, PositionVector &shape)
 Returns the named polygons's shape.
static TraCIRTreegetTree ()
 Returns a tree filled with inductive loop instances.
static bool processGet (traci::TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage)
 Processes a get value command (Command 0xa8: Get Polygon Variable)
static bool processSet (traci::TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage)
 Processes a set value command (Command 0xc8: Change Polygon State)

Private Member Functions

TraCIServerAPI_Polygonoperator= (const TraCIServerAPI_Polygon &s)
 invalidated assignment operator
 TraCIServerAPI_Polygon (const TraCIServerAPI_Polygon &s)
 invalidated copy constructor

Static Private Member Functions

static PolygongetPolygon (const std::string &id)
 Returns the named polygon.

Detailed Description

APIs for getting/setting polygon values via TraCI.

Definition at line 48 of file TraCIServerAPI_Polygon.h.

Constructor & Destructor Documentation

TraCIServerAPI_Polygon::TraCIServerAPI_Polygon ( const TraCIServerAPI_Polygon s)
private

invalidated copy constructor

Member Function Documentation

Polygon * TraCIServerAPI_Polygon::getPolygon ( const std::string &  id)
staticprivate

Returns the named polygon.

Parameters
[in]idThe id of the searched polygon
Returns
The named polygon, or 0 if it is not known

Definition at line 243 of file TraCIServerAPI_Polygon.cpp.

References NamedObjectCont< T >::get(), MSNet::getInstance(), ShapeContainer::getPolygons(), and MSNet::getShapeContainer().

bool TraCIServerAPI_Polygon::getShape ( const std::string &  id,
PositionVector shape 
)
static

Returns the named polygons's shape.

Parameters
[in]idThe id of the searched polygon
[out]shapeThe shape, if the polygon is known
Returns
Whether the polygon is known

Definition at line 232 of file TraCIServerAPI_Polygon.cpp.

References SUMO::Polygon::getShape(), and PositionVector::push_back().

Referenced by traci::TraCIServer::findObjectShape().

TraCIRTree * TraCIServerAPI_Polygon::getTree ( )
static

Returns a tree filled with inductive loop instances.

Returns
The rtree of inductive loop

Definition at line 249 of file TraCIServerAPI_Polygon.cpp.

References TraCIRTree::addObject(), MSNet::getInstance(), NamedObjectCont< T >::getMyMap(), ShapeContainer::getPolygons(), and MSNet::getShapeContainer().

Referenced by traci::TraCIServer::collectObjectsInRange().

TraCIServerAPI_Polygon& TraCIServerAPI_Polygon::operator= ( const TraCIServerAPI_Polygon s)
private

invalidated assignment operator


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