WSF
WsfSpaceMoverBase Class Reference

#include <WsfSpaceMoverBase.hpp>

Inheritance diagram for WsfSpaceMoverBase:
Collaboration diagram for WsfSpaceMoverBase:

Classes

class  SpaceModel

Public Member Functions

 WsfSpaceMoverBase ()=delete
 WsfSpaceMoverBase (const WsfScenario &aScenario, std::unique_ptr< UtOrbitalPropagatorBase > aPropagatorPtr, const std::string &aScriptClassName="WsfSpaceMover")
 WsfSpaceMoverBase (const WsfSpaceMoverBase &aSrc)
WsfSpaceMoverBaseoperator= (const WsfSpaceMoverBase &)=delete
 ~WsfSpaceMoverBase () override
Public Member Functions inherited from WsfMover
 WsfMover ()=delete
 WsfMover (const WsfScenario &aScenario)
 WsfMover (const WsfMover &aSrc)
WsfMoveroperator= (const WsfMover &)=delete
 ~WsfMover () override
virtual double TurnRadius (double atSpeed)
WsfModeListGetModeList () const
virtual void TriggerExtrapolation ()
WsfComponentCloneComponent () const override
int GetComponentInitializationOrder () const override
const char * GetScriptClassName () const override
virtual void SwapMoverInitiated (double aSimTime, WsfMover *aOldMoverPtr)
void TurnOff (double aSimTime) override
void TurnOn (double aSimTime) override
void SetNonOperational (double aSimTime) override
void SetOperational (double aSimTime) override
void PartBroken (double aSimTime) override
void Restore (double aSimTime) override
virtual bool IsStopped () const
 Return whether the mover (and its attached platform) is stopped.
virtual bool IsPaused () const
virtual void SetHeading (double aHeading)
virtual void SetPitch (double aPitch)
virtual void SetRoll (double aRoll)
virtual void SetOrientationNED (double aHeading, double aPitch, double aRoll)
virtual void ResetPosition (double aSimTime)
 Informs the mover to use the current platform state.
double GetLastUpdateTime () const
double GetUpdateInterval () const override
double GetUpdateTimeTolerance () const
void SetUpdateInterval (double aUpdateInterval) override
void SetLastUpdateTime (double aLastUpdateTime)
virtual bool UpdateAllowed () const
bool UpdateWhenBroken () const
void SetUpdateWhenBroken ()
void SetNoUpdateWhenBroken ()
virtual const WsfRouteGetRoute () const
virtual const WsfRouteGetDefaultRoute () const
virtual int RoutePointIndex () const
virtual bool GoToAltitude (double aSimTime, double aAltitude, double aClimbDiveRate, bool aKeepRoute)
virtual bool ReturnToRoute (double aSimTime)
virtual bool GoToClosestPoint (double aSimTime)
virtual bool GoToLabel (double aSimTime, WsfStringId aLabelId)
virtual bool GoToLocation (double aSimTime, double aLatitude, double aLongitude, double aAltitude)
virtual bool GoToSpeed (double aSimTime, double aSpeed, double aLinearAccel, bool aKeepRoute)
virtual bool TurnToHeading (double aSimTime, double aHeading, double aRadialAccel, WsfPath::TurnDirection aTurnDirection)
virtual bool TurnToRelativeHeading (double aSimTime, double aHeadingChange, double aRadialAccel, WsfPath::TurnDirection aTurnDirection)
virtual bool SetRoute (double aSimTime, const WsfRoute &aRoute)
virtual bool UpdateRoute (double aSimTime, const WsfRoute &aRoute)
virtual bool UpdateDefaultRoute ()
virtual bool GoToWaypoint (double aSimTime, unsigned int aDestination)
virtual bool FindAndSetPath (double aSimTime, WsfGeoPoint *aStartPtr, WsfGeoPoint *aEndPtr)
virtual bool FlyRates (const UtVec3d &aAngularRates, const UtVec3d &aLongitudinalAccel)
virtual bool FlyHeadingSpeedAltitude (double aHeading, double aSpeed, double aAltitude, double aMaxGees, double aMaxClimb)
virtual bool TurnInPlaneWithSpeed (const UtVec3d &aPlane, double aGees, double aSpeed)
virtual bool TurnInPlaneWithThrottle (const UtVec3d &aPlane, double aGees, double aThrottle)
virtual bool FlyVectorWithSpeed (const UtVec3d &aVelocityVector, double aMaxGees, double aSpeed)
virtual bool FlyVectorWithThrottle (const UtVec3d &aVelocityVector, double aMaxGees, double aThrottle)
virtual bool ExecuteTriggers (double aSimTime, unsigned int aPointIndex)
WsfStringId GetModeId () const
virtual void SetMode (WsfStringId aModeName)
bool ThreadSafe () const
 Returns true if the mover update is thread safe.
void SetThreadSafe ()
void SetNotThreadSafe ()
virtual void InitializeProperties ()
 Add any input properties and its default value common properties list.
virtual bool PropertyExists (const std::string &aPropertyName)
 Return true if the given property exists in the set of properties.
virtual void RegisterProperty (const std::string &aPropertyName, const int &aProperty)
 Add an integer property to the common set of properties.
virtual void RegisterProperty (const std::string &aPropertyName, const double &aProperty)
 Add an floating point property to the common set of properties.
virtual void RegisterProperty (const std::string &aPropertyName, const std::string &aProperty)
 Add an string property to the set of common properties.
