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
NLTriggerBuilder.h
Go to the documentation of this file.
1
/****************************************************************************/
10
// Builds trigger objects for microsim
11
/****************************************************************************/
12
// SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
13
// Copyright (C) 2001-2013 DLR (http://www.dlr.de/) and contributors
14
/****************************************************************************/
15
//
16
// This file is part of SUMO.
17
// SUMO is free software: you can redistribute it and/or modify
18
// it under the terms of the GNU General Public License as published by
19
// the Free Software Foundation, either version 3 of the License, or
20
// (at your option) any later version.
21
//
22
/****************************************************************************/
23
#ifndef NLTriggerBuilder_h
24
#define NLTriggerBuilder_h
25
26
27
// ===========================================================================
28
// included modules
29
// ===========================================================================
30
#ifdef _MSC_VER
31
#include <
windows_config.h
>
32
#else
33
#include <
config.h
>
34
#endif
35
36
#include <string>
37
#include <vector>
38
39
40
// ===========================================================================
41
// class declarations
42
// ===========================================================================
43
class
MSTrigger
;
44
class
MSNet
;
45
class
MSLaneSpeedTrigger
;
46
class
NLHandler
;
47
class
MSTriggeredRerouter
;
48
class
MSLane
;
49
class
MSEdge
;
50
class
MSBusStop
;
51
class
MSCalibrator
;
52
53
#ifdef HAVE_INTERNAL
54
class
METriggeredCalibrator;
55
#endif
56
57
58
// ===========================================================================
59
// class definitions
60
// ===========================================================================
69
class
NLTriggerBuilder
{
70
public
:
72
NLTriggerBuilder
();
73
74
76
virtual
~NLTriggerBuilder
();
77
78
83
void
setHandler
(
NLHandler
* handler);
84
85
95
void
buildVaporizer
(
const
SUMOSAXAttributes
& attrs);
96
97
102
103
118
void
parseAndBuildLaneSpeedTrigger
(
MSNet
& net,
const
SUMOSAXAttributes
& attrs,
119
const
std::string& base);
120
121
129
void
parseAndBuildRerouter
(
MSNet
& net,
const
SUMOSAXAttributes
& attrs,
130
const
std::string& base);
131
132
139
void
parseAndBuildBusStop
(
MSNet
& net,
const
SUMOSAXAttributes
& attrs);
140
141
149
void
parseAndBuildCalibrator
(
MSNet
& net,
const
SUMOSAXAttributes
& attrs,
150
const
std::string& base);
152
153
154
protected
:
163
164
176
virtual
MSLaneSpeedTrigger
*
buildLaneSpeedTrigger
(
MSNet
& net,
177
const
std::string&
id
,
const
std::vector<MSLane*>& destLanes,
178
const
std::string& file);
179
180
193
virtual
void
buildBusStop
(
MSNet
& net,
194
const
std::string&
id
,
const
std::vector<std::string>& lines,
195
MSLane
* lane,
SUMOReal
frompos,
SUMOReal
topos);
196
197
209
MSCalibrator
*
buildCalibrator
(
MSNet
& net,
210
const
std::string&
id
,
MSEdge
* edge,
SUMOReal
pos,
211
const
std::string& file,
const
std::string& outfile,
212
const
SUMOTime
freq);
213
#ifdef HAVE_INTERNAL
214
225
METriggeredCalibrator* buildMECalibrator(
MSNet
& net,
226
const
std::string&
id
,
const
MSEdge
* edge,
SUMOReal
pos,
227
const
std::string& file,
const
std::string& outfile,
228
const
SUMOTime
freq);
229
#endif
230
231
242
virtual
MSTriggeredRerouter
*
buildRerouter
(
MSNet
& net,
243
const
std::string&
id
, std::vector<MSEdge*>& edges,
244
SUMOReal
prob,
const
std::string& file,
bool
off);
246
247
248
protected
:
251
263
std::string
getFileName
(
const
SUMOSAXAttributes
& attrs,
264
const
std::string& base,
265
const
bool
allowEmpty =
false
);
266
267
279
MSLane
*
getLane
(
const
SUMOSAXAttributes
& attrs,
280
const
std::string& tt,
const
std::string& tid);
281
282
296
SUMOReal
getPosition
(
const
SUMOSAXAttributes
& attrs,
297
MSLane
* lane,
const
std::string& tt,
const
std::string& tid);
299
300
301
protected
:
303
NLHandler
*
myHandler
;
304
305
306
};
307
308
309
#endif
310
311
/****************************************************************************/
312
home
gladk
tmp
05
sumo-0.17.1~dfsg
src
netload
NLTriggerBuilder.h
Generated on Sun Jun 16 2013 07:08:12 for SUMO - Simulation of Urban MObility by
1.8.1.2