CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Protected Member Functions | Private Attributes
CmsShowTaskExecutor Class Reference

#include <Fireworks/Core/interface/CmsShowTaskExecutor.h>

Inheritance diagram for CmsShowTaskExecutor:
CmsShowTaskExecutorBase

Public Types

typedef std::function< void()> TaskFunctor
 

Public Member Functions

void addTask (const TaskFunctor &iTask)
 
 CmsShowTaskExecutor ()
 
 CmsShowTaskExecutor (const CmsShowTaskExecutor &)=delete
 
const CmsShowTaskExecutoroperator= (const CmsShowTaskExecutor &)=delete
 
void startDoingTasks () override
 
 ~CmsShowTaskExecutor () override
 
- Public Member Functions inherited from CmsShowTaskExecutorBase
 CmsShowTaskExecutorBase ()
 
 CmsShowTaskExecutorBase (const CmsShowTaskExecutorBase &)=delete
 
void doNextTask ()
 
const CmsShowTaskExecutorBaseoperator= (const CmsShowTaskExecutorBase &)=delete
 
void requestNextTask ()
 
virtual ~CmsShowTaskExecutorBase ()
 

Protected Member Functions

void doNextTaskImp () override
 
bool moreTasksAvailable () override
 

Private Attributes

std::deque< TaskFunctorm_tasks
 

Additional Inherited Members

- Public Attributes inherited from CmsShowTaskExecutorBase
sigc::signal< void()> tasksCompleted_
 

Detailed Description

Description: <one line="" class="" summary>="">

Usage: <usage>

Definition at line 30 of file CmsShowTaskExecutor.h.

Member Typedef Documentation

◆ TaskFunctor

typedef std::function<void()> CmsShowTaskExecutor::TaskFunctor

Definition at line 35 of file CmsShowTaskExecutor.h.

Constructor & Destructor Documentation

◆ CmsShowTaskExecutor() [1/2]

CmsShowTaskExecutor::CmsShowTaskExecutor ( )

Definition at line 29 of file CmsShowTaskExecutor.cc.

29 {}

◆ ~CmsShowTaskExecutor()

CmsShowTaskExecutor::~CmsShowTaskExecutor ( )
override

Definition at line 36 of file CmsShowTaskExecutor.cc.

36 {}

◆ CmsShowTaskExecutor() [2/2]

CmsShowTaskExecutor::CmsShowTaskExecutor ( const CmsShowTaskExecutor )
delete

Member Function Documentation

◆ addTask()

void CmsShowTaskExecutor::addTask ( const TaskFunctor iTask)

Definition at line 53 of file CmsShowTaskExecutor.cc.

References m_tasks.

Referenced by CmsShowMain::CmsShowMain(), FWFFLooper::loadDefaultGeometryFile(), and FWFFLooper::startingNewLoop().

53 { m_tasks.push_back(iTask); }
std::deque< TaskFunctor > m_tasks

◆ doNextTaskImp()

void CmsShowTaskExecutor::doNextTaskImp ( )
overrideprotectedvirtual

Implements CmsShowTaskExecutorBase.

Definition at line 61 of file CmsShowTaskExecutor.cc.

References f, and m_tasks.

61  {
62  TaskFunctor f = m_tasks.front();
63  m_tasks.pop_front();
64  f();
65 }
std::function< void()> TaskFunctor
std::deque< TaskFunctor > m_tasks
double f[11][100]

◆ moreTasksAvailable()

bool CmsShowTaskExecutor::moreTasksAvailable ( )
overrideprotectedvirtual

Implements CmsShowTaskExecutorBase.

Definition at line 67 of file CmsShowTaskExecutor.cc.

References m_tasks.

67 { return !m_tasks.empty(); }
std::deque< TaskFunctor > m_tasks

◆ operator=()

const CmsShowTaskExecutor& CmsShowTaskExecutor::operator= ( const CmsShowTaskExecutor )
delete

◆ startDoingTasks()

void CmsShowTaskExecutor::startDoingTasks ( )
overridevirtual

Implements CmsShowTaskExecutorBase.

Definition at line 55 of file CmsShowTaskExecutor.cc.

References m_tasks, and CmsShowTaskExecutorBase::requestNextTask().

Referenced by CmsShowMain::CmsShowMain(), and FWFFLooper::startingNewLoop().

55  {
56  if (!m_tasks.empty()) {
58  }
59 }
std::deque< TaskFunctor > m_tasks

Member Data Documentation

◆ m_tasks

std::deque<TaskFunctor> CmsShowTaskExecutor::m_tasks
private

Definition at line 56 of file CmsShowTaskExecutor.h.

Referenced by addTask(), doNextTaskImp(), moreTasksAvailable(), and startDoingTasks().