|
WSF
|
Scenario extension for event pipe. Reads the input file. More...
#include <WsfEventPipe.hpp>


Public Types | |
| using | DetailSettingsMap = std::map<std::string, WsfEventPipeOptions> |
| This is used ONLY by WsfGrammarInterface::OutputForIDE to get events names and such for the IDE. | |
Public Member Functions | |
| WsfEventPipeExtension () | |
| ~WsfEventPipeExtension () override=default | |
| bool | ProcessInput (UtInput &aInput) override |
| void | SimulationCreated (WsfSimulation &aSimulation) override |
| int | RegisterEventOption (const std::string &aOptionName, bool aDefaultValue) |
| void | AddSchema (const std::string &aSchemaText) |
| Additional UtPack structures may be defined by other extensions. | |
| void | AddCallback (std::unique_ptr< UtCallback > aCallbackPtr) |
| const UtTextDocument & | GetSchema () const |
| std::vector< std::string > & | GetEventNames () |
| const std::vector< std::string > & | GetEventNames () const |
| const wsf::eventpipe::EventIds & | GetEventIds () const |
| const DetailSettingsMap & | GetDetailSettings () const |
| Public Member Functions inherited from WsfScenarioExtension | |
| WsfScenarioExtension () | |
| ~WsfScenarioExtension () override | |
| WsfScenario & | GetScenario () const |
| WsfApplication & | GetApplication () const |
| virtual void | AddedToScenario () |
| virtual void | FileLoaded (const std::string &aFileName) |
| virtual bool | Complete () |
| virtual bool | Complete2 () |
| virtual bool | AlwaysCreate () |
| Public Member Functions inherited from WsfExtension | |
| virtual | ~WsfExtension ()=default |
| const std::string & | GetExtensionName () const |
Static Public Member Functions | |
| static WsfEventPipeExtension * | Find (const WsfScenario &aScenario) |
Public Attributes | |
| UtCallbackListN< void(UtPackSerializer *)> | RegisterExtensionMessages |
aName The event name whose identifier is desired. | |
Return the unique integer identifier for the specified event name.
| |
| int | GetEventId (const std::string &aName) const |
Additional Inherited Members | |
| Protected Member Functions inherited from WsfExtension | |
| void | InitializeExtensionName (const std::string &aName) |
Scenario extension for event pipe. Reads the input file.
| using WsfEventPipeExtension::DetailSettingsMap = std::map<std::string, WsfEventPipeOptions> |
This is used ONLY by WsfGrammarInterface::OutputForIDE to get events names and such for the IDE.
| WsfEventPipeExtension::WsfEventPipeExtension | ( | ) |
References AddSchema(), WsfEventPipeOptions::EnableOption(), full, and WsfEventPipeOptions::SetMaxEventId().
Referenced by Find().
|
overridedefault |
References AddCallback(), AddSchema(), and RegisterEventOption().
| void WsfEventPipeExtension::AddCallback | ( | std::unique_ptr< UtCallback > | aCallbackPtr | ) |
Extensions generate callbacks when connecting a UtPackSerializer method to RegisterExtensionMessages. That callback is stored here.
Referenced by wsf::AirCombat::EventPipe::RegisterEvents(), wsf::annotation::EventPipe::RegisterEvents(), wsf::cyber::EventPipe::RegisterEvents(), wsf::p6dof::EventPipe::RegisterEvents(), wsf::six_dof::EventPipe::RegisterEvents(), wsf::space::EventPipe::RegisterEvents(), WsfMilEventPipe::RegisterEvents(), and ~WsfEventPipeExtension().
| void WsfEventPipeExtension::AddSchema | ( | const std::string & | aSchemaText | ) |
Additional UtPack structures may be defined by other extensions.
Referenced by wsf::AirCombat::EventPipe::RegisterEvents(), wsf::annotation::EventPipe::RegisterEvents(), wsf::cyber::EventPipe::RegisterEvents(), wsf::p6dof::EventPipe::RegisterEvents(), wsf::six_dof::EventPipe::RegisterEvents(), wsf::space::EventPipe::RegisterEvents(), WsfMilEventPipe::RegisterEvents(), WsfEventPipeExtension(), and ~WsfEventPipeExtension().
|
static |
References WsfScenario::FindExtension(), WsfEventPipeExtension(), and WsfScenarioExtension::WsfScenario.
Referenced by wsf::cyber::ScenarioExtension::AddedToScenario(), wsf::six_dof::TypeManager::AddedToScenario(), WsfAirCombatTypeManager::AddedToScenario(), WsfAnnotationExtension::AddedToScenario(), WsfMilExtension::AddedToScenario(), WsfP6DOF_TypeManager::AddedToScenario(), WsfSpaceExtension::AddedToScenario(), and WsfEventPipeInterface::AddedToSimulation().
|
inline |
| int WsfEventPipeExtension::GetEventId | ( | const std::string & | aName | ) | const |
References GetEventNames().
|
inline |
|
inline |
Referenced by GetEventId().
|
inline |
|
inline |
Referenced by WsfEventPipeInterface::AddedToSimulation().
|
overridevirtual |
Process potential input for the extension. This method examines the current input command to determine if it is one that is recognized by the extension. If it is one recognized by the extension then it processes the command and returns 'true', otherwise it returns 'false'.
| aInput | a reference to a UtInput object. |
| UtInput::ExceptionBase | (or an object derived from it) if the command was recognized but contains some sort of error. |
Reimplemented from WsfScenarioExtension.
References WsfEventPipeOptionsCriteria::cCATEGORY_NAME, WsfEventPipeOptionsCriteria::cPLATFORM_NAME, WsfEventPipeOptionsCriteria::cPLATFORM_TYPE, WsfEventPipeOptionsCriteria::cSIDE_NAME, WsfEventPipeInput::CriteriaToDetail::mCriteria, WsfEventPipeInput::CriteriaToDetail::mDetailSettingName, WsfEventPipeOptionsCriteria::mKind, and WsfEventPipeOptionsCriteria::mText.
| int WsfEventPipeExtension::RegisterEventOption | ( | const std::string & | aOptionName, |
| bool | aDefaultValue ) |
Add a new event that can be selected to be included in the output stream. Other extensions can define events that can be included in the output stream.
Extensions that want to include additional events should call this option in their scenario extension constructor and should also call AddSchema.
| aOptionName | The name by which the event is to be known. |
| aDefaultValue | The default value for the "default" and "low" sets. |
Referenced by wsf::AirCombat::EventPipe::RegisterEvents(), wsf::annotation::EventPipe::RegisterEvents(), wsf::cyber::EventPipe::RegisterEvents(), wsf::p6dof::EventPipe::RegisterEvents(), wsf::six_dof::EventPipe::RegisterEvents(), wsf::space::EventPipe::RegisterEvents(), wsf::xio::EventPipe::RegisterEvents(), WsfMilEventPipe::RegisterEvents(), and ~WsfEventPipeExtension().
|
overridevirtual |
Called when a simulation has been created. (Technically this is called upon entry to WsfSimulation::Initialize()). This is typically used when a scenario extension also requires a simulation extension. The method would typically register the simulation extension as follows:
| aSimulation | The simulation that is being created. See note below! |
Reimplemented from WsfScenarioExtension.
References WsfExtension::GetExtensionName(), and WsfSimulation::RegisterExtension().
|
mutable |
Referenced by WsfEventPipeInterface::AddedToSimulation(), wsf::AirCombat::EventPipe::RegisterEvents(), wsf::annotation::EventPipe::RegisterEvents(), wsf::cyber::EventPipe::RegisterEvents(), wsf::p6dof::EventPipe::RegisterEvents(), wsf::six_dof::EventPipe::RegisterEvents(), wsf::space::EventPipe::RegisterEvents(), and WsfMilEventPipe::RegisterEvents().