virtual bool GetPropertyInt (const std::string &aPropertyName, int &aProperty)
virtual bool GetPropertyDouble (const std::string &aPropertyName, double &aProperty)
virtual bool GetPropertyString (const std::string &aPropertyName, std::string &aProperty)
virtual double GetThrottlePosition ()
Public Member Functions inherited from WsfPlatformPart
 WsfPlatformPart (const WsfScenario &aScenario, int aPartType)
WsfPlatformPartoperator= (const WsfPlatformPart &aRhs)=delete
 ~WsfPlatformPart () override
bool DebugEnabled () const
 Returns 'true' if debugging is enabled for this instance.
void SetDebugEnabled (bool aDebugEnabled)
unsigned int GetDebugMask ()
bool IsExternallyControlled () const
virtual void SetExternallyControlled (double aSimTime, bool aIsExternallyControlled)
int GetPartType () const
const char * GetScriptClassName () const override
WsfSimulationGetSimulation () const
const WsfScenarioGetScenario () const
WsfStringId GetComponentName () const override
void ComponentParentChanged (WsfPlatform *aPlatformPtr) override
WsfPlatformGetPlatform () const
virtual void SetPlatform (WsfPlatform *aPlatformPtr)
virtual void PlatformAdded (double aSimTime, WsfPlatform *aPlatformPtr)
virtual void PlatformDeleted (WsfPlatform *aPlatformPtr)
double GetLastStatusChangeTime () const
void SetLastStatusChangeTime (double aSimTime)
 Allows a system to set the time at which the device was initialized.
bool CanBeMadeOperational () const
 Returns an indication that this system can be made operational.
bool CanBeMadeNonOperational () const
 Returns an indication that this system can be made non-operational.
bool CanBeTurnedOn () const
 Returns an indication that this system can be turned on.
bool CanBeTurnedOff () const
 Returns an indication that this system can be turned off.
bool IsTurnedOn () const
bool InitiallyTurnedOn () const
 Is the system to be turned 'on' when added to the simulation?
void SetInitiallyTurnedOn (bool aInitiallyTurnedOn)
 Sets if the system is turned on when added to the simulation.
bool IsOperational () const
bool SetOperational (double aSimTime, bool aMakeOperational)
double GetDamageFactor () const
bool SetDamageFactor (double aSimTime, double aDamageFactor)
bool IsCritical () const
void SetCritical (bool aValue)
virtual void OnPlatformBrokenEvent (double aSimTime)
 Owning platform has issued a broken event.
bool IsBroken () const
WsfInternalLinksGetInternalLinks ()
 Return the internal links for this part.
virtual bool HasInternalLinks () const
 Does this platform part have a communication link to other platform parts?
virtual bool ProcessMessage (double aSimTime, const WsfMessage &aMessage)
virtual bool ReceiveMessage (double aSimTime, const WsfMessage &aMessage)
virtual void SendMessage (double aSimTime, const WsfMessage &aMessage)
virtual void SendMessageTo (double aSimTime, const WsfMessage &aMessage, WsfStringId aRecipientId)
void SendMessageToProcessor (double aSimTime, const WsfMessage &aMessage, WsfStringId aRecipientId)
virtual void SendQueuedMessages (double aSimTime)
const WsfCategoryListGetCategories () const
 Get the categories to which this part belongs.
void AddCategory (WsfStringId aCategoryId)
 Adds the provided category to the platform part's category list.
bool IsCategoryMember (WsfStringId aCategoryId) const
const WsfGroupListGetGroups () const
 Get the groups to which this platform part belongs.
void JoinGroup (WsfGroup *aGroupPtr)
 Join the given group.
void LeaveGroup (WsfGroup *aGroupPtr)
 Leave the given group.
bool IsGroupMember (WsfStringId aGroupId)
unsigned int GetUpdateEventEpoch () const
void IncrementUpdateEventEpoch ()
bool UpdateEventActive () const
 Is an 'Update' event active?
void SetUpdateEventActive (bool aUpdateEventActive)
 Indicate if the 'Update' event is active.
Public Member Functions inherited from WsfObject
 WsfObject ()
 This is the constructor for the WsfObject class.
 ~WsfObject () override
 This is the destructor for the WsfObject class.
const char * GetScriptClassName () const override
const std::string & GetType () const
WsfStringId GetTypeId () const
 Get the string ID of the 'type' of the object.
void SetType (WsfStringId aType)
const std::string & GetBaseType () const
WsfStringId GetBaseTypeId () const
const TypeListGetTypeList () const
bool IsA_TypeOf (WsfStringId aType) const
WsfObjectoperator= (const WsfObject &aRhs)
 Assignment operator.
template<typename T>
void Serialize (T &aBuff)
 For XIO (de)serialization.
const std::string & GetName () const
WsfStringId GetNameId () const
void SetName (WsfStringId aName)
Public Member Functions inherited from WsfComponentT< WsfPlatform >
 WsfComponentT ()
 WsfComponentT (const WsfComponentT &) noexcept
WsfComponentToperator= (const WsfComponentT &) noexcept
 ~WsfComponentT () override=default
ParentTypeGetComponentParent () const
void SetComponentParent (ParentType *aParentPtr)
Public Member Functions inherited from WsfComponent
virtual ~WsfComponent ()=default
template<typename T>
bool QueryInterfaceT (T *&aRolePtr)
bool ComponentHasRole (int aRole)
 Returns true if the component has the specified role.
virtual void PreInput ()
Public Member Functions inherited from WsfUniqueId
 WsfUniqueId ()
 Construtor initializes the unique identifier to 0.
 WsfUniqueId (const WsfUniqueId &)
 Copy constructor initializes the unique identifier to 0.
WsfUniqueIdoperator= (const WsfUniqueId &)
unsigned int GetUniqueId () const
 Get the unique identifier assigned to this object.
