You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
348 lines
24 KiB
348 lines
24 KiB
<!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>tbb::interface5::concurrent_priority_queue< T, Compare, A > Class Template Reference</title>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css">
|
|
<link href="tabs.css" rel="stylesheet" type="text/css">
|
|
</head><body>
|
|
<!-- Generated by Doxygen 1.4.7 -->
|
|
<div class="tabs">
|
|
<ul>
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li><a href="modules.html"><span>Modules</span></a></li>
|
|
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
|
|
<li id="current"><a href="annotated.html"><span>Classes</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
</ul></div>
|
|
<div class="tabs">
|
|
<ul>
|
|
<li><a href="annotated.html"><span>Class List</span></a></li>
|
|
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
|
|
<li><a href="functions.html"><span>Class Members</span></a></li>
|
|
</ul></div>
|
|
<div class="nav">
|
|
<a class="el" href="a00428.html">tbb</a>::<b>interface5</b>::<a class="el" href="a00285.html">concurrent_priority_queue</a></div>
|
|
<h1>tbb::interface5::concurrent_priority_queue< T, Compare, A > Class Template Reference</h1><!-- doxytag: class="tbb::interface5::concurrent_priority_queue" -->Concurrent priority queue.
|
|
<a href="#_details">More...</a>
|
|
<p>
|
|
<code>#include <concurrent_priority_queue.h></code>
|
|
<p>
|
|
<a href="a00031.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
|
|
<tr><td></td></tr>
|
|
<tr><td colspan="2"><br><h2>Public Types</h2></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="7c611a6b5b8f94b0e7f2afc97e31efb1"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::value_type" ref="7c611a6b5b8f94b0e7f2afc97e31efb1" args="" -->
|
|
typedef T </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#7c611a6b5b8f94b0e7f2afc97e31efb1">value_type</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Element type in the queue. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="5804b3c708ef4e50d603f918ef2b9e58"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::reference" ref="5804b3c708ef4e50d603f918ef2b9e58" args="" -->
|
|
typedef T & </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#5804b3c708ef4e50d603f918ef2b9e58">reference</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Reference type. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a4ded8601a434098605be0dcc4febc60"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::const_reference" ref="a4ded8601a434098605be0dcc4febc60" args="" -->
|
|
typedef const T & </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#a4ded8601a434098605be0dcc4febc60">const_reference</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Const reference type. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="b679eea8d01d041625a39f719ca2b7ed"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::size_type" ref="b679eea8d01d041625a39f719ca2b7ed" args="" -->
|
|
typedef size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#b679eea8d01d041625a39f719ca2b7ed">size_type</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Integral type for representing size of the queue. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="77399bc76b3ecd60e33f7e35a5becd87"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::difference_type" ref="77399bc76b3ecd60e33f7e35a5becd87" args="" -->
|
|
typedef ptrdiff_t </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#77399bc76b3ecd60e33f7e35a5becd87">difference_type</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Difference type for iterator. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="1712cb3a46bc1821fccc5e2cd83d5cd7"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::allocator_type" ref="1712cb3a46bc1821fccc5e2cd83d5cd7" args="" -->
|
|
typedef A </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a></td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Allocator type. <br></td></tr>
|
|
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="eefa40599afe00ea393897d8f5662e65"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::concurrent_priority_queue" ref="eefa40599afe00ea393897d8f5662e65" args="(const allocator_type &a=allocator_type())" -->
|
|
</td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#eefa40599afe00ea393897d8f5662e65">concurrent_priority_queue</a> (const <a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a> &a=<a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a>())</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructs a new <a class="el" href="a00285.html">concurrent_priority_queue</a> with default capacity. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="4555b4a55415a70024c4004b51e9f385"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::concurrent_priority_queue" ref="4555b4a55415a70024c4004b51e9f385" args="(size_type init_capacity, const allocator_type &a=allocator_type())" -->
|
|
</td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#4555b4a55415a70024c4004b51e9f385">concurrent_priority_queue</a> (<a class="el" href="a00285.html#b679eea8d01d041625a39f719ca2b7ed">size_type</a> init_capacity, const <a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a> &a=<a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a>())</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructs a new <a class="el" href="a00285.html">concurrent_priority_queue</a> with init_sz capacity. <br></td></tr>
|
|
<tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="9147cb4207017c260a0c3929c12cd40f"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::concurrent_priority_queue" ref="9147cb4207017c260a0c3929c12cd40f" args="(InputIterator begin, InputIterator end, const allocator_type &a=allocator_type())" -->
|
|
template<typename InputIterator> </td></tr>
|
|
<tr><td class="memTemplItemLeft" nowrap align="right" valign="top"> </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00285.html#9147cb4207017c260a0c3929c12cd40f">concurrent_priority_queue</a> (InputIterator begin, InputIterator end, const <a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a> &a=<a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a>())</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">[begin,end) constructor <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#509419e320f200456d89dc54a65140b3">concurrent_priority_queue</a> (const <a class="el" href="a00285.html">concurrent_priority_queue</a> &src)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Copy constructor. <a href="#509419e320f200456d89dc54a65140b3"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#c8b20e7430c5302936030bef59a562be">concurrent_priority_queue</a> (const <a class="el" href="a00285.html">concurrent_priority_queue</a> &src, const <a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a> &a)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Copy constructor with specific allocator. <a href="#c8b20e7430c5302936030bef59a562be"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="a00285.html">concurrent_priority_queue</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#2ab7f7808891027ac0f0f5b3a4be51e9">operator=</a> (const <a class="el" href="a00285.html">concurrent_priority_queue</a> &src)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Assignment operator. <a href="#2ab7f7808891027ac0f0f5b3a4be51e9"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#317c508fa92df218be5d014c26c09bb7">empty</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns true if empty, false otherwise. <a href="#317c508fa92df218be5d014c26c09bb7"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="a00285.html#b679eea8d01d041625a39f719ca2b7ed">size_type</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#8b2ae25c61338c6fd59e94fe09822ba5">size</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the current number of elements contained in the queue. <a href="#8b2ae25c61338c6fd59e94fe09822ba5"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#d905af7b8f6defff562f5ae9c3275763">push</a> (<a class="el" href="a00285.html#a4ded8601a434098605be0dcc4febc60">const_reference</a> elem)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Pushes elem onto the queue, increasing capacity of queue if necessary. <a href="#d905af7b8f6defff562f5ae9c3275763"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#e036461a29cc40902a2bb79abf9f5146">try_pop</a> (<a class="el" href="a00285.html#5804b3c708ef4e50d603f918ef2b9e58">reference</a> elem)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Gets a reference to and removes highest priority element. <a href="#e036461a29cc40902a2bb79abf9f5146"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#0bdcdf7cde9fd369edca845bec34ca94">clear</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Clear the queue; not thread-safe. <a href="#0bdcdf7cde9fd369edca845bec34ca94"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#0ecdc6a04aa259374425d424ca2a6082">swap</a> (<a class="el" href="a00285.html">concurrent_priority_queue</a> &q)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Swap this queue with another; not thread-safe. <a href="#0ecdc6a04aa259374425d424ca2a6082"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="d545d444fb0d16148f9b61fd89f9a337"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::get_allocator" ref="d545d444fb0d16148f9b61fd89f9a337" args="() const " -->
|
|
<a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00285.html#d545d444fb0d16148f9b61fd89f9a337">get_allocator</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return allocator object. <br></td></tr>
|
|
<tr><td colspan="2"><br><h2>Classes</h2></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><b>cpq_operation</b></td></tr>
|
|
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><b>my_functor_t</b></td></tr>
|
|
|
|
</table>
|
|
<hr><a name="_details"></a><h2>Detailed Description</h2>
|
|
<h3>template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>><br>
|
|
class tbb::interface5::concurrent_priority_queue< T, Compare, A ></h3>
|
|
|
|
Concurrent priority queue.
|
|
<p>
|
|
<hr><h2>Constructor & Destructor Documentation</h2>
|
|
<a class="anchor" name="509419e320f200456d89dc54a65140b3"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::concurrent_priority_queue" ref="509419e320f200456d89dc54a65140b3" args="(const concurrent_priority_queue &src)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::<a class="el" href="a00285.html">concurrent_priority_queue</a> </td>
|
|
<td>(</td>
|
|
<td class="paramtype">const <a class="el" href="a00285.html">concurrent_priority_queue</a>< T, Compare, A > & </td>
|
|
<td class="paramname"> <em>src</em> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline, explicit]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Copy constructor.
|
|
<p>
|
|
This operation is unsafe if there are pending concurrent operations on the src queue.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="c8b20e7430c5302936030bef59a562be"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::concurrent_priority_queue" ref="c8b20e7430c5302936030bef59a562be" args="(const concurrent_priority_queue &src, const allocator_type &a)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::<a class="el" href="a00285.html">concurrent_priority_queue</a> </td>
|
|
<td>(</td>
|
|
<td class="paramtype">const <a class="el" href="a00285.html">concurrent_priority_queue</a>< T, Compare, A > & </td>
|
|
<td class="paramname"> <em>src</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">const <a class="el" href="a00285.html#1712cb3a46bc1821fccc5e2cd83d5cd7">allocator_type</a> & </td>
|
|
<td class="paramname"> <em>a</em></td><td> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td><td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Copy constructor with specific allocator.
|
|
<p>
|
|
This operation is unsafe if there are pending concurrent operations on the src queue.
|
|
</div>
|
|
</div><p>
|
|
<hr><h2>Member Function Documentation</h2>
|
|
<a class="anchor" name="0bdcdf7cde9fd369edca845bec34ca94"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::clear" ref="0bdcdf7cde9fd369edca845bec34ca94" args="()" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::clear </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Clear the queue; not thread-safe.
|
|
<p>
|
|
This operation is unsafe if there are pending concurrent operations on the queue. Resets size, effectively emptying queue; does not free space. May not clear elements added in pending operations.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="317c508fa92df218be5d014c26c09bb7"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::empty" ref="317c508fa92df218be5d014c26c09bb7" args="() const " -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">bool <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::empty </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"> const<code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Returns true if empty, false otherwise.
|
|
<p>
|
|
Returned value may not reflect results of pending operations. This operation reads shared data and will trigger a race condition.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="2ab7f7808891027ac0f0f5b3a4be51e9"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::operator=" ref="2ab7f7808891027ac0f0f5b3a4be51e9" args="(const concurrent_priority_queue &src)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="a00285.html">concurrent_priority_queue</a>& <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::operator= </td>
|
|
<td>(</td>
|
|
<td class="paramtype">const <a class="el" href="a00285.html">concurrent_priority_queue</a>< T, Compare, A > & </td>
|
|
<td class="paramname"> <em>src</em> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Assignment operator.
|
|
<p>
|
|
This operation is unsafe if there are pending concurrent operations on the src queue.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="d905af7b8f6defff562f5ae9c3275763"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::push" ref="d905af7b8f6defff562f5ae9c3275763" args="(const_reference elem)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::push </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="a00285.html#a4ded8601a434098605be0dcc4febc60">const_reference</a> </td>
|
|
<td class="paramname"> <em>elem</em> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Pushes elem onto the queue, increasing capacity of queue if necessary.
|
|
<p>
|
|
This operation can be safely used concurrently with other push, try_pop or reserve operations.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="8b2ae25c61338c6fd59e94fe09822ba5"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::size" ref="8b2ae25c61338c6fd59e94fe09822ba5" args="() const " -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="a00285.html#b679eea8d01d041625a39f719ca2b7ed">size_type</a> <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::size </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"> const<code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Returns the current number of elements contained in the queue.
|
|
<p>
|
|
Returned value may not reflect results of pending operations. This operation reads shared data and will trigger a race condition.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="0ecdc6a04aa259374425d424ca2a6082"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::swap" ref="0ecdc6a04aa259374425d424ca2a6082" args="(concurrent_priority_queue &q)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::swap </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="a00285.html">concurrent_priority_queue</a>< T, Compare, A > & </td>
|
|
<td class="paramname"> <em>q</em> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Swap this queue with another; not thread-safe.
|
|
<p>
|
|
This operation is unsafe if there are pending concurrent operations on the queue.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="e036461a29cc40902a2bb79abf9f5146"></a><!-- doxytag: member="tbb::interface5::concurrent_priority_queue::try_pop" ref="e036461a29cc40902a2bb79abf9f5146" args="(reference elem)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename T, typename Compare = std::less<T>, typename A = cache_aligned_allocator<T>> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">bool <a class="el" href="a00285.html">tbb::interface5::concurrent_priority_queue</a>< T, Compare, A >::try_pop </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="a00285.html#5804b3c708ef4e50d603f918ef2b9e58">reference</a> </td>
|
|
<td class="paramname"> <em>elem</em> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Gets a reference to and removes highest priority element.
|
|
<p>
|
|
If a highest priority element was found, sets elem and returns true, otherwise returns false. This operation can be safely used concurrently with other push, try_pop or reserve operations.
|
|
</div>
|
|
</div><p>
|
|
<hr>The documentation for this class was generated from the following file:<ul>
|
|
<li>concurrent_priority_queue.h</ul>
|
|
<hr>
|
|
<p></p>
|
|
Copyright © 2005-2013 Intel Corporation. All Rights Reserved.
|
|
<p></p>
|
|
Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are
|
|
registered trademarks or trademarks of Intel Corporation or its
|
|
subsidiaries in the United States and other countries.
|
|
<p></p>
|
|
* Other names and brands may be claimed as the property of others.
|