1 // airportdynamicsmanager.hxx - manager for dynamic (changeable)
2 // part of airport state
4 // Written by James Turner, started December 2015
6 // Copyright (C) 2015 James Turner <zakalawe@mac.com>
8 // This program is free software; you can redistribute it and/or
9 // modify it under the terms of the GNU General Public License as
10 // published by the Free Software Foundation; either version 2 of the
11 // License, or (at your option) any later version.
13 // This program is distributed in the hope that it will be useful, but
14 // WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // General Public License for more details.
18 // You should have received a copy of the GNU General Public License
19 // along with this program; if not, write to the Free Software
20 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 #ifndef AIRPORTDYNAMICSMANAGER_H
23 #define AIRPORTDYNAMICSMANAGER_H
25 #include <simgear/structure/subsystem_mgr.hxx>
26 #include <simgear/structure/SGSharedPtr.hxx>
30 #include "airports_fwd.hxx"
35 class AirportDynamicsManager : public SGSubsystem
38 AirportDynamicsManager();
39 virtual ~AirportDynamicsManager();
42 virtual void shutdown();
43 virtual void update (double dt);
44 virtual void reinit();
46 static FGAirportDynamicsRef find(const std::string& icao);
48 static FGAirportDynamicsRef find(const FGAirportRef& apt);
50 FGAirportDynamicsRef dynamicsForICAO(const std::string& icao);
52 static const char* subsystemName() { return "airport-dynamics"; }
54 typedef std::map<std::string, FGAirportDynamicsRef> ICAODynamicsDict;
55 ICAODynamicsDict m_dynamics;
60 #endif // AIRPORTDYNAMICSMANAGER_H