template<typename T>
void Serialize (T &aBuff)
 For XIO (de)serialization.
Public Member Functions inherited from WsfAuxDataEnabled
 WsfAuxDataEnabled ()=default
 WsfAuxDataEnabled (const WsfAuxDataEnabled &aSrc)=default
WsfAuxDataEnabledoperator= (const WsfAuxDataEnabled &aRhs)
 WsfAuxDataEnabled (WsfAuxDataEnabled &&)=default
WsfAuxDataEnabledoperator= (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
WsfAttributeContainerGetAuxData ()
const WsfAttributeContainerGetAuxData () const noexcept
const WsfAttributeContainerGetAuxDataConst () const noexcept

WsfSpaceMoverBase Initial State Accessors

WSF_SPACE_DEPRECATED WsfGeoPoint GetInitialPositionLLA () const
UtVec3d GetInitialPositionECI () const
UtVec3d GetInitialPositionWCS () const
UtVec3d GetInitialVelocityECI () const
UtVec3d GetInitialVelocityWCS () const
const char * GetScriptClassName () const override
WsfSpatialDomain GetSpatialDomain () const override
bool IsExtrapolating () const override
const UtOrbitalPropagatorBase & GetPropagator () const
 Return a reference to the orbital propagator associated with this space mover.
UtOrbitalPropagatorBase & GetPropagator ()
 Return a reference to the orbital propagator associated with this space mover (non-const version).
const WsfOrbitalManeuveringGetOrbitalManeuvering () const
 Return the maneuvering model for this space mover.
bool InitializeOrbitalManeuvering (const UtCalendar &aEpoch)
 Initialize just the orbital maneuvering model.
const WsfOrbitalEventGetCurrentMissionEvent () const
 Return the current maneuver, if any, being performed by this mover.
const WsfOrbitalMissionSequenceGetMissionEvents () const
void ScheduleMission (const UtCalendar &aEpoch, std::unique_ptr< WsfOrbitalMissionSequence > aMissionEventsPtr)
void CancelMission ()
bool VerifyMission (const UtCalendar &aEpoch, const WsfOrbitalMissionSequence &aSequence, wsf::space::verify::PreOperation aPreVerifyOp=wsf::space::verify::PreOperation{}, wsf::space::verify::PostOperation aPostVerifyOp=wsf::space::verify::PostOperation{}) const
bool VerifyMission (const UtCalendar &aEpoch) const
WsfAttitudeControllerGetAttitudeController ()
 Return a reference to the attitude controller associated with this space mover.
double GetSimTimeOfEpoch () const
WsfScriptContextGetScriptContext ()
 Return a reference to the script context.
void UpdatePropagation (const UtCalendar &aEpoch)
const UtCalendar & GetCurrentTime () const
 Get the current propagation time.
double GetElementOutputUpdateInterval () const
 Get the interval between entries in an event pipe of this mover's elements.
const std::string & GetDescriptor () const
 Return the descriptor associated with this mover.
const std::string & GetDesignator () const
 Return the designator associated with this mover.
const ut::OrbitalState & GetInitialOrbitalState () const
 Return the initial unpropagated orbital state.
double GetInitialHeading () const
void SetInitialOrbitalState (const ut::OrbitalState &aState)
 A pass-through method to set the initial orbital state.
bool GetFutureLocationWCS (double aSimTime, double aLocationWCS[3]) final
 Return the WCS location at some time aSimTime in the future.
WsfMover::KinematicModelCreateKinematicModel (double aSimTime, WsfStringId aModelTypeId, const double aLocationWCS[3], const double aVelocityWCS[3], WsfMover *aMoverPtr, WsfDraw *aDrawPtr) const override
void SetTargetOrientationECI (double aPsi, double aTheta, double aPhi)
 Set the mover's target ECI orientation.
ut::optional< UtColor > GetOrbitColor () const
UtColor GetOrbitColorValue () const
bool OrbitColorSet () const
void UpdateColor (double aSimTime, const UtColor &aColor)
void SetOrbitColor (const std::string &aOrbitColor)
void SetOrbitColor (const UtColor &aOrbitColor)
bool IsTLEInputAllowed () const noexcept
void SetTLEInputAllowed (bool aTLE_InputAllowed) noexcept
double GetLookAngleTo (const UtVec3d &aLocationWCS) const
double GetIncidenceAngle (const UtVec3d &aLocationWCS) const
double GetTargetElevationAngle (const UtVec3d &aLocationWCS) const
double GetSquintAngleTo (const UtVec3d &aLocationWCS) const
double GetDistanceToHorizon () const
double GetLookAngleToHorizon () const

Common framework methods.

WsfMoverClone () const override
const int * GetComponentRoles () const override
void * QueryInterface (int aRole) override
bool PreInitialize (double aSimTime) override
bool Initialize (double aSimTime) override
bool Initialize2 (double aSimTime) override
bool ProcessInput (UtInput &aInput) override
void Update (double aSimTime) override

Mostly pass-through methods that are optionally supported by the maneuvering model.

const ut::OrbitalState & GetOrbitalState () const
 Return the current propagated orbital state.
double GetAvailableDeltaV () const
double GetRequiredDuration (double aDeltaV) const
double GetRequiredDeltaV (double aDuration) const
double GetManeuverDuration (const UtCalendar &aEpoch, const WsfOrbitalManeuver &aManeuver, double aDeltaV) const
bool PerformStagingOperation ()
const ut::CentralBody & GetCentralBody () const
const ut::CentralPoint & GetCentralPoint () const
bool Maneuver (const UtCalendar &aEpoch, const UtVec3d &aCommandedDeltaV, UtVec3d &aActualDeltaV)
virtual bool SetInitialPoint (double aLat, double aLon, double aAlt, double aSpeed, double aHeading)

Additional Inherited Members

Public Types inherited from WsfPlatformPart
enum  { cLEVEL_ONE_DEBUG = 0x00000001 , cLEVEL_TWO_DEBUG = 0x00000002 }
using InternalMessageQueue = std::queue<WsfMessage*>
using RecipientMessageQueue = std::queue<std::pair<WsfPlatformPart*, WsfMessage*>>
Public Types inherited from WsfObject
typedef std::vector< WsfStringIdTypeList
 The list of types returned by GetTypeList.
Public Types inherited from WsfComponentT< WsfPlatform >
typedef WsfPlatform ParentType
 This is needed to support the WsfComponentList template.
Static Public Attributes inherited from WsfMover
static const char * cTYPE_KIND = "mover"
Static Public Attributes inherited from WsfAuxDataEnabled
static UtCallbackListN< void(const WsfAuxDataEnabled *)> AuxDataAccessed
static UtCallbackListN< void(const WsfAuxDataEnabled *)> AuxDataDestroyed
void SetModeList (WsfModeList *aModeListPtr)
void SetUpdateTimeTolerance (double aDt)
 Revise the internal time tolerance allowed for Update() sequencing logic.
 WsfPlatformPart (const WsfPlatformPart &aSrc)
 Copy constructor (for Clone()).
 WsfObject (const WsfObject &aSrc)
 Copy constructor (for Clone()).
Protected Member Functions inherited from WsfUniqueId
void AssignUniqueId (WsfSimulation *aSimulationPtr)
double mLastUpdateTime
 The simulation time when Update was last called.
WsfVariable< double > mUpdateTimeTolerance
bool mThreadSafe
std::vector< WsfMoverMode * > mMoverModeList
 The generic list of modes (not valid until Initialize is called).
WsfStringId mModeId

Detailed Description

WsfSpaceMoverBase is a base class for Space-Based movers (in the WSF project these are WsfSpaceMover and WsfNORAD_SpaceMover). Notably, this class aggregates the orbital propagator object as a UtOrbtialPropagatorBase*. The way to implement a derived class with a derived mover is to instantiate the derived mover in the constructor, as follows:

class MyDerivedPropagator : public UtOrbitalPropagagorBase
{
...
};
class MyDerivedSpaceMover : public WsfSpaceMoverBase
{
public:
MyDerivedSpaceMover()
{
mPropagatorPtr = new MyDerivedPropagator();
...
}
Definition WsfSpaceMoverBase.hpp:70

Constructor & Destructor Documentation

◆ WsfSpaceMoverBase() [1/3]

◆ WsfSpaceMoverBase() [2/3]

WsfSpaceMoverBase::WsfSpaceMoverBase ( const WsfScenario & aScenario,
std::unique_ptr< UtOrbitalPropagatorBase > aPropagatorPtr,
const std::string & aScriptClassName = "WsfSpaceMover" )

◆ WsfSpaceMoverBase() [3/3]

WsfSpaceMoverBase::WsfSpaceMoverBase ( const WsfSpaceMoverBase & aSrc)

◆ ~WsfSpaceMoverBase()

WsfSpaceMoverBase::~WsfSpaceMoverBase ( )
override

Member Function Documentation

◆ CancelMission()

void WsfSpaceMoverBase::CancelMission ( )

Cancel the current mission. The current mission event will cease to be executed, even though it may not have actually achieved its goal. Future events will be deleted, and the parent platform will propagate using its current state.

References WsfPlatformPart::GetScenario().

◆ Clone()

WsfMover * WsfSpaceMoverBase::Clone ( ) const
overridevirtual

Clone this object.

Returns
a pointer to the new object.

Implements WsfMover.

References WsfMover::WsfMover(), and WsfSpaceMoverBase().

◆ CreateKinematicModel()

WsfMover::KinematicModel * WsfSpaceMoverBase::CreateKinematicModel ( double aSimTime,
WsfStringId aPlatformTypeId,
const double aLocationWCS[3],
const double aVelocityWCS[3],
WsfMover * aMoverPtr,
WsfDraw * aDrawPtr ) const
overridevirtual

Get the kinematic model of this mover if available. If aMoverPtr is null, "this" has been initialized (i.e., GetPlatform(), etc. will work); however, if aMoverPtr is non-null, "this" has not been initialized, so that any data needed from the simulation or scenario should be retrieved using aMoverPtr instead. In either case, the kinematic model needs to be extracted without disturbing the state of the platform to which either of "this" or aMoverPtr is attached.

Parameters
aSimTimeThe current simulation time.
aPlatformTypeIdThe platform type id that is being propagated kinematically.
aLocationWCSThe location of the platform at aSimTime.
aVelocityWCSThe velocity of the platform at aSimTime.
aMoverPtrIf non-null, a valid mover from which "this" should be initialized.
aDrawPtrA WsfDraw object that can be used for custom visualization.
Returns
The kinematic model pointer if available, otherwise nullptr.

Reimplemented from WsfMover.

References WsfSimulation::GetDateTime(), WsfPlatformPart::GetPlatform(), GetPropagator(), WsfPlatformPart::GetSimulation(), WsfDateTime::GetStartDateAndTime(), and WsfMover::WsfMover().

◆ GetAttitudeController()

WsfAttitudeController & WsfSpaceMoverBase::GetAttitudeController ( )
inline

Return a reference to the attitude controller associated with this space mover.

Referenced by WsfOrbitalAttitudeChangeEvent::ExecuteEvent(), and WsfOrbitalAttitudeChangeEvent::Initialize().

◆ GetAvailableDeltaV()

double WsfSpaceMoverBase::GetAvailableDeltaV ( ) const

Referenced by operator=().

◆ GetCentralBody()

const ut::CentralBody & WsfSpaceMoverBase::GetCentralBody ( ) const

◆ GetCentralPoint()

const ut::CentralPoint & WsfSpaceMoverBase::GetCentralPoint ( ) const

◆ GetComponentRoles()

const int * WsfSpaceMoverBase::GetComponentRoles ( ) const
overridevirtual

Returns a zero-terminated array of component roles. Note that the array should be in decreasing order of specificity and should generally the inheritance hierarchy. The first entry should be the components 'primary' role. For example a sensor would do the following:

return roles;
@ cWSF_COMPONENT_SENSOR
A 'sensor' component (WsfSensor).
Definition WsfComponentRoles.hpp:105
@ cWSF_COMPONENT_PLATFORM_PART
The component derives from WsfPlatformPart.
Definition WsfComponentRoles.hpp:98
@ cWSF_COMPONENT_ARTICULATED_PART
The component derives from WsfArticulatedPart.
Definition WsfComponentRoles.hpp:99

Reimplemented from WsfMover.

References cWSF_COMPONENT_MOVER, cWSF_COMPONENT_NULL, cWSF_COMPONENT_PLATFORM_PART, and cWSF_COMPONENT_SPACE_MOVER.

◆ GetCurrentMissionEvent()

const WsfOrbitalEvent * WsfSpaceMoverBase::GetCurrentMissionEvent ( ) const

Return the current maneuver, if any, being performed by this mover.

References WsfOrbitalEvent::GetCurrentMissionEvent().

Referenced by GetFutureLocationWCS(), and Maneuver().

◆ GetCurrentTime()

const UtCalendar & WsfSpaceMoverBase::GetCurrentTime ( ) const
inline

Get the current propagation time.

Referenced by Initialize2(), and WsfSpaceMoverBase::SpaceModel::SpaceModel().

◆ GetDescriptor()

const std::string & WsfSpaceMoverBase::GetDescriptor ( ) const
inline

Return the descriptor associated with this mover.

◆ GetDesignator()

const std::string & WsfSpaceMoverBase::GetDesignator ( ) const
inline

Return the designator associated with this mover.

◆ GetDistanceToHorizon()

double WsfSpaceMoverBase::GetDistanceToHorizon ( ) const

Return distance in meters from the mover to the central body's horizon. If the mover's position is inside the mean radius of the central body, this will return -1.

Returns
Distance from the mover to the horizon in meters; or -1 if the mover is inside the central body.

References GetCentralBody(), GetCentralPoint(), and GetOrbitalState().

◆ GetElementOutputUpdateInterval()

double WsfSpaceMoverBase::GetElementOutputUpdateInterval ( ) const
inline

Get the interval between entries in an event pipe of this mover's elements.

◆ GetFutureLocationWCS()

bool WsfSpaceMoverBase::GetFutureLocationWCS ( double aSimTime,
double aLocationWCS[3] )
finalvirtual

◆ GetIncidenceAngle()

double WsfSpaceMoverBase::GetIncidenceAngle ( const UtVec3d & aLocationWCS) const

Return the incidence angle for the given WCS location. This returns the angle in radians between the local vertical direction at aLocationWCS and the line connecting this space mover and the given aLocationWCS.

Parameters
aLocationWCSThe WCS location of the target point.
Returns
The incidence angle in radians.

References GetOrbitalState().

Referenced by GetTargetElevationAngle().

◆ GetInitialHeading()

double WsfSpaceMoverBase::GetInitialHeading ( ) const

◆ GetInitialOrbitalState()

const ut::OrbitalState & WsfSpaceMoverBase::GetInitialOrbitalState ( ) const

◆ GetInitialPositionECI()

UtVec3d WsfSpaceMoverBase::GetInitialPositionECI ( ) const

A convenience accessor to determine a WsfSpaceMoverBase's initial position. Extended to WsfSpaceMoverScriptClass for exposure to the user.

Returns
Initial Position (Reference Frame: Earth Centered Inertial (ECI) / Geocentric Celestial Reference Frame (GCRF))

References GetInitialOrbitalState().

Referenced by operator=().

◆ GetInitialPositionLLA()

WsfGeoPoint WsfSpaceMoverBase::GetInitialPositionLLA ( ) const

A convenience accessor which calculates a WsfSpaceMoverBase's initial position from its orbital elements. Extended to WsfSpaceMoverScriptClass for exposure to the user.

Returns
Initial Position (Reference Frame: Latitude, Longitude, Altitude))

References GetCentralBody(), and GetInitialOrbitalState().

Referenced by operator=().

◆ GetInitialPositionWCS()

UtVec3d WsfSpaceMoverBase::GetInitialPositionWCS ( ) const

A convenience accessor to determine a WsfSpaceMoverBase's initial position. Extended to WsfSpaceMoverScriptClass for exposure to the user.

Returns
Initial Position (Reference Frame: World Coordinate System (WCS) / Earth-Centered, Earth-Fixed (ECEF))

References GetInitialOrbitalState().

Referenced by operator=().

◆ GetInitialVelocityECI()

UtVec3d WsfSpaceMoverBase::GetInitialVelocityECI ( ) const

A convenience accessor to determine a WsfSpaceMoverBase's initial velocity. Extended to WsfSpaceMoverScriptClass for exposure to the user.

Returns
Initial Velocity (Reference Frame: Earth Centered Inertial (ECI) / Geocentric Celestial Reference Frame (GCRF))

References GetInitialOrbitalState().

Referenced by operator=().

◆ GetInitialVelocityWCS()

UtVec3d WsfSpaceMoverBase::GetInitialVelocityWCS ( ) const

A convenience accessor to determine a WsfSpaceMoverBase's initial velocity. Extended to WsfSpaceMoverScriptClass for exposure to the user.

Returns
Initial Velocity (Reference Frame: World Coordinate System (WCS) / Earth-Centered, Earth-Fixed (ECEF))

References GetInitialOrbitalState().

Referenced by operator=().

◆ GetLookAngleTo()

double WsfSpaceMoverBase::GetLookAngleTo ( const UtVec3d & aLocationWCS) const

Return the look angle to the given WCS location. This returns the angle in radians between the nadir direction and the line connecting this space mover and the given aLocationWCS.

Parameters
aLocationWCSThe WCS location of the target point.
Returns
The look angle from this space mover to the target point, in radians.

References GetOrbitalState().

◆ GetLookAngleToHorizon()

double WsfSpaceMoverBase::GetLookAngleToHorizon ( ) const

Return look angle in radians to the central body's horizon. If the mover's position is inside the mean radius of the central body, this will return -2 pi.

Returns
Look angle to the horizon in radians; or -2 pi if the mover is inside the central body.

References GetCentralBody(), GetCentralPoint(), and GetOrbitalState().

◆ GetManeuverDuration()

double WsfSpaceMoverBase::GetManeuverDuration ( const UtCalendar & aEpoch,
const WsfOrbitalManeuver & aManeuver,
double aDeltaV ) const

Referenced by operator=().

◆ GetMissionEvents()

const WsfOrbitalMissionSequence & WsfSpaceMoverBase::GetMissionEvents ( ) const

Return the current mission sequence.

In the case that no mission sequence is defined on this mover, this method will return an empty, but valid, object.

Referenced by VerifyMission().

◆ GetOrbitalManeuvering()

const WsfOrbitalManeuvering & WsfSpaceMoverBase::GetOrbitalManeuvering ( ) const

Return the maneuvering model for this space mover.

Referenced by WsfIntegratingPropagator::SetSpaceMover(), and VerifyMission().

◆ GetOrbitalState()

const ut::OrbitalState & WsfSpaceMoverBase::GetOrbitalState ( ) const

◆ GetOrbitColor()

ut::optional< UtColor > WsfSpaceMoverBase::GetOrbitColor ( ) const
inline

◆ GetOrbitColorValue()

UtColor WsfSpaceMoverBase::GetOrbitColorValue ( ) const
inline

◆ GetPropagator() [1/2]

UtOrbitalPropagatorBase & WsfSpaceMoverBase::GetPropagator ( )
inline

Return a reference to the orbital propagator associated with this space mover (non-const version).

◆ GetPropagator() [2/2]

◆ GetRequiredDeltaV()

double WsfSpaceMoverBase::GetRequiredDeltaV ( double aDuration) const

Referenced by operator=().

◆ GetRequiredDuration()

double WsfSpaceMoverBase::GetRequiredDuration ( double aDeltaV) const

Referenced by operator=().

◆ GetScriptClassName()

const char * WsfSpaceMoverBase::GetScriptClassName ( ) const
override

◆ GetScriptContext()

WsfScriptContext & WsfSpaceMoverBase::GetScriptContext ( )
inline

Return a reference to the script context.

Referenced by WsfOrbitalScriptEvent::Initialize(), Initialize(), and WsfSpaceMoverBase().

◆ GetSimTimeOfEpoch()

double WsfSpaceMoverBase::GetSimTimeOfEpoch ( ) const
inline

Return the relative time since the propagator's epoch time.

Note
This is not necessarily the same as the current simulation time.

◆ GetSpatialDomain()

WsfSpatialDomain WsfSpaceMoverBase::GetSpatialDomain ( ) const
inlineoverridevirtual

Return the spatial domain in which the mover is operating.

The spatial domain is the domain in which the mover is operating (land, sea, space, etc.).

Returns
The spatial domain in which the platform is operating. WSF_SPATIAL_DOMAIN_LAND is returned if this method is not overridden by a derived class.

Reimplemented from WsfMover.

References WSF_SPATIAL_DOMAIN_SPACE.

◆ GetSquintAngleTo()

double WsfSpaceMoverBase::GetSquintAngleTo ( const UtVec3d & aLocationWCS) const

Return the squint angle to the given WCS location. This returns the angle between this mover's WCS velocity vector projected into the local horizontal plane, and the WCS displacement vector from this mover to the given aLocationWCS projected into the local horizontal plane.

Parameters
aLocationWCSThe WCS location of the target point.
Returns
The squint angle to the target point, in radians.

References GetOrbitalState().

◆ GetTargetElevationAngle()

double WsfSpaceMoverBase::GetTargetElevationAngle ( const UtVec3d & aLocationWCS) const

Return the target elevation angle for the given WCS location. This returns the angle in radians between the local horizontal direction at aLocationWCS and the line connecthing this space mover and the given aLocationWCS.

Parameters
aLocationWCSThe WCS location of the target point.
Returns
The target elevation angle in radians.

References GetIncidenceAngle().

◆ Initialize()

bool WsfSpaceMoverBase::Initialize ( double aSimTime)
overridevirtual

Initialize the kinematic state of the associated platform. Fix the initial location, orientation, speed and acceleration of the attached platform to what it should be at the beginning of its existence.

Parameters
aSimTimeThe current simulation time.
Returns
True if successful.

Reimplemented from WsfMover.

References GetCentralPoint(), WsfDateTime::GetCurrentTime(), WsfSimulation::GetDateTime(), GetInitialOrbitalState(), WsfObject::GetName(), WsfPlatformPart::GetPlatform(), GetPropagator(), GetScriptContext(), WsfPlatformPart::GetSimulation(), WsfDateTime::GetStartDateAndTime(), WsfMover::Initialize(), ok, wsf::space::OrbitalPropagator::SetSpaceMover(), and UpdatePropagation().

Referenced by WsfNORAD_SpaceMover::Initialize(), WsfSpaceMover::Initialize(), and Initialize2().

◆ Initialize2()

bool WsfSpaceMoverBase::Initialize2 ( double aSimTime)
overridevirtual

Perform phase 2 initialization of the part. This is invoked by WsfPlatform::Initialize() during phase 2 initialization of the platform. During phase 2, platform components may assume that the platform location has been defined, initial tracks have been loaded and that all components have completed phase 1 initialization.

Parameters
aSimTimeThe current simulation time.
Returns
'true' if successful or 'false' if some sort of error occurred.

Reimplemented from WsfMover.

References GetCurrentTime(), WsfSimulation::GetDateTime(), GetInitialOrbitalState(), WsfObject::GetName(), WsfPlatformPart::GetPlatform(), GetPropagator(), WsfPlatformPart::GetSimulation(), WsfDateTime::GetStartDateAndTime(), Initialize(), ok, Update(), and VerifyMission().

Referenced by WsfIntegratingSpaceMover::Initialize2().

◆ InitializeOrbitalManeuvering()

bool WsfSpaceMoverBase::InitializeOrbitalManeuvering ( const UtCalendar & aEpoch)

Initialize just the orbital maneuvering model.

References WsfOrbitalManeuvering::Initialize().

◆ IsExtrapolating()

bool WsfSpaceMoverBase::IsExtrapolating ( ) const
inlineoverridevirtual

Return whether the mover is "extrapolating". 'Extrapolating' has a slightly different meaning depending on the mover, but it fundamentally means it is moving without any form of external guidance. In the case of a simple waypoint- following mover this means it has reached its final waypoint and has either stopped there or is continuing on at a specified direction, speed, and altitude. For movers that do not follow waypoints it is a little murkier, but it typically means that the motion is occuring without any propulsion. In this latter case it basically means that with a little knowledge an external observer could take the position at any time and use Newton's Laws to estimate future positions.

Reimplemented from WsfMover.

◆ IsTLEInputAllowed()

bool WsfSpaceMoverBase::IsTLEInputAllowed ( ) const
inlinenoexcept

◆ Maneuver()

bool WsfSpaceMoverBase::Maneuver ( const UtCalendar & aEpoch,
const UtVec3d & aCommandedDeltaV,
UtVec3d & aActualDeltaV )

◆ operator=()

◆ OrbitColorSet()

bool WsfSpaceMoverBase::OrbitColorSet ( ) const
inline

◆ PerformStagingOperation()

bool WsfSpaceMoverBase::PerformStagingOperation ( )

◆ PreInitialize()

bool WsfSpaceMoverBase::PreInitialize ( double aSimTime)
overridevirtual

Perform pre-initializion function. This is called by WsfPlatform::Initialize prior to actually initializing the components on a platform (i.e.: calling Initialize and Initialize2 for each component). The primary reason for this method is to allow components to add other components that will then be subsequently initialized. The component may examine the component list and add components, but it must not assume ANYTHING about the actual state of the component.

Parameters
aSimTimeThe current simulation time.
Returns
true if successful or false if unsuccessful (bad input data, etc.)

Reimplemented from WsfComponent.

References GetCentralPoint(), WsfDateTime::GetCurrentTime(), WsfSimulation::GetDateTime(), GetInitialOrbitalState(), WsfPlatform::GetMover(), WsfObject::GetName(), WsfPlatformPart::GetPlatform(), and WsfPlatformPart::GetSimulation().

◆ ProcessInput()

bool WsfSpaceMoverBase::ProcessInput ( UtInput & aInput)
overridevirtual

Process input from a generic source.

Examine the current input command. If it is NOT one of the commands recognized by this class then it simply returns 'false'. If it is one of the commands recognized by this class then it processes the command and returns 'true'.

Parameters
aInputa reference to a UtInput object.
Returns
'true' if the command was one recognized by the class or 'false' if not.
Exceptions
UtInput::ExceptionBase(or an object derived from it) if the command was recognized but contains some sort of error.
Note
If a derived class does not recognize the command (i.e.: the return value is false) then it should call the base class ProcessInput method. This chain should continue until either the command is recognized or the top-level base class is encountered.

Reimplemented from WsfMover.

References WsfObjectTypeList< T >::Find(), WsfAttitudeControllerTypes::Get(), WsfOrbitalManeuveringTypes::Get(), WsfPlatformPart::GetScenario(), and WsfMover::ProcessInput().

Referenced by WsfNORAD_SpaceMover::ProcessInput(), and WsfSpaceMover::ProcessInput().

◆ QueryInterface()

void * WsfSpaceMoverBase::QueryInterface ( int aRole)
overridevirtual

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);

