diff options
author | neodarz <neodarz@neodarz.net> | 2018-08-11 20:21:34 +0200 |
---|---|---|
committer | neodarz <neodarz@neodarz.net> | 2018-08-11 20:21:34 +0200 |
commit | 0ea5fc66924303d1bf73ba283a383e2aadee02f2 (patch) | |
tree | 2568e71a7ccc44ec23b8bb3f0ff97fb6bf2ed709 /docs/doxygen/nel/a02216.html | |
download | nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.tar.xz nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.zip |
Initial commit
Diffstat (limited to 'docs/doxygen/nel/a02216.html')
-rw-r--r-- | docs/doxygen/nel/a02216.html | 1033 |
1 files changed, 1033 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a02216.html b/docs/doxygen/nel/a02216.html new file mode 100644 index 00000000..cdd5c821 --- /dev/null +++ b/docs/doxygen/nel/a02216.html @@ -0,0 +1,1033 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> +<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> +<title>NeL: NLMISC::CTaskManager class Reference</title> +<link href="doxygen.css" rel="stylesheet" type="text/css"> +</head><body> +<!-- Generated by Doxygen 1.3.6 --> +<div class="qindex"> <form class="search" action="search.php" method="get"> +<a class="qindex" href="main.html">Main Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical List</a> | <a class="qindex" href="annotated.html">Data Structures</a> | <a class="qindex" href="files.html">File List</a> | <a class="qindex" href="namespacemembers.html">Namespace Members</a> | <a class="qindex" href="functions.html">Data Fields</a> | <a class="qindex" href="globals.html">Globals</a> | <a class="qindex" href="pages.html">Related Pages</a> | <span class="search"><u>S</u>earch for <input class="search" type="text" name="query" value="" size="20" accesskey="s"/></span></form></div> +<h1>NLMISC::CTaskManager Class Reference</h1><code>#include <<a class="el" href="a06486.html">task_manager.h</a>></code> +<p> +<p>Inheritance diagram for NLMISC::CTaskManager: +<p><center><img src="a02216.png" usemap="#NLMISC::CTaskManager_map" border="0" alt=""></center> +<map name="NLMISC::CTaskManager_map"> +<area href="a02187.html" alt="NLMISC::IRunnable" shape="rect" coords="0,0,182,24"> +<area href="a02215.html" alt="NLMISC::CAsyncFileManager" shape="rect" coords="0,112,182,136"> +</map> +<hr><a name="_details"></a><h2>Detailed Description</h2> +<a class="el" href="a02216.html">CTaskManager</a> is a class that manage a list of Task with one Thread <dl compact><dt><b>Author:</b></dt><dd>Alain Saffray <p> +Nevrax France </dd></dl> +<dl compact><dt><b>Date:</b></dt><dd>2000 </dd></dl> + +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00055">55</a> of file <a class="el" href="a06486.html">task_manager.h</a>.<table border=0 cellpadding=0 cellspacing=0> +<tr><td></td></tr> +<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera0">addTask</a> (<a class="el" href="a02187.html">IRunnable</a> *, float priority=0)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Add a task to TaskManager and its priority. <a href="#NLMISC_1_1CTaskManagera0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera1">CTaskManager</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructor. <a href="#NLMISC_1_1CTaskManagera1"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera2">deleteTask</a> (<a class="el" href="a02187.html">IRunnable</a> *<a class="el" href="a04223.html#a628">r</a>)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Delete a task, only if task is not running, return true if found and deleted. <a href="#NLMISC_1_1CTaskManagera2"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera3">dump</a> (std::vector< std::string > &result)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Dump task list. <a href="#NLMISC_1_1CTaskManagera3"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void </td><td class="memItemRight" valign=bottom><a class="el" href="a02187.html#NLMISC_1_1IRunnablePosa0">getName</a> (std::string &result) const </td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera5">getNumWaitingTasks</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Get number of waiting task. <a href="#NLMISC_1_1CTaskManagera5"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera6">isTaskRunning</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Is there a current task ? <a href="#NLMISC_1_1CTaskManagera6"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera7">isThreadRunning</a> () const </td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">return false if exit() is required. task added with <a class="el" href="a02216.html#NLMISC_1_1CTaskManagera0">addTask()</a> should test this flag. <a href="#NLMISC_1_1CTaskManagera7"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera8">registerTaskPriorityCallback</a> (<a class="el" href="a03470.html">IChangeTaskPriority</a> *callback)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Register task priority callback. <a href="#NLMISC_1_1CTaskManagera8"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera9">run</a> (void)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Manage TaskQueue. <a href="#NLMISC_1_1CTaskManagera9"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera10">sleepTask</a> (void)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Sleep a Task. <a href="#NLMISC_1_1CTaskManagera10"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a15">uint</a> </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera11">taskListSize</a> (void)</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Task list size. <a href="#NLMISC_1_1CTaskManagera11"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top> </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagera12">~CTaskManager</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Destructeur. <a href="#NLMISC_1_1CTaskManagera12"></a><br><br></td></tr> +<tr><td colspan=2><br><h2>Protected Member Functions</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerb0">waitCurrentTaskToComplete</a> ()</td></tr> + +<tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>CSynchronized< std::list<<br> + std::string > > </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp0">_DoneTaskQueue</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top>CSynchronized< std::string > </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp1">_RunningTask</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">queue of tasks, using list container instead of queue for DeleteTask methode <a href="#NLMISC_1_1CTaskManagerp1"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>CSynchronized< std::list<<br> + <a class="el" href="a03469.html">CWaitingTask</a> > > </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp2">_TaskQueue</a></td></tr> + +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03880.html">IThread</a> * </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp3">_Thread</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">thread pointer <a href="#NLMISC_1_1CTaskManagerp3"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>volatile bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">flag indicate thread loop, if false cause thread exit <a href="#NLMISC_1_1CTaskManagerp4"></a><br><br></td></tr> +<tr><td colspan=2><br><h2>Private Member Functions</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>void </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerd0">changeTaskPriority</a> ()</td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">Register task priority callback. <a href="#NLMISC_1_1CTaskManagerd0"></a><br><br></td></tr> +<tr><td colspan=2><br><h2>Private Attributes</h2></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03470.html">IChangeTaskPriority</a> * </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerr0">_ChangePriorityCallback</a></td></tr> + +<tr><td class="mdescLeft"> </td><td class="mdescRight">The callback. <a href="#NLMISC_1_1CTaskManagerr0"></a><br><br></td></tr> +<tr><td class="memItemLeft" nowrap align=right valign=top>volatile bool </td><td class="memItemRight" valign=bottom><a class="el" href="a02216.html#NLMISC_1_1CTaskManagerr1">_IsTaskRunning</a></td></tr> + +</table> +<hr><h2>Constructor & Destructor Documentation</h2> +<a class="anchor" name="NLMISC_1_1CTaskManagera1" doxytag="NLMISC::CTaskManager::CTaskManager" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> NLMISC::CTaskManager::CTaskManager </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Constructor. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00039">39</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00108">_ChangePriorityCallback</a>, <a class="el" href="a06486.html#l00158">_IsTaskRunning</a>, <a class="el" href="a06486.html#l00146">_RunningTask</a>, <a class="el" href="a06486.html#l00151">_Thread</a>, <a class="el" href="a06486.html#l00154">_ThreadRunning</a>, and <a class="el" href="a03880.html#NLMISC_1_1IThreada4">NLMISC::IThread::start()</a>. +<p> +<div class="fragment"><pre>00039 : <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp1">_RunningTask</a> (<span class="stringliteral">""</span>), <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp2">_TaskQueue</a> (<span class="stringliteral">""</span>), <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp0">_DoneTaskQueue</a> (<span class="stringliteral">""</span>) +00040 { +00041 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr1">_IsTaskRunning</a> = <span class="keyword">false</span>; +00042 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a> = <span class="keyword">true</span>; +00043 CSynchronized<string>::CAccessor currentTask(&_RunningTask); +00044 currentTask.value () = <span class="stringliteral">""</span>; +00045 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp3">_Thread</a> = IThread::create(<span class="keyword">this</span>); +00046 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp3">_Thread</a>->start(); +00047 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr0">_ChangePriorityCallback</a> = NULL; +00048 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera12" doxytag="NLMISC::CTaskManager::~CTaskManager" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> NLMISC::CTaskManager::~<a class="el" href="a02216.html">CTaskManager</a> </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Destructeur. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00053">53</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00154">_ThreadRunning</a>, and <a class="el" href="a05586.html#l00073">NLMISC::nlSleep()</a>. +<p> +<div class="fragment"><pre>00054 { +00055 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a> = <span class="keyword">false</span>; +00056 <span class="keywordflow">while</span>(!<a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a>) +00057 <a class="code" href="a05378.html#a256">nlSleep</a>(10); +00058 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Member Function Documentation</h2> +<a class="anchor" name="NLMISC_1_1CTaskManagera0" doxytag="NLMISC::CTaskManager::addTask" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::addTask </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02187.html">IRunnable</a> * </td> + <td class="mdname" nowrap>, </td> + </tr> + <tr> + <td class="md" nowrap align="right"></td> + <td></td> + <td class="md" nowrap>float </td> + <td class="mdname" nowrap> <em>priority</em> = 0</td> + </tr> + <tr> + <td></td> + <td class="md">) </td> + <td class="md" colspan="2"></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Add a task to TaskManager and its priority. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00126">126</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00147">_TaskQueue</a>, and <a class="el" href="a05646.html#l00993">r</a>. +<p> +Referenced by <a class="el" href="a05455.html#l00067">NLMISC::CAsyncFileManager::addLoadTask()</a>, <a class="el" href="a06770.html#l00080">NL3D::CZoneManager::checkZonesAround()</a>, <a class="el" href="a05455.html#l00149">NLMISC::CAsyncFileManager::loadFile()</a>, <a class="el" href="a05455.html#l00156">NLMISC::CAsyncFileManager::loadFiles()</a>, and <a class="el" href="a05455.html#l00163">NLMISC::CAsyncFileManager::signal()</a>. +<p> +<div class="fragment"><pre>00127 { +00128 CSynchronized<std::list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00129 acces.value().push_back(CWaitingTask(r, priority)); +00130 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerd0" doxytag="NLMISC::CTaskManager::changeTaskPriority" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::changeTaskPriority </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [private]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Register task priority callback. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00216">216</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00108">_ChangePriorityCallback</a>, <a class="el" href="a06486.html#l00147">_TaskQueue</a>, and <a class="el" href="a03470.html#NLMISC_1_1CTaskManager_1_1IChangeTaskPrioritya0">NLMISC::CTaskManager::IChangeTaskPriority::getTaskPriority()</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00061">run()</a>. +<p> +<div class="fragment"><pre>00217 { +00218 <span class="keywordflow">if</span> (<a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr0">_ChangePriorityCallback</a>) +00219 { +00220 CSynchronized<list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00221 <a class="code" href="a03889.html">list<CWaitingTask></a> &taskList = acces.value(); +00222 +00223 <a class="code" href="a03889.html">list<CWaitingTask></a>::iterator ite = taskList.begin(); +00224 <span class="keywordflow">while</span>(ite != taskList.end()) +00225 { +00226 <span class="comment">// Get the new priority</span> +00227 ite->Priority = <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr0">_ChangePriorityCallback</a>-><a class="code" href="a03470.html#NLMISC_1_1CTaskManager_1_1IChangeTaskPrioritya0">getTaskPriority</a>(*(ite->Task)); +00228 +00229 <span class="comment">// Next task</span> +00230 ite++; +00231 } +00232 } +00233 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera2" doxytag="NLMISC::CTaskManager::deleteTask" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> bool NLMISC::CTaskManager::deleteTask </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a02187.html">IRunnable</a> * </td> + <td class="mdname1" valign="top" nowrap> <em>r</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Delete a task, only if task is not running, return true if found and deleted. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00133">133</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00147">_TaskQueue</a>, and <a class="el" href="a05646.html#l00993">r</a>. +<p> +<div class="fragment"><pre>00134 { +00135 CSynchronized<list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00136 <span class="keywordflow">for</span>(<a class="code" href="a03889.html">list<CWaitingTask></a>::iterator it = acces.value().begin(); it != acces.value().end(); it++) +00137 { +00138 <span class="keywordflow">if</span>(it->Task == <a class="code" href="a04223.html#a628">r</a>) +00139 { +00140 acces.value().erase(it); +00141 <span class="keywordflow">return</span> <span class="keyword">true</span>; +00142 } +00143 } +00144 <span class="keywordflow">return</span> <span class="keyword">false</span>; +00145 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera3" doxytag="NLMISC::CTaskManager::dump" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::dump </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::vector< std::string > & </td> + <td class="mdname1" valign="top" nowrap> <em>result</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Dump task list. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00163">163</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00148">_DoneTaskQueue</a>, <a class="el" href="a06486.html#l00146">_RunningTask</a>, <a class="el" href="a06486.html#l00147">_TaskQueue</a>, and <a class="el" href="a06229.html#l02652">NLMISC::toString()</a>. +<p> +<div class="fragment"><pre>00164 { +00165 CSynchronized<string>::CAccessor accesCurrent(&_RunningTask); +00166 CSynchronized<list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00167 CSynchronized<list<string> >::CAccessor accesDone(&_DoneTaskQueue); +00168 +00169 <span class="keyword">const</span> <a class="code" href="a03889.html">list<CWaitingTask></a> &taskList = acces.value(); +00170 <span class="keyword">const</span> <a class="code" href="a03889.html">list<string></a> &taskDone = accesDone.value(); +00171 <span class="keyword">const</span> string &taskCurrent = accesCurrent.value(); +00172 +00173 <span class="comment">// Resize the destination array</span> +00174 result.clear (); +00175 result.reserve (taskList.size () + taskDone.size () + 1); +00176 +00177 <span class="comment">// Add the waiting strings</span> +00178 <a class="code" href="a03889.html">list<string></a>::const_reverse_iterator iteDone = taskDone.rbegin (); +00179 <span class="keywordflow">while</span> (iteDone != taskDone.rend ()) +00180 { +00181 result.push_back (<span class="stringliteral">"Done : "</span> + *iteDone); +00182 +00183 <span class="comment">// Next task</span> +00184 iteDone++; +00185 } +00186 +00187 <span class="comment">// Add the current string</span> +00188 <span class="keywordflow">if</span> (!taskCurrent.empty()) +00189 { +00190 result.push_back (<span class="stringliteral">"Current : "</span> + taskCurrent); +00191 } +00192 +00193 <span class="comment">// Add the waiting strings</span> +00194 <a class="code" href="a03889.html">list<CWaitingTask></a>::const_iterator ite = taskList.begin (); +00195 <span class="keywordflow">while</span> (ite != taskList.end ()) +00196 { +00197 string name; +00198 ite->Task->getName (name); +00199 result.push_back (<span class="stringliteral">"Waiting : "</span> + name + <span class="stringliteral">" "</span> + <a class="code" href="a05378.html#a244">toString</a>(ite->Priority)); +00200 +00201 <span class="comment">// Next task</span> +00202 ite++; +00203 } +00204 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1IRunnablePosa0" doxytag="NLMISC::CTaskManager::getName" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> virtual void NLMISC::IRunnable::getName </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">std::string & </td> + <td class="mdname1" valign="top" nowrap> <em>result</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline, virtual, inherited]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Reimplemented in <a class="el" href="a02220.html#NL3D_1_1CAsyncFileManager3D_1_1CMeshLoada1">NL3D::CAsyncFileManager3D::CMeshLoad</a>, <a class="el" href="a02218.html#NL3D_1_1CAsyncFileManager3D_1_1CIGLoada1">NL3D::CAsyncFileManager3D::CIGLoad</a>, <a class="el" href="a02219.html#NL3D_1_1CAsyncFileManager3D_1_1CIGLoadUsera1">NL3D::CAsyncFileManager3D::CIGLoadUser</a>, <a class="el" href="a02222.html#NL3D_1_1CAsyncFileManager3D_1_1CTextureLoada1">NL3D::CAsyncFileManager3D::CTextureLoad</a>, <a class="el" href="a03752.html#NL3D_1_1CZoneLoadingTaska1">NL3D::CZoneLoadingTask</a>, <a class="el" href="a02593.html#NLPACS_1_1CGlobalRetriever_1_1CLrLoadera1">NLPACS::CGlobalRetriever::CLrLoader</a>, <a class="el" href="a02223.html#NLMISC_1_1CAsyncFileManager_1_1CFileLoada1">NLMISC::CAsyncFileManager::CFileLoad</a>, <a class="el" href="a02224.html#NLMISC_1_1CAsyncFileManager_1_1CMultipleFileLoada1">NLMISC::CAsyncFileManager::CMultipleFileLoad</a>, and <a class="el" href="a02225.html#NLMISC_1_1CAsyncFileManager_1_1CSignala1">NLMISC::CAsyncFileManager::CSignal</a>. +<p> +Definition at line <a class="el" href="a06535.html#l00074">74</a> of file <a class="el" href="a06535.html">thread.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00061">run()</a>. +<p> +<div class="fragment"><pre>00075 { +00076 result = <span class="stringliteral">"NoName"</span>; +00077 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera5" doxytag="NLMISC::CTaskManager::getNumWaitingTasks" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a15">uint</a> NLMISC::CTaskManager::getNumWaitingTasks </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Get number of waiting task. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00208">208</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00147">_TaskQueue</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>00209 { +00210 CSynchronized<list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00211 <span class="keywordflow">return</span> acces.value().size(); +00212 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera6" doxytag="NLMISC::CTaskManager::isTaskRunning" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> bool NLMISC::CTaskManager::isTaskRunning </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Is there a current task ? +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00090">90</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +References <a class="el" href="a06486.html#l00158">_IsTaskRunning</a>. +<p> +<div class="fragment"><pre>00090 {<span class="keywordflow">return</span> <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr1">_IsTaskRunning</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera7" doxytag="NLMISC::CTaskManager::isThreadRunning" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> bool NLMISC::CTaskManager::isThreadRunning </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap> const<code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +return false if exit() is required. task added with <a class="el" href="a02216.html#NLMISC_1_1CTaskManagera0">addTask()</a> should test this flag. +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00081">81</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +References <a class="el" href="a06486.html#l00154">_ThreadRunning</a>. +<p> +<div class="fragment"><pre>00081 {<span class="keywordflow">return</span> <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a>;} +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera8" doxytag="NLMISC::CTaskManager::registerTaskPriorityCallback" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::registerTaskPriorityCallback </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top"><a class="el" href="a03470.html">IChangeTaskPriority</a> * </td> + <td class="mdname1" valign="top" nowrap> <em>callback</em> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Register task priority callback. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00237">237</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00108">_ChangePriorityCallback</a>. +<p> +<div class="fragment"><pre>00238 { +00239 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr0">_ChangePriorityCallback</a> = callback; +00240 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera9" doxytag="NLMISC::CTaskManager::run" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::run </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">void </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [virtual]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Manage TaskQueue. +<p> + +<p> +Implements <a class="el" href="a02187.html#NLMISC_1_1IRunnablePosa1">NLMISC::IRunnable</a>. +<p> +Definition at line <a class="el" href="a06485.html#l00061">61</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00148">_DoneTaskQueue</a>, <a class="el" href="a06486.html#l00158">_IsTaskRunning</a>, <a class="el" href="a06486.html#l00146">_RunningTask</a>, <a class="el" href="a06486.html#l00147">_TaskQueue</a>, <a class="el" href="a06486.html#l00154">_ThreadRunning</a>, <a class="el" href="a06485.html#l00216">changeTaskPriority()</a>, <a class="el" href="a06535.html#l00074">NLMISC::IRunnable::getName()</a>, <a class="el" href="a06485.html#l00032">NLMISC_DONE_TASK_SIZE</a>, <a class="el" href="a02187.html#NLMISC_1_1IRunnablePosa1">NLMISC::IRunnable::run()</a>, <a class="el" href="a06486.html#l00075">sleepTask()</a>, and <a class="el" href="a06229.html#l02652">NLMISC::toString()</a>. +<p> +<div class="fragment"><pre>00062 { +00063 IRunnable *runnableTask; +00064 <span class="keywordtype">float</span> priorityTask; +00065 <span class="keywordflow">while</span>(<a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a>) +00066 { +00067 { +00068 CSynchronized<list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00069 <span class="keywordflow">if</span>(acces.value().empty()) +00070 { +00071 runnableTask = NULL; +00072 } +00073 <span class="keywordflow">else</span> +00074 { +00075 <span class="comment">// Update task priorities</span> +00076 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerd0">changeTaskPriority</a> (); +00077 +00078 <span class="comment">// Get the best task</span> +00079 <a class="code" href="a03889.html">list<CWaitingTask></a> &taskList = acces.value(); +00080 <a class="code" href="a03889.html">list<CWaitingTask></a>::iterator ite = taskList.begin(); +00081 <a class="code" href="a03889.html">list<CWaitingTask></a>::iterator bestIte = ite; +00082 <span class="keywordflow">while</span> (ite != taskList.end()) +00083 { +00084 <span class="keywordflow">if</span> (ite->Priority < bestIte->Priority) +00085 bestIte = ite; +00086 +00087 <span class="comment">// Next task;</span> +00088 ite++; +00089 } +00090 +00091 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr1">_IsTaskRunning</a> = <span class="keyword">true</span>; +00092 runnableTask = bestIte->Task; +00093 priorityTask = bestIte->Priority; +00094 taskList.erase (bestIte); +00095 } +00096 } +00097 <span class="keywordflow">if</span>(runnableTask) +00098 { +00099 { +00100 CSynchronized<string>::CAccessor currentTask(&_RunningTask); +00101 string temp; +00102 runnableTask->getName(temp); +00103 currentTask.value () = temp + <span class="stringliteral">" "</span> + <a class="code" href="a05378.html#a244">toString</a> (priorityTask); +00104 } +00105 runnableTask->run(); +00106 { +00107 CSynchronized<string>::CAccessor currentTask(&_RunningTask); +00108 CSynchronized<list<string> >::CAccessor doneTask(&_DoneTaskQueue); +00109 doneTask.value().push_front (currentTask.value ()); +00110 currentTask.value () = <span class="stringliteral">""</span>; +00111 <span class="keywordflow">if</span> (doneTask.value().size () > <a class="code" href="a05062.html#a0">NLMISC_DONE_TASK_SIZE</a>) +00112 doneTask.value().resize (NLMISC_DONE_TASK_SIZE); +00113 } +00114 +00115 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr1">_IsTaskRunning</a> = <span class="keyword">false</span>; +00116 } +00117 <span class="keywordflow">else</span> +00118 { +00119 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagera10">sleepTask</a>(); +00120 } +00121 } +00122 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagerp4">_ThreadRunning</a> = <span class="keyword">true</span>; +00123 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera10" doxytag="NLMISC::CTaskManager::sleepTask" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::sleepTask </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">void </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [inline]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Sleep a Task. +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00075">75</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +References <a class="el" href="a05586.html#l00073">NLMISC::nlSleep()</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00061">run()</a>, and <a class="el" href="a06485.html#l00155">waitCurrentTaskToComplete()</a>. +<p> +<div class="fragment"><pre>00075 { <a class="code" href="a05378.html#a256">nlSleep</a>(10); } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagera11" doxytag="NLMISC::CTaskManager::taskListSize" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a15">uint</a> NLMISC::CTaskManager::taskListSize </td> + <td class="md" valign="top">( </td> + <td class="md" nowrap valign="top">void </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +Task list size. +<p> + +<p> +Definition at line <a class="el" href="a06485.html#l00148">148</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00147">_TaskQueue</a>, and <a class="el" href="a05981.html#l00105">uint</a>. +<p> +<div class="fragment"><pre>00149 { +00150 CSynchronized<list<CWaitingTask> >::CAccessor acces(&_TaskQueue); +00151 <span class="keywordflow">return</span> acces.value().size(); +00152 } +</pre></div> </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerb0" doxytag="NLMISC::CTaskManager::waitCurrentTaskToComplete" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> void NLMISC::CTaskManager::waitCurrentTaskToComplete </td> + <td class="md" valign="top">( </td> + <td class="mdname1" valign="top" nowrap> </td> + <td class="md" valign="top"> ) </td> + <td class="md" nowrap><code> [protected]</code></td> + </tr> + + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +If any, wait the current running task to complete this function MUST be called in a 'accessor to the _TaskQueue' statement because a mutex is required eg: { CSynchronized<list<IRunnable *> >::CAccessor acces(&_TaskQueue); <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerb0">waitCurrentTaskToComplete()</a>; } +<p> +Definition at line <a class="el" href="a06485.html#l00155">155</a> of file <a class="el" href="a06485.html">task_manager.cpp</a>. +<p> +References <a class="el" href="a06486.html#l00158">_IsTaskRunning</a>, and <a class="el" href="a06486.html#l00075">sleepTask()</a>. +<p> +Referenced by <a class="el" href="a05455.html#l00072">NLMISC::CAsyncFileManager::cancelLoadTask()</a>. +<p> +<div class="fragment"><pre>00156 { +00157 <span class="keywordflow">while</span> (<a class="code" href="a02216.html#NLMISC_1_1CTaskManagerr1">_IsTaskRunning</a>) +00158 <a class="code" href="a02216.html#NLMISC_1_1CTaskManagera10">sleepTask</a>(); +00159 } +</pre></div> </td> + </tr> +</table> +<hr><h2>Field Documentation</h2> +<a class="anchor" name="NLMISC_1_1CTaskManagerr0" doxytag="NLMISC::CTaskManager::_ChangePriorityCallback" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a03470.html">IChangeTaskPriority</a>* <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerr0">NLMISC::CTaskManager::_ChangePriorityCallback</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +The callback. +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00108">108</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00216">changeTaskPriority()</a>, <a class="el" href="a06485.html#l00039">CTaskManager()</a>, and <a class="el" href="a06485.html#l00237">registerTaskPriorityCallback()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerp0" doxytag="NLMISC::CTaskManager::_DoneTaskQueue" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> CSynchronized<std::list<std::string> > <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp0">NLMISC::CTaskManager::_DoneTaskQueue</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00148">148</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00163">dump()</a>, and <a class="el" href="a06485.html#l00061">run()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerr1" doxytag="NLMISC::CTaskManager::_IsTaskRunning" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> volatile bool <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerr1">NLMISC::CTaskManager::_IsTaskRunning</a><code> [private]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00158">158</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00039">CTaskManager()</a>, <a class="el" href="a06486.html#l00090">isTaskRunning()</a>, <a class="el" href="a06485.html#l00061">run()</a>, and <a class="el" href="a06485.html#l00155">waitCurrentTaskToComplete()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerp1" doxytag="NLMISC::CTaskManager::_RunningTask" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> CSynchronized<std::string> <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp1">NLMISC::CTaskManager::_RunningTask</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +queue of tasks, using list container instead of queue for DeleteTask methode +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00146">146</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00039">CTaskManager()</a>, <a class="el" href="a06485.html#l00163">dump()</a>, and <a class="el" href="a06485.html#l00061">run()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerp2" doxytag="NLMISC::CTaskManager::_TaskQueue" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> CSynchronized<std::list<<a class="el" href="a03469.html">CWaitingTask</a>> > <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp2">NLMISC::CTaskManager::_TaskQueue</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00147">147</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00126">addTask()</a>, <a class="el" href="a06485.html#l00216">changeTaskPriority()</a>, <a class="el" href="a06485.html#l00133">deleteTask()</a>, <a class="el" href="a06485.html#l00163">dump()</a>, <a class="el" href="a06485.html#l00208">getNumWaitingTasks()</a>, <a class="el" href="a06485.html#l00061">run()</a>, and <a class="el" href="a06485.html#l00148">taskListSize()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerp3" doxytag="NLMISC::CTaskManager::_Thread" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> <a class="el" href="a03880.html">IThread</a>* <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp3">NLMISC::CTaskManager::_Thread</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +thread pointer +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00151">151</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00039">CTaskManager()</a>. </td> + </tr> +</table> +<a class="anchor" name="NLMISC_1_1CTaskManagerp4" doxytag="NLMISC::CTaskManager::_ThreadRunning" ></a><p> +<table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> + <tr> + <td class="mdRow"> + <table cellpadding="0" cellspacing="0" border="0"> + <tr> + <td class="md" nowrap valign="top"> volatile bool <a class="el" href="a02216.html#NLMISC_1_1CTaskManagerp4">NLMISC::CTaskManager::_ThreadRunning</a><code> [protected]</code> + </table> + </td> + </tr> +</table> +<table cellspacing=5 cellpadding=0 border=0> + <tr> + <td> + + </td> + <td> + +<p> +flag indicate thread loop, if false cause thread exit +<p> + +<p> +Definition at line <a class="el" href="a06486.html#l00154">154</a> of file <a class="el" href="a06486.html">task_manager.h</a>. +<p> +Referenced by <a class="el" href="a06485.html#l00039">CTaskManager()</a>, <a class="el" href="a06486.html#l00081">isThreadRunning()</a>, <a class="el" href="a06485.html#l00061">run()</a>, and <a class="el" href="a06485.html#l00053">~CTaskManager()</a>. </td> + </tr> +</table> +<hr>The documentation for this class was generated from the following files:<ul> +<li><a class="el" href="a06486.html">task_manager.h</a><li><a class="el" href="a06485.html">task_manager.cpp</a></ul> +<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 13:37:19 2004 for NeL by +<a href="http://www.doxygen.org/index.html"> +<img src="doxygen.png" alt="doxygen" align="middle" border=0 > +</a>1.3.6 </small></address> +</body> +</html> |