SUMO - Simulation of Urban MObility
MSVTypeProbe.h
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2017 German Aerospace Center (DLR) and others.
4 /****************************************************************************/
5 //
6 // This program and the accompanying materials
7 // are made available under the terms of the Eclipse Public License v2.0
8 // which accompanies this distribution, and is available at
9 // http://www.eclipse.org/legal/epl-v20.html
10 //
11 /****************************************************************************/
19 // Writes positions of vehicles that have a certain (named) type
20 /****************************************************************************/
21 #ifndef MSVTypeProbe_h
22 #define MSVTypeProbe_h
23 
24 
25 // ===========================================================================
26 // included modules
27 // ===========================================================================
28 #ifdef _MSC_VER
29 #include <windows_config.h>
30 #else
31 #include <config.h>
32 #endif
33 
34 #include <string>
35 #include <utils/common/Command.h>
37 #include <utils/common/Named.h>
38 #include <utils/common/SUMOTime.h>
39 
40 
41 // ===========================================================================
42 // class definitions
43 // ===========================================================================
59 class MSVTypeProbe : public Named, public Command {
60 public:
68  MSVTypeProbe(const std::string& id, const std::string& vType,
69  OutputDevice& od, SUMOTime frequency);
70 
71 
73  virtual ~MSVTypeProbe();
74 
75 
76 
79 
90  SUMOTime execute(SUMOTime currentTime);
92 
93 
94 private:
96  std::string myVType;
97 
100 
103 
104 
105 private:
107  MSVTypeProbe(const MSVTypeProbe&);
108 
111 
112 
113 };
114 
115 #endif
116 
117 /****************************************************************************/
118 
MSVTypeProbe(const std::string &id, const std::string &vType, OutputDevice &od, SUMOTime frequency)
Constructor.
SUMOTime myFrequency
The frequency of reporting.
Definition: MSVTypeProbe.h:102
Base (microsim) event class.
Definition: Command.h:60
Writes positions of vehicles that have a certain (named) type.
Definition: MSVTypeProbe.h:59
SUMOTime execute(SUMOTime currentTime)
Writes values into the given stream.
OutputDevice & myOutputDevice
The device to write into.
Definition: MSVTypeProbe.h:99
Base class for objects which have an id.
Definition: Named.h:45
std::string myVType
The id of the vehicle type vehicles must have to be reported.
Definition: MSVTypeProbe.h:96
MSVTypeProbe & operator=(const MSVTypeProbe &)
Invalidated assignment operator.
virtual ~MSVTypeProbe()
Destructor.
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:70
long long int SUMOTime
Definition: TraCIDefs.h:51