Reimplemented from WsfMover.

References cWSF_COMPONENT_SPACE_MOVER, and WsfMover::QueryInterface().

◆ ScheduleMission()

void WsfSpaceMoverBase::ScheduleMission ( const UtCalendar & aEpoch,
std::unique_ptr< WsfOrbitalMissionSequence > aMissionEventsPtr )

Set the MissionEvent sequence using a simulation event that executes at the current simulation time (necessary because a scripted event can schedule a new sequence, thus potentially deleting itself). Then, initialize and schedule the first event in the new sequence.

Parameters
aEpochThe current epoch, to be used as the basis for scheduling mission.
aMissionEventsPtrThe new mission events sequence to be executed.

◆ SetInitialOrbitalState()

void WsfSpaceMoverBase::SetInitialOrbitalState ( const ut::OrbitalState & aState)
inline

A pass-through method to set the initial orbital state.

Referenced by wsf::space::script::UT_DEFINE_SCRIPT_METHOD().

◆ SetInitialPoint()

bool WsfSpaceMoverBase::SetInitialPoint ( double aLat,
double aLon,
double aAlt,
double aSpeed,
double aHeading )
virtual

Reimplemented in WsfNORAD_SpaceMover, and WsfSpaceMover.

Referenced by operator=().

◆ SetOrbitColor() [1/2]

