1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2019 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials
5 // are made available under the terms of the Eclipse Public License v2.0
6 // which accompanies this distribution, and is available at
7 // http://www.eclipse.org/legal/epl-v20.html
8 // SPDX-License-Identifier: EPL-2.0
9 /****************************************************************************/
10 /// @file    SystemFrame.h
11 /// @author  Daniel Krajzewicz
12 /// @author  Michael Behrisch
13 /// @date    Mon, 23.06.2003
14 /// @version $Id$
15 ///
16 // A set of actions common to all applications
17 /****************************************************************************/
18 #ifndef SystemFrame_h
19 #define SystemFrame_h
20 
21 
22 // ===========================================================================
23 // included modules
24 // ===========================================================================
25 
26 
27 // ===========================================================================
28 // class declarations
29 // ===========================================================================
30 class OptionsCont;
31 
32 
33 // ===========================================================================
34 // class definitions
35 // ===========================================================================
36 /**
37  * @class SystemFrame
38  * @brief A set of actions common to all applications
39  *
40  * As almost all applications within the SUMO-package share the same
41  *  initialisation procedure, it is encapsulated within this class.
42  *
43  * Only two things are done herein, so far. The first is to insert
44  *  options into the given options container that are used for dealing
45  *  with the application's configuration.
46  *
47  * Additionally, a closing method may be found, which closes all used
48  *  subsystems.
49  */
50 class SystemFrame {
51 public:
52     /** @brief Adds configuration options to the given container
53      *
54      * @param[in] oc The options container to add the options to
55      * @todo let the container be retrieved
56      */
57     static void addConfigurationOptions(OptionsCont& oc);
58 
59 
60     /** @brief Adds reporting options to the given container
61      *
62      * @param[in] oc The options container to add the options to
63      * @todo let the container be retrieved
64      */
65     static void addReportOptions(OptionsCont& oc);
66 
67     /// @brief checks shared options and sets StdDefs
68     static bool checkOptions();
69 
70     /** @brief Closes all of an applications subsystems
71      *
72      * Closes (in this order)
73      * @arg The xml subsystem
74      * @arg The options subsystem
75      * @arg The message subsystem
76      * @see XMLSubSys::close()
77      * @see OptionsCont::clear()
78      * @see MsgHandler::cleanupOnEnd()
79      */
80     static void close();
81 
82 
83 };
84 
85 
86 #endif
87 
88 /****************************************************************************/
89 
90