SUMO - Simulation of Urban MObility
Main Page
Related Pages
Modules
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
MS_E2_ZS_CollectorOverLanes.h
Go to the documentation of this file.
1
/****************************************************************************/
8
// A detector which joins E2Collectors over consecutive lanes (backward)
9
/****************************************************************************/
10
// SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
11
// Copyright (C) 2001-2012 DLR (http://www.dlr.de/) and contributors
12
/****************************************************************************/
13
//
14
// This file is part of SUMO.
15
// SUMO is free software: you can redistribute it and/or modify
16
// it under the terms of the GNU General Public License as published by
17
// the Free Software Foundation, either version 3 of the License, or
18
// (at your option) any later version.
19
//
20
/****************************************************************************/
21
#ifndef MS_E2_ZS_CollectorOverLanes_h
22
#define MS_E2_ZS_CollectorOverLanes_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 <
microsim/output/MSDetectorFileOutput.h
>
35
#include <
utils/common/UtilExceptions.h
>
36
37
38
// ===========================================================================
39
// class declarations
40
// ===========================================================================
41
class
MSLane
;
42
class
SUMOVehicle
;
43
class
OutputDevice
;
44
class
MSE2Collector
;
45
46
47
// ===========================================================================
48
// class definitions
49
// ===========================================================================
64
class
MS_E2_ZS_CollectorOverLanes
:
65
public
MSDetectorFileOutput
{
66
public
:
68
typedef
std::vector< MSE2Collector* >
CollectorCont
;
69
82
MS_E2_ZS_CollectorOverLanes
(
const
std::string&
id
,
83
DetectorUsage
usage,
MSLane
* lane,
SUMOReal
startPos,
84
SUMOTime
haltingTimeThreshold,
SUMOReal
haltingSpeedThreshold,
85
SUMOReal
jamDistThreshold) ;
86
87
96
void
init
(
MSLane
* lane,
SUMOReal
detLength) ;
97
98
100
virtual
~MS_E2_ZS_CollectorOverLanes
() ;
101
102
106
const
std::string&
getID
()
const
;
107
108
113
const
std::string&
getStartLaneID
()
const
;
114
115
116
119
128
void
writeXMLOutput
(
OutputDevice
& dev,
129
SUMOTime
startTime,
SUMOTime
stopTime);
130
131
139
void
writeXMLDetectorProlog
(
OutputDevice
& dev)
const
;
141
142
143
147
SUMOReal
getLength
()
const
{
148
return
myLength
;
149
}
150
151
protected
:
158
void
extendTo
(
SUMOReal
length) ;
159
160
168
std::string
makeID
(
const
std::string& baseID,
169
size_t
c,
size_t
r)
const
;
170
171
180
virtual
MSE2Collector
*
buildCollector
(
size_t
c,
size_t
r,
181
MSLane
* l,
SUMOReal
start,
SUMOReal
end) ;
182
183
189
std::vector<MSLane*>
getLanePredeccessorLanes
(
MSLane
* l) ;
190
191
protected
:
193
SUMOReal
startPosM
;
194
196
SUMOReal
myLength
;
197
199
SUMOTime
haltingTimeThresholdM
;
200
202
SUMOReal
haltingSpeedThresholdM
;
203
205
SUMOReal
jamDistThresholdM
;
206
208
typedef
std::vector<MSLane*>
LaneVector
;
209
211
typedef
std::vector<LaneVector>
LaneVectorVector
;
212
214
typedef
std::vector<MSE2Collector*>
DetectorVector
;
215
217
typedef
std::vector<DetectorVector>
DetectorVectorVector
;
218
220
typedef
std::vector<SUMOReal>
LengthVector
;
221
222
226
LaneVectorVector
myLaneCombinations
;
227
228
232
DetectorVectorVector
myDetectorCombinations
;
233
234
238
LengthVector
myLengths
;
239
240
242
std::string
myID
;
243
245
std::string
myStartLaneID
;
246
248
typedef
std::map<MSLane*, MSE2Collector*>
LaneDetMap
;
249
251
LaneDetMap
myAlreadyBuild
;
252
254
DetectorUsage
myUsage
;
255
256
257
private
:
259
MS_E2_ZS_CollectorOverLanes
(
const
MS_E2_ZS_CollectorOverLanes
&);
260
262
MS_E2_ZS_CollectorOverLanes
&
operator=
(
const
MS_E2_ZS_CollectorOverLanes
&);
263
264
265
};
266
267
268
#endif
269
270
/****************************************************************************/
271
tmp
buildd
sumo-0.15.0~dfsg
src
microsim
output
MS_E2_ZS_CollectorOverLanes.h
Generated on Sun May 27 2012 14:52:05 for SUMO - Simulation of Urban MObility by
1.8.1