void WsfSpaceMoverBase::SetOrbitColor ( const std::string & aOrbitColor)
inline

References SetOrbitColor().

Referenced by SetOrbitColor(), and UpdateColor().

◆ SetOrbitColor() [2/2]

void WsfSpaceMoverBase::SetOrbitColor ( const UtColor & aOrbitColor)

◆ SetTargetOrientationECI()

void WsfSpaceMoverBase::SetTargetOrientationECI ( double aPsi,
double aTheta,
double aPhi )

Set the mover's target ECI orientation.

References WsfSimulation::GetSimTime(), WsfPlatformPart::GetSimulation(), simTime, and Update().

◆ SetTLEInputAllowed()

void WsfSpaceMoverBase::SetTLEInputAllowed ( bool aTLE_InputAllowed)
inlinenoexcept

◆ Update()

void WsfSpaceMoverBase::Update ( double aSimTime)
overridevirtual

Update the kinematic state of the associated platform. Update the location, orientation, speed and acceleration of the attached platform to what it should be at the supplied time.

Parameters
aSimTimeThe current simulation time.
Note
The derived class MUST update the protected variable mLastUpdateTime to be the current simulation time.

Reimplemented from WsfMover.

References WsfSimulation::GetDateTime(), WsfPlatformPart::GetPlatform(), WsfPlatformPart::GetSimulation(), WsfDateTime::GetStartDateAndTime(), WsfMover::mLastUpdateTime, WsfMover::mUpdateTimeTolerance, and UpdatePropagation().

Referenced by WsfSpaceMoverBase::SpaceModel::GetLocationXYZ(), WsfSpaceMoverBase::SpaceModel::GetVelocityXYZ(), Initialize2(), and SetTargetOrientationECI().

◆ UpdateColor()

void WsfSpaceMoverBase::UpdateColor ( double aSimTime,
const UtColor & aColor )

◆ UpdatePropagation()

void WsfSpaceMoverBase::UpdatePropagation ( const UtCalendar & aEpoch)

Update the propagation and the associated platform. This method is usually only called from the Update method; however, in some cases it is called to update the state of the platform instantaneously, especially during execution of an impulsive maneuver.

Parameters
aEpochThe time to which the propagation and platform state will be updated.

References WsfPlatformPart::GetPlatform().

Referenced by Initialize(), WsfIntegratingSpaceMover::Initialize2(), and Update().

◆ VerifyMission() [1/2]

bool WsfSpaceMoverBase::VerifyMission ( const UtCalendar & aEpoch) const

Verify the initial sequence of MissionEvents in this object. The sequence of MissionEvents is verified outside of the simulation as a check to make sure that constraints are being met. If the sequence is not verified, error messages are printed and the simulation will not run until the errors are fixed. In the case of some orbital events that involve checks on other platforms (WsfIterceptManeuver, WsfRendezvousManeuver, WsfOrbitalScriptEvent, etc.) the verification will terminate with the check of the non-verifiable event, and the sequence may subsequently fail to completely execute during runtime.

