|
WSF
|
A 'status message' provides status about an operation. More...
#include <WsfStatusMessage.hpp>


Public Member Functions | |
| WsfStatusMessage () | |
| Constructor, for XIO (de)serialization (create a Status message). | |
| WsfStatusMessage (WsfSimulation &aSimulation) | |
| WsfStatusMessage (WsfPlatform *aPlatformPtr) | |
| WsfStatusMessage (WsfStringId aStatusId, WsfPlatform *aPlatformPtr) | |
| WsfMessage * | Clone () const override |
| const char * | GetScriptClassName () const override |
| Public Member Functions inherited from WsfMessage | |
| WsfMessage (WsfStringId aType) | |
| Constructor for XIO (de)serialization. | |
| WsfMessage (WsfStringId aType, const wsf::comm::Address &aSrcAddr, WsfSimulation &aSimulation) | |
| WsfMessage (WsfPlatform *aPlatformPtr) | |
| WsfMessage (WsfStringId aType, WsfPlatform *aPlatformPtr) | |
| WsfMessage (WsfStringId aType, WsfStringId aSubType, WsfPlatform *aPlatformPtr) | |
| WsfMessage (WsfSimulation &aSimulation) | |
| WsfMessage & | operator= (const WsfMessage &aRhs)=default |
| ~WsfMessage () override | |
| const char * | GetScriptClassName () const override |
| WsfSimulation * | GetSimulation () const |
| Get the simulation that owns the message. | |
| void | SetSimulation (WsfSimulation *aSimulationPtr) |
| WsfStringId | GetOriginator () const |
| void | SetOriginator (WsfPlatform *aPlatformPtr) |
| Set the originator of this message. | |
| size_t | GetOriginatorIndex () const |
| int | GetSizeBits () const |
| void | SetSizeBits (int aSizeBits) |
| int | GetSizeBytes () const |
| void | SetSizeBytes (int aSizeBytes) |
| unsigned int | GetSerialNumber () const |
| void | SetSerialNumber (unsigned int aSerialNumber) |
| double | GetDataTag () const |
| void | SetDataTag (double aDataTag) |
| WsfStringId | GetStaticType () const |
| WsfStringId | GetType () const |
| void | SetType (WsfStringId aType) |
| WsfStringId | GetSubType () const |
| void | SetSubType (WsfStringId aSubType) |
| int | GetPriority () const |
| void | SetPriority (int aPriority) |
| const wsf::comm::Address & | GetSrcAddr () const |
| void | SetSrcAddr (const wsf::comm::Address &aSrcAddr) |
| const wsf::comm::Address & | GetDstAddr () const |
| void | SetDstAddr (const wsf::comm::Address &aDstAddr) |
| const wsf::comm::Address & | GetNextHopAddr () const |
| void | SetNextHopAddr (const wsf::comm::Address &aNextHopAddr) |
| virtual bool | CanBeReplacedBy (const WsfMessage &aMessage) const |
| WsfStringId | GetGroup () const |
| void | SetGroup (WsfStringId aGroup) const |
| void | PrintDataTagPrecise (std::ostream &aStream, std::streamsize aPrecision) const |
| template<typename T> | |
| void | Serialize (T &aBuff) |
| (De)serializer for XIO | |
| virtual WsfStringId | GetComponentNameId () const |
| virtual WsfStringId | GetComponentTypeId () const |
| virtual WsfStringId | GetComponentModeId () const |
| Public Member Functions inherited from WsfAuxDataEnabled | |
| WsfAuxDataEnabled ()=default | |
| WsfAuxDataEnabled (const WsfAuxDataEnabled &aSrc)=default | |
| WsfAuxDataEnabled & | operator= (const WsfAuxDataEnabled &aRhs) |
| WsfAuxDataEnabled (WsfAuxDataEnabled &&)=default | |
| WsfAuxDataEnabled & | operator= (WsfAuxDataEnabled &&)=default |
| virtual | ~WsfAuxDataEnabled () noexcept |
| void | SetAuxData (const WsfAttributeContainer &aAuxData) |
| void | DeleteAuxData () |
| Delete the aux data container from the object. | |
| void | MergeAuxData (const WsfAuxDataEnabled &aSrc) |
| Merge the object's aux data with aux data from an existing object. | |
| void | UpdateAuxData (const WsfAuxDataEnabled &aSrc) |
| Update the object's aux data with aux data from an existing object. | |
| bool | HasAuxData () const |
| Returns true if this object has aux data. | |
| bool | ProcessInput (UtInput &aInput) |
| template<typename T> | |
| void | Serialize (T &aBuff) |
| (De)serialization for XIO | |
| WsfAttributeContainer & | GetAuxData () |
| const WsfAttributeContainer & | GetAuxData () const noexcept |
| const WsfAttributeContainer & | GetAuxDataConst () const noexcept |
Static Public Member Functions | |
| static std::unique_ptr< UtScriptClass > | CreateScriptClass (const std::string &aClassName, UtScriptTypes *aScriptTypesPtr) |
| static WsfStringId | GetTypeId () |
| Static Public Member Functions inherited from WsfMessage | |
| static WsfStringId | GetTypeId () |
Platform methods. | |
A status may sometimes deal with another platform (such as a spawned object).
| |
| WsfTrackId | mRequestId |
| The request ID to which the status pertains. | |
| WsfStringId | mSystemNameId |
| The system name ID to which the status pertains. | |
| size_t | mPlatformIndex |
| The other platform index. | |
| WsfPlatform * | GetPlatform () const |
| size_t | GetPlatformIndex () const |
| void | SetPlatform (WsfPlatform *aPlatformPtr) |
| void | SetPlatformIndex (size_t aPlatformIndex) |
| template<typename T> | |
| void | Serialize (T &aBuff) |
| For XIO (de)serialization. | |
Status methods. | |
The message status is a string ID that represents the status being reported. The status values and their interpretation are defined by convention. | |
| WsfStringId | GetStatusId () const |
| Get the status (string ID form). | |
| const std::string & | GetStatus () const |
| Get the Status (string form). | |
| void | SetStatusId (WsfStringId aStatusId) |
| Set the status (string ID form). | |
| void | SetStatus (WsfStringId aStatus) |
Request ID methods. | |
A status may be associated with a particular request (e.g.: a command). These methods are concerned with the identifier of the request. | |
| const WsfTrackId & | GetRequestId () const |
| Get the request ID to which the status applies. | |
| void | SetRequestId (const WsfTrackId &aRequestId) |
| Set the request ID to which the status applies. | |
System name methods. | |
A status may be associated with a particular system (e.g.: sensor, comm, mover, etc.) These methods are concerned the name of the system to which the status applies. | |
| WsfStringId | GetSystemNameId () const |
| std::string | GetSystemName () const |
| void | SetSystemNameId (WsfStringId aSystemNameId) |
| void | SetSystemName (const std::string &aSystemName) |
Additional Inherited Members | |
| Static Public Attributes inherited from WsfMessage | |
| static constexpr size_t | cBITS_IN_BYTE = 8U |
| Static Public Attributes inherited from WsfAuxDataEnabled | |
| static UtCallbackListN< void(const WsfAuxDataEnabled *)> | AuxDataAccessed |
| static UtCallbackListN< void(const WsfAuxDataEnabled *)> | AuxDataDestroyed |
| WsfMessage (const WsfMessage &aSrc)=default | |
A 'status message' provides status about an operation.
| WsfStatusMessage::WsfStatusMessage | ( | ) |
Constructor, for XIO (de)serialization (create a Status message).
References GetTypeId(), mPlatformIndex, mRequestId, mSystemNameId, and WsfMessage::WsfMessage().
Referenced by Clone(), and WsfStatusMessage().
| WsfStatusMessage::WsfStatusMessage | ( | WsfSimulation & | aSimulation | ) |
References CreateScriptClass(), WsfMessage::WsfMessage(), and WsfStatusMessage().
| WsfStatusMessage::WsfStatusMessage | ( | WsfPlatform * | aPlatformPtr | ) |
Constructor (create a Status message)
| aPlatformPtr | The originator of the message. |
References GetTypeId(), mPlatformIndex, mRequestId, mSystemNameId, and WsfMessage::WsfMessage().
| WsfStatusMessage::WsfStatusMessage | ( | WsfStringId | aStatusId, |
| WsfPlatform * | aPlatformPtr ) |
Constructor (create a Status message)
| aStatusId | The status as a string ID. |
| aPlatformPtr | The originator of the message. |
References GetTypeId(), mPlatformIndex, mRequestId, mSystemNameId, and WsfMessage::WsfMessage().
|
overridevirtual |
Create a clone of this message (the 'virtual copy constructor').
Reimplemented from WsfMessage.
References WsfMessage::WsfMessage(), and WsfStatusMessage().
|
static |
Create the 'class' object for the script system. This is invoked once by WsfScriptManager to create the 'class' object that defines the interface to instances of this class from the script system.
Referenced by WsfScriptManager::RegisterTypes(), and WsfStatusMessage().
| WsfPlatform * WsfStatusMessage::GetPlatform | ( | ) | const |
Get the pointer to the other platform.
References WsfSimulation::GetPlatformByIndex(), WsfMessage::GetSimulation(), and mPlatformIndex.
|
inline |
References mPlatformIndex.
Referenced by WsfXIO_AutoDisMapping::TranslateStatusMessage().
|
inline |
Get the request ID to which the status applies.
References mRequestId.
Referenced by WsfTrackStateController::ProcessMessage().
|
override |
| const std::string & WsfStatusMessage::GetStatus | ( | ) | const |
Get the Status (string form).
References WsfMessage::GetSubType().
Referenced by WsfTrackStateController::ProcessMessage().
|
inline |
Get the status (string ID form).
References WsfMessage::GetSubType().
Referenced by WsfPlatformPart::ProcessMessage(), and WsfTrackStateController::ProcessMessage().
| std::string WsfStatusMessage::GetSystemName | ( | ) | const |
Get the system name (string form).
References mSystemNameId.
|
inline |
Get the system name (string ID form).
References mSystemNameId.
Referenced by WsfMessageProcessor::Selector::Matches(), and WsfPlatformPart::ProcessMessage().
|
static |
Get the type ID associated with this message.
Referenced by WsfXIO_MessageService::HandleMessage(), WsfXIO_AutoDisMapping::Initialize(), WsfMessageProcessor::Selector::Matches(), WsfDefaultAssetManagerImpl::on_message(), WsfPlatformPart::ProcessMessage(), WsfTrackStateController::ProcessMessage(), WsfStatusMessage(), WsfStatusMessage(), and WsfStatusMessage().
|
inline |
For XIO (de)serialization.
References mPlatformIndex, mRequestId, mSystemNameId, and WsfMessage::Serialize().
| void WsfStatusMessage::SetPlatform | ( | WsfPlatform * | aPlatformPtr | ) |
Set the pointer to the other platform.
| aPlatformPtr | The pointer to the |
References WsfPlatform::GetIndex(), and mPlatformIndex.
Referenced by WsfExplicitWeapon::AddWeaponToSimulation().
|
inline |
References mPlatformIndex.
Referenced by WsfXIO_AutoDisMapping::TranslateStatusMessage().
|
inline |
Set the request ID to which the status applies.
References mRequestId.
Referenced by WsfExplicitWeapon::AddWeaponToSimulation().
| void WsfStatusMessage::SetStatus | ( | WsfStringId | aStatus | ) |
|
inline |
Set the status (string ID form).
References WsfMessage::SetSubType().
| void WsfStatusMessage::SetSystemName | ( | const std::string & | aSystemName | ) |
Set the system name (string form).
| aSystemName | The system name to which the status applied. If empty then the status does not apply to a particular system. |
References mSystemNameId.
|
inline |
Set the system name (string ID form).
| aSystemNameId | The string ID of the system name to which the status applied. If zero then the status does not apply to a particular system. |
References mSystemNameId.
Referenced by WsfExplicitWeapon::AddWeaponToSimulation(), WsfPlatformPart::PartBroken(), WsfPlatformPart::SetNonOperational(), WsfPlatformPart::SetOperational(), WsfPlatformPart::TurnOff(), and WsfPlatformPart::TurnOn().
|
protected |
The other platform index.
Referenced by GetPlatform(), GetPlatformIndex(), Serialize(), SetPlatform(), SetPlatformIndex(), WsfStatusMessage(), WsfStatusMessage(), and WsfStatusMessage().
|
protected |
The request ID to which the status pertains.
Referenced by GetRequestId(), Serialize(), SetRequestId(), WsfStatusMessage(), WsfStatusMessage(), and WsfStatusMessage().
|
protected |
The system name ID to which the status pertains.
Referenced by GetSystemName(), GetSystemNameId(), Serialize(), SetSystemName(), SetSystemNameId(), WsfStatusMessage(), WsfStatusMessage(), and WsfStatusMessage().