SUMO - Simulation of Urban MObility
NWFrame.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 // Sets and checks options for netwrite
20 /****************************************************************************/
21 #ifndef NWFrame_h
22 #define NWFrame_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 
35 // ===========================================================================
36 // class declarations
37 // ===========================================================================
38 class OptionsCont;
39 class NBNetBuilder;
40 class Position;
41 class OutputDevice;
42 
43 
44 // ===========================================================================
45 // class definitions
46 // ===========================================================================
51 class NWFrame {
52 public:
54  static void fillOptions(bool forNetgen);
55 
59  static bool checkOptions();
60 
62  static void writeNetwork(const OptionsCont& oc, NBNetBuilder& nb);
63 
65  static void writePositionLong(const Position& pos, OutputDevice& dev);
66 
68  static const std::string MAJOR_VERSION;
69 };
70 
71 
72 #endif
73 
74 /****************************************************************************/
75 
static bool checkOptions()
Checks set options from the OptionsCont-singleton for being valid.
Definition: NWFrame.cpp:131
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:45
static void writePositionLong(const Position &pos, OutputDevice &dev)
Writes the given position to device in long format (one attribute per dimension)
Definition: NWFrame.cpp:194
Sets and checks options for netwrite; saves the network.
Definition: NWFrame.h:51
static void writeNetwork(const OptionsCont &oc, NBNetBuilder &nb)
Writes the network stored in the given net builder.
Definition: NWFrame.cpp:180
Instance responsible for building networks.
Definition: NBNetBuilder.h:115
A storage for options typed value containers)
Definition: OptionsCont.h:98
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:70
static void fillOptions(bool forNetgen)
Inserts options used by the network writer.
Definition: NWFrame.cpp:58
static const std::string MAJOR_VERSION
The version number for written files.
Definition: NWFrame.h:68