WSF
WsfXIO_WeaponComponent Class Reference

#include <WsfXIO_WeaponComponent.hpp>

Inheritance diagram for WsfXIO_WeaponComponent:
Collaboration diagram for WsfXIO_WeaponComponent:

Public Types

enum  { cWEAPON_INFO = WsfXIO_RequestPlatformInfoPkt::cPART_1_INFO , cABORT_FIRE = WsfXIO_TaskCommandPkt::cTASK_COMMAND_1 }
 Equate generic definitions in the packet registry to more meaningful definitions;. More...
Public Types inherited from WsfComponentT< PARENT_TYPE >
typedef PARENT_TYPE ParentType
 This is needed to support the WsfComponentList template.

Public Member Functions

 WsfXIO_WeaponComponent ()
 ~WsfXIO_WeaponComponent () override=default
Public Member Functions inherited from WsfXIO_Component
 WsfXIO_Component (int aRole, const std::string &aName)
bool Initialize ()
 Called by WsfXIO_Interface to allow initialization of the component.
Public Member Functions inherited from WsfSimpleComponentT< WsfComponentT< PARENT_TYPE > >
 WsfSimpleComponentT ()=default
 Empty constructor for serialization.
 WsfSimpleComponentT (int aRole, WsfStringId aName)
 WsfSimpleComponentT (int aRole)
 WsfSimpleComponentT (WsfStringId aName)
 WsfSimpleComponentT (const WsfSimpleComponentT &aSrc)
WsfSimpleComponentToperator= (const WsfSimpleComponentT &aRhs)
 ~WsfSimpleComponentT () override=default
WsfStringId GetComponentName () const override
const int * GetComponentRoles () const override
Public Member Functions inherited from WsfComponentT< PARENT_TYPE >
 WsfComponentT ()
 WsfComponentT (const WsfComponentT &) noexcept
WsfComponentToperator= (const WsfComponentT &) noexcept
 ~WsfComponentT () override=default
virtual void ComponentParentChanged (ParentType *aParentPtr)
ParentTypeGetComponentParent () const
void SetComponentParent (ParentType *aParentPtr)
Public Member Functions inherited from WsfComponent
virtual ~WsfComponent ()=default
virtual int GetComponentInitializationOrder () const
template<typename T>
bool QueryInterfaceT (T *&aRolePtr)
bool ComponentHasRole (int aRole)
 Returns true if the component has the specified role.
virtual bool PreInitialize (double aSimTime)
virtual bool Initialize (double aSimTime)
virtual bool Initialize2 (double aSimTime)
virtual void PreInput ()
virtual bool ProcessInput (UtInput &aInput)
Public Member Functions inherited from WsfNamed
 WsfNamed ()
 WsfNamed (WsfStringId aName)
 WsfNamed (const WsfNamed &)=default
WsfNamedoperator= (const WsfNamed &)=default
virtual ~WsfNamed ()=default
const std::string & GetName () const
WsfStringId GetNameId () const
void SetName (WsfStringId aName)

Component interface.

WsfComponentCloneComponent () const override
void * QueryInterface (int aRole) override
void ComponentParentChanged (WsfXIO_Simulation *aXIO_SimulationPtr) override
 Called when the component is added to the XIO interface.

Miscellaneous methods.

WsfXIO_SimulationGetXIO_Simulation () const
WsfSimulationGetSimulation () const
double GetSimTime () const

WsfXIO_Component interface.

void EM_RcvrInfo_Load (WsfXIO_EM_RcvrInfo &aInfo, const WsfEM_Rcvr &aRcvr) override
void EM_XmtrInfo_Load (WsfXIO_EM_XmtrInfo &aInfo, const WsfEM_Xmtr &aXmtr) override
WsfXIO_PlatformPartInfoCreatePlatformPartInfo (WsfPlatformPart &aPart) override
 Called from WsfXIO_PlatformPartInfo::Create to process an unrecognized platform part type.
void RegisterSimulationObservers (WsfSimulation &aSimulation, UtCallbackHolder &aCallbacks) override
 Called from WsfXIO_PlatformInfoService::UpdateCallbacks.
bool FillPartState (const WsfPlatformPart &aPart, WsfXIO_PartStateChangePkt &aPkt) override
 Called from WsfXIO_PlatformInfoService::FillPartState.
WsfObjectFindPartType (int aPartType, WsfStringId aPartTypeName) override
 Called from WsfXIO_PlatformInfoService::FindObjectType.
WsfObjectFindPart (const WsfPlatform &aPlatform, int aPartType, WsfStringId aPartName) override
 Called from WsfXIO_PlatformInfoService::FindObjectType.
