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.
279 lines
18 KiB
279 lines
18 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::flow::interface6::graph Class 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>flow</b>::<b>interface6</b>::<a class="el" href="a00300.html">graph</a></div>
|
|
<h1>tbb::flow::interface6::graph Class Reference</h1><!-- doxytag: class="tbb::flow::interface6::graph" -->The graph class.
|
|
<a href="#_details">More...</a>
|
|
<p>
|
|
<code>#include <flow_graph.h></code>
|
|
<p>
|
|
<a href="a00059.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="ec5db0443a1320850f8fa05b5eed2ea4"></a><!-- doxytag: member="tbb::flow::interface6::graph::iterator" ref="ec5db0443a1320850f8fa05b5eed2ea4" args="" -->
|
|
typedef graph_iterator< <a class="el" href="a00300.html">graph</a>,<br>
|
|
<a class="el" href="a00301.html">graph_node</a> > </td><td class="memItemRight" valign="bottom"><b>iterator</b></td></tr>
|
|
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="3e677faaf2d66684cd32ccf5492dda4e"></a><!-- doxytag: member="tbb::flow::interface6::graph::const_iterator" ref="3e677faaf2d66684cd32ccf5492dda4e" args="" -->
|
|
typedef graph_iterator< const <br>
|
|
<a class="el" href="a00300.html">graph</a>, const <a class="el" href="a00301.html">graph_node</a> > </td><td class="memItemRight" valign="bottom"><b>const_iterator</b></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="4ab3d4b5208ece28c4c3ced647e26e12"></a><!-- doxytag: member="tbb::flow::interface6::graph::graph" ref="4ab3d4b5208ece28c4c3ced647e26e12" args="()" -->
|
|
</td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#4ab3d4b5208ece28c4c3ced647e26e12">graph</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructs a graph with isolated <a class="el" href="a00352.html">task_group_context</a>. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="104d4f3775f596b43177c29e6b7b7656"></a><!-- doxytag: member="tbb::flow::interface6::graph::graph" ref="104d4f3775f596b43177c29e6b7b7656" args="(task_group_context &use_this_context)" -->
|
|
</td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#104d4f3775f596b43177c29e6b7b7656">graph</a> (<a class="el" href="a00353.html">task_group_context</a> &use_this_context)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Constructs a graph with use_this_context as context. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#8a7d424c0616a1c37a908ead182e2fe5">~graph</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Destroys the graph. <a href="#8a7d424c0616a1c37a908ead182e2fe5"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#a993b789d1e488e0c3929135beae560e">increment_wait_count</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Used to register that an external entity may still interact with the graph. <a href="#a993b789d1e488e0c3929135beae560e"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#29b85506870f13a884a21655aec2a65d">decrement_wait_count</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Deregisters an external entity that may have interacted with the graph. <a href="#29b85506870f13a884a21655aec2a65d"></a><br></td></tr>
|
|
<tr><td class="memTemplParams" nowrap colspan="2">template<typename Receiver, typename Body> </td></tr>
|
|
<tr><td class="memTemplItemLeft" nowrap align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00300.html#50a7938df01b6148ab2c0696835f002e">run</a> (Receiver &r, Body body)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Spawns a task that runs a body and puts its output to a specific receiver. <a href="#50a7938df01b6148ab2c0696835f002e"></a><br></td></tr>
|
|
<tr><td class="memTemplParams" nowrap colspan="2">template<typename Body> </td></tr>
|
|
<tr><td class="memTemplItemLeft" nowrap align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00300.html#c1145b00e063793a7e7bf994d202c7a0">run</a> (Body body)</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Spawns a task that runs a function object. <a href="#c1145b00e063793a7e7bf994d202c7a0"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#a66b0020f7514b86d030fa8aea073d37">wait_for_all</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Wait until graph is idle and decrement_wait_count calls equals increment_wait_count calls. <a href="#a66b0020f7514b86d030fa8aea073d37"></a><br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="7f4e3ae90811a5d8b597146b5b586d10"></a><!-- doxytag: member="tbb::flow::interface6::graph::root_task" ref="7f4e3ae90811a5d8b597146b5b586d10" args="()" -->
|
|
<a class="el" href="a00349.html">task</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#7f4e3ae90811a5d8b597146b5b586d10">root_task</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the root task of the graph. <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="b028cb585ec21e5de523d0075d0fa880"></a><!-- doxytag: member="tbb::flow::interface6::graph::begin" ref="b028cb585ec21e5de523d0075d0fa880" args="()" -->
|
|
iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#b028cb585ec21e5de523d0075d0fa880">begin</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">start iterator <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a167c62511ddacaa152daa64ab2d6aac"></a><!-- doxytag: member="tbb::flow::interface6::graph::end" ref="a167c62511ddacaa152daa64ab2d6aac" args="()" -->
|
|
iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#a167c62511ddacaa152daa64ab2d6aac">end</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">end iterator <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="f63c3b7d03098b57fc16b71c57b303e5"></a><!-- doxytag: member="tbb::flow::interface6::graph::begin" ref="f63c3b7d03098b57fc16b71c57b303e5" args="() const " -->
|
|
const_iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#f63c3b7d03098b57fc16b71c57b303e5">begin</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">start const iterator <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="907bd06606818c36f52420fe8d469d35"></a><!-- doxytag: member="tbb::flow::interface6::graph::end" ref="907bd06606818c36f52420fe8d469d35" args="() const " -->
|
|
const_iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#907bd06606818c36f52420fe8d469d35">end</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">end const iterator <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="e183dfc3f89dc8f57c06ba165fb89f66"></a><!-- doxytag: member="tbb::flow::interface6::graph::cbegin" ref="e183dfc3f89dc8f57c06ba165fb89f66" args="() const " -->
|
|
const_iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#e183dfc3f89dc8f57c06ba165fb89f66">cbegin</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">start const iterator <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="4866156e6a31d0399b61c6eb82ee81fd"></a><!-- doxytag: member="tbb::flow::interface6::graph::cend" ref="4866156e6a31d0399b61c6eb82ee81fd" args="() const " -->
|
|
const_iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#4866156e6a31d0399b61c6eb82ee81fd">cend</a> () const </td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">end const iterator <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="227ea140dc2c68f79a4e5a34a8367b58"></a><!-- doxytag: member="tbb::flow::interface6::graph::is_cancelled" ref="227ea140dc2c68f79a4e5a34a8367b58" args="()" -->
|
|
bool </td><td class="memItemRight" valign="bottom"><a class="el" href="a00300.html#227ea140dc2c68f79a4e5a34a8367b58">is_cancelled</a> ()</td></tr>
|
|
|
|
<tr><td class="mdescLeft"> </td><td class="mdescRight">return status of graph execution <br></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="e48ff6b3b7433ce6ee2c2518b79d1a7c"></a><!-- doxytag: member="tbb::flow::interface6::graph::exception_thrown" ref="e48ff6b3b7433ce6ee2c2518b79d1a7c" args="()" -->
|
|
bool </td><td class="memItemRight" valign="bottom"><b>exception_thrown</b> ()</td></tr>
|
|
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="11cdff0b9201b4b9fa173265a8d7b9f4"></a><!-- doxytag: member="tbb::flow::interface6::graph::reset" ref="11cdff0b9201b4b9fa173265a8d7b9f4" args="()" -->
|
|
void </td><td class="memItemRight" valign="bottom"><b>reset</b> ()</td></tr>
|
|
|
|
<tr><td colspan="2"><br><h2>Friends</h2></td></tr>
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="9143fb4f732c36d5587e467e21a0e7f6"></a><!-- doxytag: member="tbb::flow::interface6::graph::graph_node" ref="9143fb4f732c36d5587e467e21a0e7f6" args="" -->
|
|
class </td><td class="memItemRight" valign="bottom"><b>graph_node</b></td></tr>
|
|
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="621c092f8466e55743ceef04b0bde9ce"></a><!-- doxytag: member="tbb::flow::interface6::graph::graph_iterator" ref="621c092f8466e55743ceef04b0bde9ce" args="" -->
|
|
class </td><td class="memItemRight" valign="bottom"><b>graph_iterator</b></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>run_and_put_task</b></td></tr>
|
|
|
|
<tr><td class="memItemLeft" nowrap align="right" valign="top">class </td><td class="memItemRight" valign="bottom"><b>run_task</b></td></tr>
|
|
|
|
</table>
|
|
<hr><a name="_details"></a><h2>Detailed Description</h2>
|
|
The graph class.
|
|
<p>
|
|
This class serves as a handle to the graph
|
|
<p>
|
|
<hr><h2>Constructor & Destructor Documentation</h2>
|
|
<a class="anchor" name="8a7d424c0616a1c37a908ead182e2fe5"></a><!-- doxytag: member="tbb::flow::interface6::graph::~graph" ref="8a7d424c0616a1c37a908ead182e2fe5" args="()" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">tbb::flow::interface6::graph::~graph </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Destroys the graph.
|
|
<p>
|
|
Calls wait_for_all, then destroys the root task and context.
|
|
</div>
|
|
</div><p>
|
|
<hr><h2>Member Function Documentation</h2>
|
|
<a class="anchor" name="29b85506870f13a884a21655aec2a65d"></a><!-- doxytag: member="tbb::flow::interface6::graph::decrement_wait_count" ref="29b85506870f13a884a21655aec2a65d" args="()" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void tbb::flow::interface6::graph::decrement_wait_count </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Deregisters an external entity that may have interacted with the graph.
|
|
<p>
|
|
The graph will not return from wait_for_all until all the number of decrement_wait_count calls matches the number of increment_wait_count calls.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="a993b789d1e488e0c3929135beae560e"></a><!-- doxytag: member="tbb::flow::interface6::graph::increment_wait_count" ref="a993b789d1e488e0c3929135beae560e" args="()" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void tbb::flow::interface6::graph::increment_wait_count </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Used to register that an external entity may still interact with the graph.
|
|
<p>
|
|
The graph will not return from wait_for_all until a matching number of decrement_wait_count calls is made.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="c1145b00e063793a7e7bf994d202c7a0"></a><!-- doxytag: member="tbb::flow::interface6::graph::run" ref="c1145b00e063793a7e7bf994d202c7a0" args="(Body body)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename Body> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void tbb::flow::interface6::graph::run </td>
|
|
<td>(</td>
|
|
<td class="paramtype">Body </td>
|
|
<td class="paramname"> <em>body</em> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Spawns a task that runs a function object.
|
|
<p>
|
|
The task is spawned as a child of the graph. This is useful for running tasks that need to block a <a class="el" href="a00300.html#a66b0020f7514b86d030fa8aea073d37">wait_for_all()</a> on the graph. For example a one-off source.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="50a7938df01b6148ab2c0696835f002e"></a><!-- doxytag: member="tbb::flow::interface6::graph::run" ref="50a7938df01b6148ab2c0696835f002e" args="(Receiver &r, Body body)" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<div class="memtemplate">
|
|
template<typename Receiver, typename Body> </div>
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void tbb::flow::interface6::graph::run </td>
|
|
<td>(</td>
|
|
<td class="paramtype">Receiver & </td>
|
|
<td class="paramname"> <em>r</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">Body </td>
|
|
<td class="paramname"> <em>body</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>
|
|
Spawns a task that runs a body and puts its output to a specific receiver.
|
|
<p>
|
|
The task is spawned as a child of the graph. This is useful for running tasks that need to block a <a class="el" href="a00300.html#a66b0020f7514b86d030fa8aea073d37">wait_for_all()</a> on the graph. For example a one-off source.
|
|
</div>
|
|
</div><p>
|
|
<a class="anchor" name="a66b0020f7514b86d030fa8aea073d37"></a><!-- doxytag: member="tbb::flow::interface6::graph::wait_for_all" ref="a66b0020f7514b86d030fa8aea073d37" args="()" -->
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void tbb::flow::interface6::graph::wait_for_all </td>
|
|
<td>(</td>
|
|
<td class="paramname"> </td>
|
|
<td> ) </td>
|
|
<td width="100%"><code> [inline]</code></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="memdoc">
|
|
|
|
<p>
|
|
Wait until graph is idle and decrement_wait_count calls equals increment_wait_count calls.
|
|
<p>
|
|
The waiting thread will go off and steal work while it is block in the wait_for_all.
|
|
</div>
|
|
</div><p>
|
|
<hr>The documentation for this class was generated from the following file:<ul>
|
|
<li><a class="el" href="a00385.html">flow_graph.h</a></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.
|