📄 group__apr__thread__cond.html
字号:
<a class="anchor" name="ga7" doxytag="apr_thread_cond.h::apr_thread_cond_pool_get" ></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="group__apr__pools.html#ga0">apr_pool_t</a>* apr_thread_cond_pool_get </td>
<td class="md" valign="top">( </td>
<td class="md" nowrap valign="top">const <a class="el" href="group__apr__thread__cond.html#ga0">apr_thread_cond_t</a> * </td>
<td class="mdname1" valign="top" nowrap> <em>thethread_cond</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>
Get the pool used by this thread_cond. <dl compact><dt><b>Returns:</b></dt><dd>apr_pool_t the pool </dd></dl>
</td>
</tr>
</table>
<a class="anchor" name="ga4" doxytag="apr_thread_cond.h::apr_thread_cond_signal" ></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="group__apr__errno.html#ga0">apr_status_t</a> apr_thread_cond_signal </td>
<td class="md" valign="top">( </td>
<td class="md" nowrap valign="top"><a class="el" href="group__apr__thread__cond.html#ga0">apr_thread_cond_t</a> * </td>
<td class="mdname1" valign="top" nowrap> <em>cond</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>
Signals a single thread, if one exists, that is blocking on the given condition variable. That thread is then scheduled to wake up and acquire the associated mutex. Although it is not required, if predictable scheduling is desired, that mutex must be locked while calling this function. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td></td><td valign=top><em>cond</em> </td><td>the condition variable on which to produce the signal. </td></tr>
</table>
</dl>
</td>
</tr>
</table>
<a class="anchor" name="ga3" doxytag="apr_thread_cond.h::apr_thread_cond_timedwait" ></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="group__apr__errno.html#ga0">apr_status_t</a> apr_thread_cond_timedwait </td>
<td class="md" valign="top">( </td>
<td class="md" nowrap valign="top"><a class="el" href="group__apr__thread__cond.html#ga0">apr_thread_cond_t</a> * </td>
<td class="mdname" nowrap> <em>cond</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td></td>
<td class="md" nowrap><a class="el" href="group__apr__thread__mutex.html#ga0">apr_thread_mutex_t</a> * </td>
<td class="mdname" nowrap> <em>mutex</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td></td>
<td class="md" nowrap><a class="el" href="group__apr__time.html#ga3">apr_interval_time_t</a> </td>
<td class="mdname" nowrap> <em>timeout</em></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>
Put the active calling thread to sleep until signaled to wake up or the timeout is reached. Each condition variable must be associated with a mutex, and that mutex must be locked before calling this function, or the behavior will be undefined. As the calling thread is put to sleep, the given mutex will be simultaneously released; and as this thread wakes up the lock is again simultaneously acquired. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td></td><td valign=top><em>cond</em> </td><td>the condition variable on which to block. </td></tr>
<tr><td></td><td valign=top><em>mutex</em> </td><td>the mutex that must be locked upon entering this function, is released while the thread is asleep, and is again acquired before returning from this function. </td></tr>
<tr><td></td><td valign=top><em>timeout</em> </td><td>The amount of time in microseconds to wait. This is a maximum, not a minimum. If the condition is signaled, we will wake up before this time, otherwise the error APR_TIMEUP is returned. </td></tr>
</table>
</dl>
</td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="apr_thread_cond.h::apr_thread_cond_wait" ></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="group__apr__errno.html#ga0">apr_status_t</a> apr_thread_cond_wait </td>
<td class="md" valign="top">( </td>
<td class="md" nowrap valign="top"><a class="el" href="group__apr__thread__cond.html#ga0">apr_thread_cond_t</a> * </td>
<td class="mdname" nowrap> <em>cond</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td></td>
<td class="md" nowrap><a class="el" href="group__apr__thread__mutex.html#ga0">apr_thread_mutex_t</a> * </td>
<td class="mdname" nowrap> <em>mutex</em></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>
Put the active calling thread to sleep until signaled to wake up. Each condition variable must be associated with a mutex, and that mutex must be locked before calling this function, or the behavior will be undefined. As the calling thread is put to sleep, the given mutex will be simultaneously released; and as this thread wakes up the lock is again simultaneously acquired. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td></td><td valign=top><em>cond</em> </td><td>the condition variable on which to block. </td></tr>
<tr><td></td><td valign=top><em>mutex</em> </td><td>the mutex that must be locked upon entering this function, is released while the thread is asleep, and is again acquired before returning from this function. </td></tr>
</table>
</dl>
</td>
</tr>
</table>
<hr size="1"><address style="align: right;"><small>Generated on Mon Feb 7 13:18:26 2005 for Apache Portable Runtime by
<a href="../../../www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border=0 ></a> 1.3.7 </small></address>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -