#include <ApplicationExtension.hpp>
◆ ApplicationExtension()
| engage::ApplicationExtension::ApplicationExtension |
( |
| ) |
|
◆ AddedToApplication()
| void engage::ApplicationExtension::AddedToApplication |
( |
WsfApplication & | aApplication | ) |
|
|
overridevirtual |
◆ ScenarioCreated()
| void engage::ApplicationExtension::ScenarioCreated |
( |
WsfScenario & | aScenario | ) |
|
|
overridevirtual |
Called in response to the creation of a WsfScenario object. This is called at the end of the WsfScenario constructor. A derived class may provide this method to do the following:
-
Register a scenario extension to register new types and access the input stream to interpret commands, e.g.:
aScenario.RegisterExtension("my_extension", new MyScenarioExtension);
-
If a scenario extension is not being created, register new type objects or object factories, e.g.:
aScenario.GetMoverTypes().AddCoreType("MY_MOVER", new MyMover(aScenario));
aScenario.GetAntennaPatternTypes().AddObjectFactor(MyAntennaPattern::ObjectFactory);
- Parameters
-
| aScenario | The scenario object that is being created. |
- See also
- WsfScenarioExtension.
Reimplemented from WsfApplicationExtension.
References WsfScenario::RegisterExtension().
◆ SimulationCreated()
| void engage::ApplicationExtension::SimulationCreated |
( |
WsfSimulation & | aSimulation | ) |
|
|
overridevirtual |
Called in response to the creation of a WsfSimulation object. This is actually called when the WsfSimulation::Initialize() is called. A derived class will override this method if it needs to concern itself the creation of a simulation.
Notes concerning creation of simulation extensions:
-
If an application extension requires a simulation extension but not a scenario extension (probably a rare occurrence), then the simulation extension should be created here, e.g.:
aSimulation.RegisterExtension("my_extension", new MySimulationExtension);
-
If, however, the application extension requires both a scenario extension (created by WsfApplicationExtension::ScenarioCreated) and a simulation extension, the simulation extension should be created in WsfScenarioExtension::SimulationCreated. This ensures that any dependencies registered by WsfApplication::ExtensionDepends are honored.
- Parameters
-
| aSimulation | The simulation object that is being created. |
- See also
- WsfSimulationExtension.
Reimplemented from WsfApplicationExtension.
The documentation for this class was generated from the following files: