|
WSF
|
#include <WsfPhysicalScanSensorScheduler.hpp>


Classes | |
| struct | SensorTarget |
| struct | SearchModeData |
Public Member Functions | |
| WsfPhysicalScanSensorScheduler ()=default | |
| WsfPhysicalScanSensorScheduler (std::string aTypeName, bool aRandomizeInitialHeading, SearchListSortFn aSearchListSort) | |
| ~WsfPhysicalScanSensorScheduler () override=default | |
| WsfSensorScheduler * | Clone () const override |
| bool | ProcessInput (UtInput &aInput) override |
| bool | Initialize (double aSimTime, WsfSensor *aSensorPtr, WsfSensorTracker *aTrackerPtr) override |
| void | ModeDeselected (double aSimTime, WsfStringId aModeNameId) override |
| void | ModeSelected (double aSimTime, WsfStringId aModeNameId) override |
| void | PlatformAdded (double aSimTime, WsfPlatform *aPlatformPtr) override |
| void | RemoveTarget (double aSimTime, size_t aTargetIndex) override |
| bool | SelectTarget (double aSimTime, double &aNextSimTime, size_t &aTargetIndex, WsfTrackId &aRequestId, WsfSensor::Settings &aSettings) override |
| void | TurnOff (double aSimTime) override |
| void | TurnOn (double aSimTime) override |
| double | GetInitialHeading () const |
| Public Member Functions inherited from WsfSensorScheduler | |
| WsfSensorScheduler () | |
| virtual | ~WsfSensorScheduler ()=default |
| bool | DebugEnabled () const |
| Returns 'true' if debugging is enabled for the scheduler. | |
| void | SetDebugEnabled (bool aDebug) |
| virtual void | FrameTimeChanged (double aSimTime, WsfStringId aModeNameId) |
| virtual int | GetActiveRequestCount (WsfStringId aModeNameId) const |
| virtual int | GetMaximumRequestCount (WsfStringId aModeNameId) const |
| virtual bool | HaveRequestFor (const WsfTrackId &aRequestId) const |
| virtual void | PlatformDeleted (WsfPlatform *aPlatformPtr) |
| virtual const WsfTrack & | GetTrackForRequest (const WsfTrackId &aRequestId) const |
| virtual bool | StartTracking (double aSimTime, const WsfTrack &aTrack, WsfStringId aModeNameId) |
| virtual bool | StopTracking (double aSimTime, const WsfTrackId &aTrackId) |
| virtual void | TrackerModeChange (double aSimTime, const WsfTrackId &aRequestId, size_t aTargetIndex, WsfPlatform *aTargetPtr, const WsfTrack *aTrackPtr, WsfStringId aModeNameId) |
| WsfSimulation * | GetSimulation () const |
Static Public Member Functions | |
| static std::unique_ptr< WsfSensorScheduler > | ObjectFactory (const std::string &aTypeName) |
Protected Member Functions | |
| WsfPhysicalScanSensorScheduler (const WsfPhysicalScanSensorScheduler &aSrc) | |
| WsfPhysicalScanSensorScheduler & | operator= (const WsfPhysicalScanSensorScheduler &)=delete |
| void | CheckSearchModeAvailability () |
| Check if the current mode selections provide for the ability to process search chances. | |
| void | ResetSearchList () |
| Protected Member Functions inherited from WsfSensorScheduler | |
| WsfSensorScheduler (const WsfSensorScheduler &aSrc) | |
| WsfSensorScheduler & | operator= (const WsfSensorScheduler &aSrc)=delete |
| const SearchList & | GetSearchList () const |
Protected Attributes | |
| std::vector< WsfSensorMode * > | mModeList |
| The pointers to the sensor modes, indexed by mode index. | |
| size_t | mLastExplicitModeIndex {0} |
| The last mode explicitly selected (i.e.: via WsfSensor::SelectMode). | |
| std::vector< size_t > | mSearchModeIndex {0} |
| bool | mSearchAllowed {false} |
| 'true' if search chances can be processed. | |
| std::queue< SensorTarget > | mSensorTargetQueue |
| A queue of platform indices representing targets in the sensor's current FOV angle. | |
| double | mSensorUpdateInterval {0.0} |
| The value of UpdateInterval defined by user at run-time in the input files. | |
| std::map< size_t, SearchModeData > | mSearchModeDataMap |
| double | mLastUpdate {-1.0} |
| Protected Attributes inherited from WsfSensorScheduler | |
| WsfSensor * | mSensorPtr |
| WsfSensorTracker * | mTrackerPtr |
| SearchList | mSearchList |
Additional Inherited Members | |
| Protected Types inherited from WsfSensorScheduler | |
| using | SearchList = std::vector<size_t> |
| using | SearchListIndex = SearchList::size_type |
|
default |
References WsfPhysicalScanSensorScheduler().
Referenced by Clone(), operator=(), WsfPhysicalScanSensorScheduler(), and WsfPhysicalScanSensorScheduler().
| WsfPhysicalScanSensorScheduler::WsfPhysicalScanSensorScheduler | ( | std::string | aTypeName, |
| bool | aRandomizeInitialHeading, | ||
| SearchListSortFn | aSearchListSort ) |
References WsfSensorScheduler::WsfSensorScheduler().
|
overridedefault |
|
protected |
References WsfPhysicalScanSensorScheduler(), and WsfSensorScheduler::WsfSensorScheduler().
|
protected |
Check if the current mode selections provide for the ability to process search chances.
References WsfSensorMode::CanSearchWhileTrack(), WsfSensorMode::DisablesSearch(), WsfMode::IsSelected(), mModeList, mSearchAllowed, and mSearchModeIndex.
Referenced by ModeDeselected(), ModeSelected(), operator=(), and TurnOn().
|
overridevirtual |
Reimplemented from WsfSensorScheduler.
References WsfPhysicalScanSensorScheduler(), and WsfSensorScheduler::WsfSensorScheduler().
Referenced by ~WsfPhysicalScanSensorScheduler().
|
inline |
Returns the initial heading (in radians) of the sensor, either as specified via ProcessInput, or otherwise a random value chosen during Initialize. Do not call this before the scheduler is initialized!
|
overridevirtual |
Initialize the scheduler.
| aSimTime | The current simulation time. |
| aSensorPtr | The sensor with which the scheduler is associated. |
| aTrackerPtr | The tracker that is associated with the sensor. This can be zero if there is no tracker. |
Reimplemented from WsfSensorScheduler.
References WsfSensorScheduler::DebugEnabled(), WsfModeList::GetDerivedModeList(), WsfSensorMode::GetFrameTime(), WsfSensor::GetModeList(), WsfNamed::GetName(), WsfSimulation::GetRandom(), WsfSensorScheduler::GetSimulation(), WsfSensor::GetUpdateInterval(), WsfSensorScheduler::Initialize(), mLastExplicitModeIndex, mModeList, mSearchModeDataMap, WsfSensorScheduler::mSensorPtr, mSensorUpdateInterval, and ok.
Referenced by ~WsfPhysicalScanSensorScheduler().
|
overridevirtual |
A mode has been explicitly deselected. This is called from WsfSensor::DeselectMode to indicate that a mode has been deselected.
| aSimTime | The current simulation time. |
| aModeNameId | The name (string ID) of the mode that has been deselected. |
Reimplemented from WsfSensorScheduler.
References CheckSearchModeAvailability(), mLastExplicitModeIndex, mModeList, and WsfSensorScheduler::mSensorPtr.
Referenced by ~WsfPhysicalScanSensorScheduler().
|
overridevirtual |
A mode has been explicitly selected. This is called from WsfSensor::SelectMode to indicate that a mode has been selected.
| aSimTime | The current simulation time. |
| aModeNameId | The name (string ID) of the mode that has been selected. |
Reimplemented from WsfSensorScheduler.
References CheckSearchModeAvailability(), mLastExplicitModeIndex, and WsfSensorScheduler::mSensorPtr.
Referenced by ~WsfPhysicalScanSensorScheduler().
|
static |
Factory method for WsfSensorSchedulerTypes to determine if a scheduler represented by this class is being requested.
Referenced by WsfSensorTypes::WsfSensorTypes(), and ~WsfPhysicalScanSensorScheduler().
|
protecteddelete |
References CheckSearchModeAvailability(), ResetSearchList(), and WsfPhysicalScanSensorScheduler().
|
overridevirtual |
A platform has been added to the simulation.
| aSimTime | The current simulation time. |
| aPlatformPtr | A pointer to the platform that was added. |
Reimplemented from WsfSensorScheduler.
References WsfPlatform::GetIndex(), and WsfSensorScheduler::mSearchList.
Referenced by ~WsfPhysicalScanSensorScheduler().
|
overridevirtual |
Reimplemented from WsfSensorScheduler.
References WsfSensorScheduler::ProcessInput().
Referenced by ~WsfPhysicalScanSensorScheduler().
|
overridevirtual |
Indicate that the specified target should be removed from further consideration. This is called from the scheduler to indicate that the target should be removed from any scheduling list.
| aSimTime | The current simulation time. |
| aTargetIndex | The object ID of the target to be removed. |
Reimplemented from WsfSensorScheduler.
References WsfSensorScheduler::mSearchList.
Referenced by ~WsfPhysicalScanSensorScheduler().
|
protected |
References WsfSensorScheduler::mSearchList.
Referenced by operator=(), TurnOff(), and TurnOn().
|
overridevirtual |
Select a target for a detection attempt.
| aSimTime | [input] The current simulation time. |
| aNextSimTime | [output] The simulation time when the scheduler should next be called. |
| aTargetIndex | [output] The object ID of the target to be detected (typically a platform index or some other unique ID). This will not be valid if the return value from the method is false. |
| aRequestId | [output] The request ID (original track ID from StartTracking) associated with the target. aRequest.IsNull() will be true if the target is not associated with a track request. This will not be valid if the return value from the method is false. |
| aSettings | [updated] The sensor settings to be used for the detection attempt. This will not be valid if the return value from the method is false. |
Reimplemented from WsfSensorScheduler.
References WsfSensorScheduler::DebugEnabled(), WsfObject::GetName(), WsfSimulation::GetPlatformByIndex(), WsfSensorScheduler::GetSimulation(), mLastUpdate, WsfSensor::Settings::mModeIndex, mModeList, mSearchAllowed, WsfSensorScheduler::mSearchList, mSearchModeDataMap, mSearchModeIndex, WsfSensorScheduler::mSensorPtr, mSensorTargetQueue, mSensorUpdateInterval, WsfTrackId::Null(), and WsfPlatform::Update().
Referenced by ~WsfPhysicalScanSensorScheduler().
|
overridevirtual |
The sensor is being turned off.
| aSimTime | The current simulation time. |
Reimplemented from WsfSensorScheduler.
References WsfSensorScheduler::DebugEnabled(), WsfSensorScheduler::mSensorPtr, and ResetSearchList().
Referenced by ~WsfPhysicalScanSensorScheduler().
|
overridevirtual |
The sensor is being turned on.
| aSimTime | The current simulation time. |
Reimplemented from WsfSensorScheduler.
References CheckSearchModeAvailability(), WsfSensorScheduler::DebugEnabled(), WsfSimulation::GetPlatformCount(), WsfSimulation::GetPlatformEntry(), WsfSensorScheduler::GetSimulation(), WsfSensorScheduler::mSensorPtr, and ResetSearchList().
Referenced by ~WsfPhysicalScanSensorScheduler().
|
protected |
The last mode explicitly selected (i.e.: via WsfSensor::SelectMode).
Referenced by Initialize(), ModeDeselected(), and ModeSelected().
|
protected |
The value of Sim Time during the last Update interval. This is used by SelectTarget to know when to search through the list of platforms and create a list of targets to return.
Referenced by SelectTarget().
|
protected |
The pointers to the sensor modes, indexed by mode index.
Referenced by CheckSearchModeAvailability(), Initialize(), ModeDeselected(), and SelectTarget().
|
protected |
'true' if search chances can be processed.
Referenced by CheckSearchModeAvailability(), and SelectTarget().
|
protected |
Referenced by Initialize(), and SelectTarget().
|
protected |
The mode index to be used for searching. If greater than the mode count then searching is disabled.
Referenced by CheckSearchModeAvailability(), and SelectTarget().
|
protected |
A queue of platform indices representing targets in the sensor's current FOV angle.
Referenced by SelectTarget().
|
protected |
The value of UpdateInterval defined by user at run-time in the input files.
Referenced by Initialize(), and SelectTarget().