# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NLMISC::CTaskManager Class Reference

CTaskManager is a class that manage a list of Task with one Thread. More...

#include <task_manager.h>

Inheritance diagram for NLMISC::CTaskManager

Inheritance graph
[legend]
Collaboration diagram for NLMISC::CTaskManager:

Collaboration graph
[legend]
List of all members.

Public Methods

 CTaskManager ()
 Constructor. More...

 ~CTaskManager ()
 Destructeur. More...

void run (void)
 Manage TaskQueue. More...

void addTask (IRunnable *)
 Add a task to TaskManager. More...

bool deleteTask (IRunnable *r)
 Delete a task, only if task is not running, return true if found and deleted. More...

void sleepTask (void)
 Sleep a Task. More...

uint taskListSize (void)
 Task list size. More...


Private Attributes

CSynchronized<std::list<IRunnable *> > _TaskQueue
IThread_Thread
volatile bool _ThreadRunning

Detailed Description

CTaskManager is a class that manage a list of Task with one Thread.

Author(s):
Alain Saffray , Nevrax France
Date:
2000

Definition at line 43 of file task_manager.h.


Constructor & Destructor Documentation

NLMISC::CTaskManager::CTaskManager ( )
 

Constructor.

Definition at line 35 of file task_manager.cpp.

NLMISC::CTaskManager::~CTaskManager ( )
 

Destructeur.

Definition at line 45 of file task_manager.cpp.


Member Function Documentation

void NLMISC::CTaskManager::addTask ( IRunnable * r )
 

Add a task to TaskManager.

Definition at line 84 of file task_manager.cpp.

bool NLMISC::CTaskManager::deleteTask ( IRunnable * r )
 

Delete a task, only if task is not running, return true if found and deleted.

Definition at line 91 of file task_manager.cpp.

void NLMISC::CTaskManager::run ( void ) [virtual]
 

Manage TaskQueue.

Reimplemented from NLMISC::IRunnable.

Definition at line 53 of file task_manager.cpp.

void NLMISC::CTaskManager::sleepTask ( void ) [inline]
 

Sleep a Task.

Definition at line 63 of file task_manager.h.

uint NLMISC::CTaskManager::taskListSize ( void )
 

Task list size.

Definition at line 106 of file task_manager.cpp.


Member Data Documentation

CSynchronized< std::list< IRunnable *> > NLMISC::CTaskManager::_TaskQueue [private]
 

Definition at line 70 of file task_manager.h.

IThread * NLMISC::CTaskManager::_Thread [private]
 

Definition at line 73 of file task_manager.h.

volatile bool NLMISC::CTaskManager::_ThreadRunning [private]
 

Definition at line 76 of file task_manager.h.


The documentation for this class was generated from the following files: