1 /****************************************************************************/ 2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo 3 // Copyright (C) 2001-2019 German Aerospace Center (DLR) and others. 4 // This program and the accompanying materials 5 // are made available under the terms of the Eclipse Public License v2.0 6 // which accompanies this distribution, and is available at 7 // http://www.eclipse.org/legal/epl-v20.html 8 // SPDX-License-Identifier: EPL-2.0 9 /****************************************************************************/ 10 /// @file TraCIServerAPI_Person.h 11 /// @author Daniel Krajzewicz 12 /// @date 26.05.2014 13 /// @version $Id$ 14 /// 15 // APIs for getting/setting person values via TraCI 16 /****************************************************************************/ 17 #ifndef TraCIServerAPI_Person_h 18 #define TraCIServerAPI_Person_h 19 20 21 // =========================================================================== 22 // included modules 23 // =========================================================================== 24 #include <config.h> 25 26 #include <foreign/tcpip/storage.h> 27 28 29 // =========================================================================== 30 // class declarations 31 // =========================================================================== 32 class TraCIServer; 33 34 35 // =========================================================================== 36 // class definitions 37 // =========================================================================== 38 /** 39 * @class TraCIServerAPI_Person 40 * @brief APIs for getting/setting person values via TraCI 41 */ 42 class TraCIServerAPI_Person { 43 public: 44 /** @brief Processes a get value command (Command 0xae: Get Person Variable) 45 * 46 * @param[in] server The TraCI-server-instance which schedules this request 47 * @param[in] inputStorage The storage to read the command from 48 * @param[out] outputStorage The storage to write the result to 49 */ 50 static bool processGet(TraCIServer& server, tcpip::Storage& inputStorage, 51 tcpip::Storage& outputStorage); 52 53 54 /** @brief Processes a set value command (Command 0xce: Change Person State) 55 * 56 * @param[in] server The TraCI-server-instance which schedules this request 57 * @param[in] inputStorage The storage to read the command from 58 * @param[out] outputStorage The storage to write the result to 59 */ 60 static bool processSet(TraCIServer& server, tcpip::Storage& inputStorage, 61 tcpip::Storage& outputStorage); 62 63 64 private: 65 /// @brief invalidated copy constructor 66 TraCIServerAPI_Person(const TraCIServerAPI_Person& s); 67 68 /// @brief invalidated assignment operator 69 TraCIServerAPI_Person& operator=(const TraCIServerAPI_Person& s); 70 71 72 }; 73 74 75 #endif 76 77 /****************************************************************************/ 78