WSF
WsfMultiThreadManager Class Reference

A specialization class to handle multi-thread capabilities in the WSF core framework via thread pools. More...

#include <WsfMultiThreadManager.hpp>

Classes

class  PlatformElement
class  SensorElement
class  SimulationUpdateThread
 Implementation of worker thread for updating a platform. More...
struct  ThreadFactory

Public Member Functions

 WsfMultiThreadManager (unsigned int aNumberOfThreads, double aBreakUpdateTime, bool aDebugMultiThread, WsfSimulation *aSimulationPtr)
 Constructor.
virtual ~WsfMultiThreadManager ()
void Initialize ()
void Complete (double aSimTime)

Priority queue methods.

class SimulationUpdateThread
bool PlatformsQueued ()
bool PopNextPlatformElement (PlatformElement &aPlatformElement)
bool SensorsQueued ()
bool PopNextSensorElement (SensorElement &aSensorElement)

Main update methods.

void UpdatePlatforms (double aCurrentTime)
void UpdateSensors (double aCurrentTime)
bool BreakUpdate ()

Platform and Sensor methods

void AddPlatform (double aSimTime, WsfPlatform *aPlatformPtr)
void PlatformIntroduced (double aSimTime, WsfPlatform *aPlatformPtr)
void DeletePlatform (double aSimTime, WsfPlatform *aOldPlatformPtr)
void PlatformDeleted (double aSimTime, WsfPlatform *aOldPlatformPtr)
void TurnSensorOff (double aSimTime, WsfSensor *aSensorPtr)
void TurnSensorOn (double aSimTime, WsfSensor *aSensorPtr)

Detailed Description

A specialization class to handle multi-thread capabilities in the WSF core framework via thread pools.

Current implementation allows for threaded platform (i.e. mover) and sensor updates.

Constructor & Destructor Documentation

◆ WsfMultiThreadManager()

WsfMultiThreadManager::WsfMultiThreadManager ( unsigned int aNumberOfThreads,
double aBreakUpdateTime,
bool aDebugMultiThread,
WsfSimulation * aSimulationPtr )

◆ ~WsfMultiThreadManager()

WsfMultiThreadManager::~WsfMultiThreadManager ( )
virtual

Member Function Documentation

◆ AddPlatform()

void WsfMultiThreadManager::AddPlatform ( double aSimTime,
WsfPlatform * aPlatformPtr )

◆ BreakUpdate()

bool WsfMultiThreadManager::BreakUpdate ( )
inline

◆ Complete()

void WsfMultiThreadManager::Complete ( double aSimTime)

◆ DeletePlatform()

void WsfMultiThreadManager::DeletePlatform ( double aSimTime,
WsfPlatform * aOldPlatformPtr )

◆ Initialize()

void WsfMultiThreadManager::Initialize ( )

◆ PlatformDeleted()

void WsfMultiThreadManager::PlatformDeleted ( double aSimTime,
WsfPlatform * aOldPlatformPtr )
inline

◆ PlatformIntroduced()

void WsfMultiThreadManager::PlatformIntroduced ( double aSimTime,
WsfPlatform * aPlatformPtr )
inline

◆ PlatformsQueued()

bool WsfMultiThreadManager::PlatformsQueued ( )
inlineprotected

◆ PopNextPlatformElement()

bool WsfMultiThreadManager::PopNextPlatformElement ( PlatformElement & aPlatformElement)
protected

◆ PopNextSensorElement()

bool WsfMultiThreadManager::PopNextSensorElement ( SensorElement & aSensorElement)
protected

◆ SensorsQueued()

bool WsfMultiThreadManager::SensorsQueued ( )
inlineprotected

◆ TurnSensorOff()

void WsfMultiThreadManager::TurnSensorOff ( double aSimTime,
WsfSensor * aSensorPtr )

◆ TurnSensorOn()

void WsfMultiThreadManager::TurnSensorOn ( double aSimTime,
WsfSensor * aSensorPtr )

◆ UpdatePlatforms()

void WsfMultiThreadManager::UpdatePlatforms ( double aCurrentTime)

◆ UpdateSensors()

void WsfMultiThreadManager::UpdateSensors ( double aCurrentTime)

◆ SimulationUpdateThread

friend class SimulationUpdateThread
friend

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