Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > 598246a3099b0106d22dd5249478d3b7 > files > 125

ccrtp-devel-1.7.1-2.fc12.i686.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>ccRTP: RTPSessionPool Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.9 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
      <li><a href="classes.html"><span>Class&nbsp;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>RTPSessionPool Class Reference</h1><!-- doxytag: class="RTPSessionPool" --><!-- doxytag: inherits="RTPSessionBaseHandler" -->This class is a base class for classes that define a group of RTP sessions that will be served by one or more execution threads.  
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="pool_8h_source.html">pool.h</a>&gt;</code>
<p>
<div class="dynheader">
Inheritance diagram for RTPSessionPool:</div>
<div class="dynsection">

<p><center><img src="class_r_t_p_session_pool.png" usemap="#RTPSessionPool_map" border="0" alt=""></center>
<map name="RTPSessionPool_map">
<area href="class_r_t_p_session_base_handler.html" alt="RTPSessionBaseHandler" shape="rect" coords="0,0,152,24">
<area href="class_single_r_t_p_session_pool.html" alt="SingleRTPSessionPool" shape="rect" coords="0,112,152,136">
</map>
</div>

<p>
<a href="class_r_t_p_session_pool-members.html">List of all members.</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">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#f71216f4e7feffc4a1ce09ad09f61e00">RTPSessionPool</a> ()</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#21183e45cdc63081014dd949b8d44187">~RTPSessionPool</a> ()</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#75bfb63a4e3f2a5733d6c6791ebd3290">addSession</a> (<a class="el" href="class_r_t_p_session_base.html">RTPSessionBase</a> &amp;session)</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#2dc76b8c47f413489087196432f631af">removeSession</a> (<a class="el" href="class_r_t_p_session_base.html">RTPSessionBase</a> &amp;session)</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">size_t&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#0a3282183a7c74a3bbdd89f2e47bcbf5">getPoolLength</a> () const </td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#0bac7dd70b374f5133852d6d7ba7cdf5">startRunning</a> ()=0</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#7819ba46f655aa793db2aa003da21df4">isActive</a> ()</td></tr>

<tr><td colspan="2"><br><h2>Protected Types</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef std::list<br class="typebreak">
&lt; <a class="el" href="class_session_list_element.html">SessionListElement</a> * &gt;<br class="typebreak">
::iterator&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#1430560da7877fabc2de9bea53054438">PoolIterator</a></td></tr>

<tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#cb99df4c50af8713dd36087b8381cc8b">setActive</a> ()</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">timeval&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#14eae74f2744ff7d88f978335d6262e8">getPoolTimeout</a> ()</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#8786c68862aa74f74f94130b6b0eb949">setPoolTimeout</a> (int sec, int usec)</td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#e0a03e7d2897eba1c40efd91efaa28d5">setPoolTimeout</a> (struct timeval to)</td></tr>

<tr><td colspan="2"><br><h2>Protected Attributes</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">std::list&lt; <a class="el" href="class_session_list_element.html">SessionListElement</a> * &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#c5f2382721c2dc7253b355ba4f12e3d8">sessionList</a></td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">ThreadLock&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#d90e7ca14b02de5be3eacf7d27946d79">poolLock</a></td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">fd_set&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#fbc0205f973575c59eb89c7f11cd9cac">recvSocketSet</a></td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top">SOCKET&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_r_t_p_session_pool.html#4318d42eed619e6f9f75ddc4e9d7383e">highestSocket</a></td></tr>

