WSF
ToolManager.hpp
Go to the documentation of this file.
1// ****************************************************************************
2// CUI
3//
4// The Advanced Framework for Simulation, Integration, and Modeling (AFSIM)
5//
6// Copyright 2003-2015 The Boeing Company. All rights reserved.
7//
8// The use, dissemination or disclosure of data in this file is subject to
9// limitation or restriction. See accompanying README and LICENSE for details.
10// ****************************************************************************
11
12#ifndef TOOLMANAGER_HPP
13#define TOOLMANAGER_HPP
14
15#include <vector>
16
17#include "Tool.hpp"
18#include "WeaponToolsExport.hpp"
19class UtInput;
20#include "WsfObjectTypeList.hpp"
22
29
31{
32public:
33 static ToolManager* Find(WsfScenario& aScenario);
34 ToolManager(WsfScenario& aScenario);
35 void AddedToScenario() override;
36 ~ToolManager() override;
37
38 bool ProcessInput(UtInput& aInput) override;
39 bool Initialize(WsfSimulation& aSimulation);
40
41 bool AllToolsDone();
42
44 bool UnRegister(Tool* aToolPtr);
45
47 bool Register(Tool* aToolPtr);
48
49 bool AddToolType(const std::string& aType, Tool* aToolTypePtr);
50
51private:
52 void AddBaseTypes();
53
54 typedef std::vector<std::pair<Tool*, bool>> ToolsStatus;
55
56 ToolsStatus mRunningToolsStatus;
58};
59
60#endif
#define WT_EXPORT
Definition WeaponToolsExport.hpp:26
bool Initialize(WsfSimulation &aSimulation)
Definition ToolManager.cpp:193
bool UnRegister(Tool *aToolPtr)
This informs the ToolManager that a tool instance is finished.
Definition ToolManager.cpp:102
static ToolManager * Find(WsfScenario &aScenario)
Definition ToolManager.cpp:218
bool AllToolsDone()
Definition ToolManager.cpp:32
bool Register(Tool *aToolPtr)
This informs the ToolManager that a tool instance is now active (in use).
Definition ToolManager.cpp:81
bool AddToolType(const std::string &aType, Tool *aToolTypePtr)
ToolManager(WsfScenario &aScenario)
Definition ToolManager.cpp:56
Definition Tool.hpp:39
Definition WsfObjectTypeList.hpp:42
WsfScenarioExtension()
Definition WsfScenarioExtension.cpp:21
virtual bool ProcessInput(UtInput &aInput)
Definition WsfScenarioExtension.cpp:62
virtual void AddedToScenario()
Definition WsfScenarioExtension.cpp:50
friend class WsfScenario
Definition WsfScenarioExtension.hpp:39
The main controller for a simulation.
Definition WsfSimulation.hpp:109
Copyrights Multiple, All Rights Reserved