bool HandleStateChangeRequest (double aSimTime, WsfXIO_PartStateChangeRequestPkt &aPkt, WsfPlatform *aPlatformPtr, WsfEM_Xmtr *&aXmtrPtr, WsfEM_Rcvr *&aRcvrPtr) override
bool HandleTaskCommand (double aSimTime, WsfXIO_TaskCommandPkt &aPkt, WsfTaskProcessor *aProcA_Ptr, WsfTaskProcessor *aProcB_Ptr, WsfTrack *aTrackPtr, WsfTaskResource *aResourcePtr) override

Additional Inherited Members

int mRoles [2]

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Equate generic definitions in the packet registry to more meaningful definitions;.

Enumerator
cWEAPON_INFO 
cABORT_FIRE 

Constructor & Destructor Documentation

◆ WsfXIO_WeaponComponent()

WsfXIO_WeaponComponent::WsfXIO_WeaponComponent ( )

◆ ~WsfXIO_WeaponComponent()

WsfXIO_WeaponComponent::~WsfXIO_WeaponComponent ( )
overridedefault

Member Function Documentation

◆ CloneComponent()

WsfComponent * WsfXIO_WeaponComponent::CloneComponent ( ) const
inlineoverridevirtual

Clones a component. May return null if component does not support clone.

Implements WsfComponent.

References WsfXIO_WeaponComponent().

◆ ComponentParentChanged()

void WsfXIO_WeaponComponent::ComponentParentChanged ( WsfXIO_Simulation * aXIO_SimulationPtr)
override

◆ CreatePlatformPartInfo()

WsfXIO_PlatformPartInfo * WsfXIO_WeaponComponent::CreatePlatformPartInfo ( WsfPlatformPart & aPart)
overridevirtual

Called from WsfXIO_PlatformPartInfo::Create to process an unrecognized platform part type.

Reimplemented from WsfXIO_Component.

References GetXIO_Simulation(), and WsfComponent::QueryInterfaceT().

◆ EM_RcvrInfo_Load()

void WsfXIO_WeaponComponent::EM_RcvrInfo_Load ( WsfXIO_EM_RcvrInfo & aInfo,
const WsfEM_Rcvr & aRcvr )
overridevirtual

Reimplemented from WsfXIO_Component.

References WsfEW_EP::GetElectronicProtect().

◆ EM_XmtrInfo_Load()

void WsfXIO_WeaponComponent::EM_XmtrInfo_Load ( WsfXIO_EM_XmtrInfo & aInfo,
const WsfEM_Xmtr & aXmtr )
overridevirtual

Reimplemented from WsfXIO_Component.

References WsfEW_EA::GetElectronicAttack().

◆ FillPartState()

◆ FindPart()

WsfObject * WsfXIO_WeaponComponent::FindPart ( const WsfPlatform & aPlatform,
int aPartType,
WsfStringId aPartName )
overridevirtual

◆ FindPartType()

WsfObject * WsfXIO_WeaponComponent::FindPartType ( int aPartType,
WsfStringId aPartTypeName )
overridevirtual

◆ GetSimTime()

double WsfXIO_WeaponComponent::GetSimTime ( ) const

◆ GetSimulation()

WsfSimulation & WsfXIO_WeaponComponent::GetSimulation ( ) const

◆ GetXIO_Simulation()

WsfXIO_Simulation * WsfXIO_WeaponComponent::GetXIO_Simulation ( ) const
inline

◆ HandleStateChangeRequest()

◆ HandleTaskCommand()

bool WsfXIO_WeaponComponent::HandleTaskCommand ( double aSimTime,
WsfXIO_TaskCommandPkt & aPkt,
WsfTaskProcessor * aProcA_Ptr,
WsfTaskProcessor * aProcB_Ptr,
WsfTrack * aTrackPtr,
WsfTaskResource * aResourcePtr )
overridevirtual

◆ QueryInterface()

void * WsfXIO_WeaponComponent::QueryInterface ( int aRole)
inlineoverridevirtual

Requests a component's role interface. A component can support one or more roles.

Parameters
aRoleThe role whose interface is to be returned.
Returns
A pointer to the object if it supports the indicated role, or 'null' if it does not. Usage: WsfProcessor* procPtrOrNull = (WsfProcessor*)componentPtr->QueryComponentInterface(cWSF_COMPONENT_PROCESSOR);

Implements WsfComponent.

References WsfSimpleComponentT< WsfComponentT< PARENT_TYPE > >::mRoles.

◆ RegisterSimulationObservers()


The documentation for this class was generated from the following files:
Copyrights Multiple, All Rights Reserved