Eclipse 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.dev/sumo
3 // Copyright (C) 2001-2024 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials are made available under the
5 // terms of the Eclipse Public License 2.0 which is available at
6 // https://www.eclipse.org/legal/epl-2.0/
7 // This Source Code may also be made available under the following Secondary
8 // Licenses when the conditions for such availability set forth in the Eclipse
9 // Public License 2.0 are satisfied: GNU General Public License, version 2
10 // or later which is available at
11 // https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html
12 // SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
13 /****************************************************************************/
20 // Sets and checks options for netwrite
21 /****************************************************************************/
22 #pragma once
23 #include <config.h>
24 
25 
26 // ===========================================================================
27 // class declarations
28 // ===========================================================================
29 
30 class OptionsCont;
31 class NBNetBuilder;
32 class Position;
33 class OutputDevice;
34 
35 // ===========================================================================
36 // class definitions
37 // ===========================================================================
42 class NWFrame {
43 
44 public:
46  static void fillOptions(OptionsCont& oc, bool forNetgen);
47 
51  static bool checkOptions(OptionsCont& oc);
52 
54  static void writeNetwork(const OptionsCont& oc, NBNetBuilder& nb);
55 
57  static void writePositionLong(const Position& pos, OutputDevice& dev);
58 };
Instance responsible for building networks.
Definition: NBNetBuilder.h:107
Sets and checks options for netwrite; saves the network.
Definition: NWFrame.h:42
static void fillOptions(OptionsCont &oc, bool forNetgen)
Inserts options used by the network writer.
Definition: NWFrame.cpp:49
static void writeNetwork(const OptionsCont &oc, NBNetBuilder &nb)
Writes the network stored in the given net builder.
Definition: NWFrame.cpp:188
static void writePositionLong(const Position &pos, OutputDevice &dev)
Writes the given position to device in long format (one attribute per dimension)
Definition: NWFrame.cpp:201
static bool checkOptions(OptionsCont &oc)
Checks set options for being valid.
Definition: NWFrame.cpp:139
A storage for options typed value containers)
Definition: OptionsCont.h:89
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:61
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:37