Parameters
aEpochThe start epoch at which the MissionEvent sequence is to be verified.

References GetMissionEvents(), and VerifyMission().

◆ VerifyMission() [2/2]

bool WsfSpaceMoverBase::VerifyMission ( const UtCalendar & aEpoch,
const WsfOrbitalMissionSequence & aSequence,
wsf::space::verify::PreOperation aPreVerifyOp = wsf::space::verify::PreOperation{},
wsf::space::verify::PostOperation aPostVerifyOp = wsf::space::verify::PostOperation{} ) const

Verify a given sequence of MissionEvents. The sequence of MissionEvents outside of the simulation as a check to make sure that constraints are being met. If the sequence is not verified, error messages are printed and the simulation will not run until the errors are fixed. In the case of some orbital events that involve checks on other platforms (WsfIterceptManeuver, WsfRendezvousManeuver, WsfOrbitalScriptEvent, etc.) the verification will terminate with the check of the non-verifiable event, and the sequence may subsequently fail to completely execute during runtime.

Parameters
aEpochThe start epoch at which the MissionEvent sequence is to be verified.
aSequenceThe mission sequence to be verified.
aPreVerifyOpThe operation to perform before each event is verified.
aPostVerifyOpThe operation to perform after each event is verified.

References WsfObject::GetName(), GetOrbitalManeuvering(), WsfPlatformPart::GetPlatform(), GetPropagator(), WsfOrbitalMissionSequence::GetSequence(), wsf::space::OrbitalMissionVerificationContext::Initialize(), and wsf::space::OrbitalMissionVerificationContext::VerifyMission().

Referenced by Initialize2(), and VerifyMission().


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