What’s New in the Pulse Physiology Engine 4.4.0
×

#include <PulseEngineThreadController.h>

Inherits Loggable.

Classes

class  Simulation
 

Public Member Functions

 PulseEngineThreadController (const std::string &logFilename)
 
virtual ~PulseEngineThreadController ()=default
 
bool Run (const std::vector< Simulation * > &PulseEngineThreads)
 
- Public Member Functions inherited from Loggable
 Loggable (Logger *logger=nullptr)
 
 Loggable (std::string const &logfile)
 
virtual ~Loggable ()
 
virtual Logger * GetLogger () const
 
virtual void SetLogger (Logger &logger)
 
virtual void Debug (std::string const &msg) const
 
virtual void Debug (std::stringstream &msg) const
 
virtual void Debug (std::ostream &msg) const
 
virtual void Info (std::string const &msg) const
 
virtual void Info (std::stringstream &msg) const
 
virtual void Info (const std::stringstream &msg) const
 
virtual void Info (std::ostream &msg) const
 
virtual void Warning (std::string const &msg) const
 
virtual void Warning (std::stringstream &msg) const
 
virtual void Warning (std::ostream &msg) const
 
virtual void Error (std::string const &msg) const
 
virtual void Error (std::stringstream &msg) const
 
virtual void Error (std::ostream &msg) const
 
virtual void Fatal (std::string const &msg) const
 
virtual void Fatal (std::stringstream &msg) const
 
virtual void Fatal (std::ostream &msg) const
 

Protected Member Functions

void ControllerLoop ()
 
Simulation * GetNextSimulation ()
 
void Complete (Simulation *)
 

Protected Attributes

size_t m_TotalSimulations =0
 
std::mutex m_Mutex
 
std::vector< Simulation * > m_Remaining
 
std::vector< std::thread > m_Threads
 
- Protected Attributes inherited from Loggable
bool myLogger
 
Logger * m_Logger
 

Constructor & Destructor Documentation

◆ PulseEngineThreadController()

PulseEngineThreadController::PulseEngineThreadController ( const std::string &  logFilename)
inline

◆ ~PulseEngineThreadController()

virtual PulseEngineThreadController::~PulseEngineThreadController ( )
virtualdefault

Member Function Documentation

◆ Complete()

void PulseEngineThreadController::Complete ( Simulation *  sim)
protected

◆ ControllerLoop()

void PulseEngineThreadController::ControllerLoop ( )
protected

◆ GetNextSimulation()

PulseEngineThreadController::Simulation * PulseEngineThreadController::GetNextSimulation ( )
protected

◆ Run()

bool PulseEngineThreadController::Run ( const std::vector< Simulation * > &  PulseEngineThreads)

Member Data Documentation

◆ m_Mutex

std::mutex PulseEngineThreadController::m_Mutex
protected

◆ m_Remaining

std::vector<Simulation*> PulseEngineThreadController::m_Remaining
protected

◆ m_Threads

std::vector<std::thread> PulseEngineThreadController::m_Threads
protected

◆ m_TotalSimulations

size_t PulseEngineThreadController::m_TotalSimulations =0
protected

Distributed under the Apache License, Version 2.0.

See accompanying NOTICE file for details.