<ahref="#pub-methods">Public Member Functions</a>|
<ahref="#friends">Friends</a>|
<ahref="classcrashpad_1_1WorkerThread-members.html">List of all members</a></div>
<divclass="headertitle">
<divclass="title">crashpad::WorkerThread Class Reference</div></div>
</div><!--header-->
<divclass="contents">
<p>A <aclass="el"href="classcrashpad_1_1WorkerThread.html"title="A WorkerThread executes its Delegate's DoWork method repeatedly on a dedicated thread at a set time i...">WorkerThread</a> executes its <aclass="el"href="classcrashpad_1_1WorkerThread_1_1Delegate.html"title="An interface for doing work on a WorkerThread. ">Delegate</a>'s DoWork method repeatedly on a dedicated thread at a set time interval.
<trclass="memdesc:"><tdclass="mdescLeft"> </td><tdclass="mdescRight">An interface for doing work on a <aclass="el"href="classcrashpad_1_1WorkerThread.html"title="A WorkerThread executes its Delegate's DoWork method repeatedly on a dedicated thread at a set time i...">WorkerThread</a>. <ahref="classcrashpad_1_1WorkerThread_1_1Delegate.html#details">More...</a><br/></td></tr>
<trclass="memdesc:acd19c649b9eb4440f6685b016c01b1f7"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Creates a new <aclass="el"href="classcrashpad_1_1WorkerThread.html"title="A WorkerThread executes its Delegate's DoWork method repeatedly on a dedicated thread at a set time i...">WorkerThread</a> that is not yet running. <ahref="#acd19c649b9eb4440f6685b016c01b1f7">More...</a><br/></td></tr>
<trclass="memdesc:a5d5bb2e8fe18e4ca391b09a09d1ea23f"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Starts the worker thread. <ahref="#a5d5bb2e8fe18e4ca391b09a09d1ea23f">More...</a><br/></td></tr>
<trclass="memdesc:a6fb859504e561e443236960adbf5fad6"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Stops the worker thread from running. <ahref="#a6fb859504e561e443236960adbf5fad6">More...</a><br/></td></tr>
<trclass="memdesc:af30d5046ff7606f8d6b3fc5bf61143e0"><tdclass="mdescLeft"> </td><tdclass="mdescRight">Interrupts a <em>work_interval</em> to execute the work function immediately. This invokes <aclass="el"href="classcrashpad_1_1WorkerThread_1_1Delegate.html#a91492f3dae15910a62d1980f0ec618c3"title="The work function executed by the WorkerThread every work interval. ">Delegate::DoWork()</a> on the thread, without waiting for the current <em>work_interval</em> to expire. After the delegate is invoked, the <aclass="el"href="classcrashpad_1_1WorkerThread.html"title="A WorkerThread executes its Delegate's DoWork method repeatedly on a dedicated thread at a set time i...">WorkerThread</a> will start waiting for a new <em>work_interval</em>. <br/></td></tr>
<divclass="textblock"><p>A <aclass="el"href="classcrashpad_1_1WorkerThread.html"title="A WorkerThread executes its Delegate's DoWork method repeatedly on a dedicated thread at a set time i...">WorkerThread</a> executes its <aclass="el"href="classcrashpad_1_1WorkerThread_1_1Delegate.html"title="An interface for doing work on a WorkerThread. ">Delegate</a>'s DoWork method repeatedly on a dedicated thread at a set time interval. </p>
</div><h2class="groupheader">Constructor & Destructor Documentation</h2>
<p>Creates a new <aclass="el"href="classcrashpad_1_1WorkerThread.html"title="A WorkerThread executes its Delegate's DoWork method repeatedly on a dedicated thread at a set time i...">WorkerThread</a> that is not yet running. </p>
<dlclass="params"><dt>Parameters</dt><dd>
<tableclass="params">
<tr><tdclass="paramdir">[in]</td><tdclass="paramname">work_interval</td><td>The time interval in seconds at which the <em>delegate</em> runs. The interval counts from the completion of <aclass="el"href="classcrashpad_1_1WorkerThread_1_1Delegate.html#a91492f3dae15910a62d1980f0ec618c3"title="The work function executed by the WorkerThread every work interval. ">Delegate::DoWork()</a> to the next invocation. </td></tr>
<tr><tdclass="paramdir">[in]</td><tdclass="paramname">delegate</td><td>The work delegate to invoke every interval. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<h2class="groupheader">Member Function Documentation</h2>
<tr><tdclass="paramdir">[in]</td><tdclass="paramname">initial_work_delay</td><td>The amount of time in seconds to wait before invoking the <em>delegate</em> for the first time. Pass <code>0</code> for no delay. </td></tr>
<p>If the work function is currently executing, this will not interrupt it. This method stops any future work from occurring. This method is safe to call from any thread with the exception of the worker thread itself, as this joins the thread. </p>
</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>util/thread/worker_thread.h</li>
<li>util/thread/worker_thread.cc</li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hrclass="footer"/><addressclass="footer"><small>
Generated by  <ahref="http://www.doxygen.org/index.html">