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
NIXMLNodesHandler.h
Go to the documentation of this file.
1
/****************************************************************************/
9
// Importer for network nodes stored in XML
10
/****************************************************************************/
11
// SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
12
// Copyright (C) 2001-2013 DLR (http://www.dlr.de/) and contributors
13
/****************************************************************************/
14
//
15
// This file is part of SUMO.
16
// SUMO is free software: you can redistribute it and/or modify
17
// it under the terms of the GNU General Public License as published by
18
// the Free Software Foundation, either version 3 of the License, or
19
// (at your option) any later version.
20
//
21
/****************************************************************************/
22
#ifndef NIXMLNodesHandler_h
23
#define NIXMLNodesHandler_h
24
25
26
// ===========================================================================
27
// included modules
28
// ===========================================================================
29
#ifdef _MSC_VER
30
#include <
windows_config.h
>
31
#else
32
#include <
config.h
>
33
#endif
34
35
#include <
utils/xml/SUMOSAXHandler.h
>
36
#include <
utils/geom/Position.h
>
37
38
39
// ===========================================================================
40
// class declarations
41
// ===========================================================================
42
class
OptionsCont
;
43
class
GeoConvHelper
;
44
class
NBNode
;
45
class
NBNodeCont
;
46
class
NBTrafficLightLogicCont
;
47
48
49
// ===========================================================================
50
// class definitions
51
// ===========================================================================
60
class
NIXMLNodesHandler
:
public
SUMOSAXHandler
{
61
62
public
:
71
NIXMLNodesHandler
(
NBNodeCont
& nc,
NBTrafficLightLogicCont
& tlc,
72
OptionsCont
& options);
73
74
76
~NIXMLNodesHandler
();
77
78
79
protected
:
81
82
93
void
myStartElement
(
int
element,
94
const
SUMOSAXAttributes
& attrs);
96
97
98
private
:
99
/*
100
* @brief Parses node information
101
* Tries to parse a node. If the node can be parsed, it is stored within
102
* "myNodeCont". Otherwise an error is generated. Then, if given
103
* the tls information is parsed and inserted into "myTLLogicCont".
104
*/
105
void
addNode
(
const
SUMOSAXAttributes
& attrs);
106
107
/*
108
* @brief Parses node deletion information
109
*/
110
void
deleteNode
(
const
SUMOSAXAttributes
& attrs);
111
112
/*
113
* @brief Parses a cluster of nodes to be joined
114
*/
115
void
addJoinCluster
(
const
SUMOSAXAttributes
& attrs);
116
117
/*
118
* @brief Parses a list of nodes to be excluded from joining
119
*/
120
void
addJoinExclusion
(
const
SUMOSAXAttributes
& attrs);
121
127
void
processTrafficLightDefinitions
(
const
SUMOSAXAttributes
& attrs,
128
NBNode
* currentNode);
129
130
131
private
:
133
OptionsCont
&
myOptions
;
134
136
std::string
myID
;
137
139
Position
myPosition
;
140
142
NBNodeCont
&
myNodeCont
;
143
145
NBTrafficLightLogicCont
&
myTLLogicCont
;
146
148
GeoConvHelper
*
myLocation
;
149
150
151
private
:
153
NIXMLNodesHandler
(
const
NIXMLNodesHandler
& s);
154
156
NIXMLNodesHandler
&
operator=
(
const
NIXMLNodesHandler
& s);
157
158
};
159
160
161
#endif
162
163
/****************************************************************************/
164
home
gladk
tmp
05
sumo-0.17.1~dfsg
src
netimport
NIXMLNodesHandler.h
Generated on Sun Jun 16 2013 07:08:09 for SUMO - Simulation of Urban MObility by
1.8.1.2