</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
This class is a base class for classes that define a group of RTP sessions that will be served by one or more execution threads. 
<p>
Derived classes are responsible for serving each RTP session with a thread at least.<p>
In order to use the RTP session "pool" you just have to build <a class="el" href="class_r_t_p_session_base.html" title="Generic RTP protocol stack for exchange of realtime data.">RTPSessionBase</a> objects for each RTP session (instead of RTPSession objects). Then, add the <a class="el" href="class_r_t_p_session_base.html" title="Generic RTP protocol stack for exchange of realtime data.">RTPSessionBase</a> objects to an RTP session "pool" and call <a class="el" href="class_r_t_p_session_pool.html#0bac7dd70b374f5133852d6d7ba7cdf5">startRunning()</a> method of the session pool.<p>
<dl class="author" compact><dt><b>Author:</b></dt><dd>Federico Montesino Pouzols &lt;<a href="mailto:fedemp@altern.org">fedemp@altern.org</a>&gt; </dd></dl>
<hr><h2>Member Typedef Documentation</h2>
<a class="anchor" name="1430560da7877fabc2de9bea53054438"></a><!-- doxytag: member="RTPSessionPool::PoolIterator" ref="1430560da7877fabc2de9bea53054438" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef std::list&lt;<a class="el" href="class_session_list_element.html">SessionListElement</a>*&gt;::iterator <a class="el" href="class_r_t_p_session_pool.html#1430560da7877fabc2de9bea53054438">RTPSessionPool::PoolIterator</a><code> [protected]</code>          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="f71216f4e7feffc4a1ce09ad09f61e00"></a><!-- doxytag: member="RTPSessionPool::RTPSessionPool" ref="f71216f4e7feffc4a1ce09ad09f61e00" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">RTPSessionPool::RTPSessionPool           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="21183e45cdc63081014dd949b8d44187"></a><!-- doxytag: member="RTPSessionPool::~RTPSessionPool" ref="21183e45cdc63081014dd949b8d44187" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual RTPSessionPool::~RTPSessionPool           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="75bfb63a4e3f2a5733d6c6791ebd3290"></a><!-- doxytag: member="RTPSessionPool::addSession" ref="75bfb63a4e3f2a5733d6c6791ebd3290" args="(RTPSessionBase &amp;session)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool RTPSessionPool::addSession           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_r_t_p_session_base.html">RTPSessionBase</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>session</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="0a3282183a7c74a3bbdd89f2e47bcbf5"></a><!-- doxytag: member="RTPSessionPool::getPoolLength" ref="0a3282183a7c74a3bbdd89f2e47bcbf5" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">size_t RTPSessionPool::getPoolLength           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="14eae74f2744ff7d88f978335d6262e8"></a><!-- doxytag: member="RTPSessionPool::getPoolTimeout" ref="14eae74f2744ff7d88f978335d6262e8" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">timeval RTPSessionPool::getPoolTimeout           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline, protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="7819ba46f655aa793db2aa003da21df4"></a><!-- doxytag: member="RTPSessionPool::isActive" ref="7819ba46f655aa793db2aa003da21df4" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool RTPSessionPool::isActive           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="2dc76b8c47f413489087196432f631af"></a><!-- doxytag: member="RTPSessionPool::removeSession" ref="2dc76b8c47f413489087196432f631af" args="(RTPSessionBase &amp;session)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool RTPSessionPool::removeSession           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_r_t_p_session_base.html">RTPSessionBase</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>session</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="cb99df4c50af8713dd36087b8381cc8b"></a><!-- doxytag: member="RTPSessionPool::setActive" ref="cb99df4c50af8713dd36087b8381cc8b" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void RTPSessionPool::setActive           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline, protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="e0a03e7d2897eba1c40efd91efaa28d5"></a><!-- doxytag: member="RTPSessionPool::setPoolTimeout" ref="e0a03e7d2897eba1c40efd91efaa28d5" args="(struct timeval to)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void RTPSessionPool::setPoolTimeout           </td>
          <td>(</td>
          <td class="paramtype">struct timeval&nbsp;</td>
          <td class="paramname"> <em>to</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [inline, protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="8786c68862aa74f74f94130b6b0eb949"></a><!-- doxytag: member="RTPSessionPool::setPoolTimeout" ref="8786c68862aa74f74f94130b6b0eb949" args="(int sec, int usec)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void RTPSessionPool::setPoolTimeout           </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>sec</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>usec</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [inline, protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="0bac7dd70b374f5133852d6d7ba7cdf5"></a><!-- doxytag: member="RTPSessionPool::startRunning" ref="0bac7dd70b374f5133852d6d7ba7cdf5" args="()=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void RTPSessionPool::startRunning           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

<p>Implemented in <a class="el" href="class_single_r_t_p_session_pool.html#65445dc5b64a42f4cda434a00743b0b8">SingleRTPSessionPool</a>.</p>

</div>
</div><p>
<hr><h2>Member Data Documentation</h2>
<a class="anchor" name="4318d42eed619e6f9f75ddc4e9d7383e"></a><!-- doxytag: member="RTPSessionPool::highestSocket" ref="4318d42eed619e6f9f75ddc4e9d7383e" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">SOCKET <a class="el" href="class_r_t_p_session_pool.html#4318d42eed619e6f9f75ddc4e9d7383e">RTPSessionPool::highestSocket</a><code> [protected]</code>          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="d90e7ca14b02de5be3eacf7d27946d79"></a><!-- doxytag: member="RTPSessionPool::poolLock" ref="d90e7ca14b02de5be3eacf7d27946d79" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ThreadLock <a class="el" href="class_r_t_p_session_pool.html#d90e7ca14b02de5be3eacf7d27946d79">RTPSessionPool::poolLock</a><code> [mutable, protected]</code>          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="fbc0205f973575c59eb89c7f11cd9cac"></a><!-- doxytag: member="RTPSessionPool::recvSocketSet" ref="fbc0205f973575c59eb89c7f11cd9cac" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">fd_set <a class="el" href="class_r_t_p_session_pool.html#fbc0205f973575c59eb89c7f11cd9cac">RTPSessionPool::recvSocketSet</a><code> [protected]</code>          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<a class="anchor" name="c5f2382721c2dc7253b355ba4f12e3d8"></a><!-- doxytag: member="RTPSessionPool::sessionList" ref="c5f2382721c2dc7253b355ba4f12e3d8" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">std::list&lt;<a class="el" href="class_session_list_element.html">SessionListElement</a>*&gt; <a class="el" href="class_r_t_p_session_pool.html#c5f2382721c2dc7253b355ba4f12e3d8">RTPSessionPool::sessionList</a><code> [protected]</code>          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>

</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="pool_8h_source.html">pool.h</a></ul>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Fri Jul 24 21:42:26 2009 for ccRTP by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.9 </small></address>
</body>
</html>