SUMO - Simulation of Urban MObility
|
APIs for getting/setting GUI values via TraCI. More...
#include <TraCIServerAPI_GUI.h>
Static Public Member Functions | |
static bool | processGet (traci::TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage) throw (traci::TraCIException, std::invalid_argument) |
Processes a get value command (Command 0xac: Get GUI Variable) | |
static bool | processSet (traci::TraCIServer &server, tcpip::Storage &inputStorage, tcpip::Storage &outputStorage) throw (traci::TraCIException, std::invalid_argument) |
Processes a set value command (Command 0xcc: Change GUI State) | |
Static Protected Member Functions | |
static GUIMainWindow * | getMainWindow () |
Returns the main window. | |
static GUISUMOAbstractView *const | getNamedView (const std::string &id) |
Returns the named view. | |
Private Member Functions | |
TraCIServerAPI_GUI & | operator= (const TraCIServerAPI_GUI &s) |
invalidated assignment operator | |
TraCIServerAPI_GUI (const TraCIServerAPI_GUI &s) | |
invalidated copy constructor |
APIs for getting/setting GUI values via TraCI.
Definition at line 55 of file TraCIServerAPI_GUI.h.
TraCIServerAPI_GUI::TraCIServerAPI_GUI | ( | const TraCIServerAPI_GUI & | s | ) | [private] |
invalidated copy constructor
GUIMainWindow * TraCIServerAPI_GUI::getMainWindow | ( | ) | [static, protected] |
Returns the main window.
Definition at line 228 of file TraCIServerAPI_GUI.cpp.
GUISUMOAbstractView *const TraCIServerAPI_GUI::getNamedView | ( | const std::string & | id | ) | [static, protected] |
Returns the named view.
[in] | viewName | The name of the view |
Definition at line 242 of file TraCIServerAPI_GUI.cpp.
References GUIGlChildWindow::getView(), and GUIMainWindow::getViewByID().
TraCIServerAPI_GUI& TraCIServerAPI_GUI::operator= | ( | const TraCIServerAPI_GUI & | s | ) | [private] |
invalidated assignment operator
bool TraCIServerAPI_GUI::processGet | ( | traci::TraCIServer & | server, |
tcpip::Storage & | inputStorage, | ||
tcpip::Storage & | outputStorage | ||
) | throw (traci::TraCIException, std::invalid_argument) [static] |
Processes a get value command (Command 0xac: Get GUI Variable)
[in] | server | The TraCI-server-instance which schedules this request |
[in] | inputStorage | The storage to read the command from |
[out] | outputStorage | The storage to write the result to |
Definition at line 61 of file TraCIServerAPI_GUI.cpp.
References CMD_GET_GUI_VARIABLE, GUISUMOAbstractView::getChanger(), GUISUMOAbstractView::getColoringSchemesCombo(), GUISUMOAbstractView::getVisibleBoundary(), GUIPerspectiveChanger::getXPos(), GUIPerspectiveChanger::getYPos(), GUIPerspectiveChanger::getZoom(), ID_LIST, POSITION_2D, RESPONSE_GET_GUI_VARIABLE, RTYPE_ERR, RTYPE_OK, TYPE_BOUNDINGBOX, TYPE_DOUBLE, TYPE_STRING, TYPE_STRINGLIST, VAR_VIEW_BOUNDARY, VAR_VIEW_OFFSET, VAR_VIEW_SCHEMA, VAR_VIEW_ZOOM, tcpip::Storage::writeDouble(), tcpip::Storage::writeString(), tcpip::Storage::writeStringList(), tcpip::Storage::writeUnsignedByte(), Boundary::xmax(), Boundary::xmin(), Boundary::ymax(), and Boundary::ymin().
Referenced by GUIApplicationWindow::handleEvent_SimulationLoaded().
bool TraCIServerAPI_GUI::processSet | ( | traci::TraCIServer & | server, |
tcpip::Storage & | inputStorage, | ||
tcpip::Storage & | outputStorage | ||
) | throw (traci::TraCIException, std::invalid_argument) [static] |
Processes a set value command (Command 0xcc: Change GUI State)
[in] | server | The TraCI-server-instance which schedules this request |
[in] | inputStorage | The storage to read the command from |
[out] | outputStorage | The storage to write the result to |
Definition at line 126 of file TraCIServerAPI_GUI.cpp.
References GUISUMOAbstractView::centerTo(), CMD_SET_GUI_VARIABLE, GUISUMOAbstractView::getChanger(), MSNet::getInstance(), MSVehicleControl::getVehicle(), MSNet::getVehicleControl(), GUIPerspectiveChanger::getXPos(), GUIPerspectiveChanger::getYPos(), GUIPerspectiveChanger::getZoom(), GUISUMOAbstractView::makeSnapshot(), POSITION_2D, RTYPE_ERR, RTYPE_OK, GUISUMOAbstractView::setColorScheme(), GUISUMOAbstractView::setViewport(), GUISUMOAbstractView::startTrack(), GUISUMOAbstractView::stopTrack(), SUMOReal, TYPE_BOUNDINGBOX, TYPE_DOUBLE, TYPE_STRING, VAR_SCREENSHOT, VAR_TRACK_VEHICLE, VAR_VIEW_BOUNDARY, VAR_VIEW_OFFSET, VAR_VIEW_SCHEMA, VAR_VIEW_ZOOM, and GUIVehicle::VO_TRACKED.
Referenced by GUIApplicationWindow::handleEvent_SimulationLoaded().