paradiseo/trunk/paradiseo-moeo/docs/html/classmoeoVector.html
liefooga 2e7e817428 update docs
git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@263 331e1502-861f-0410-8da2-ba01fb791d7f
2007-04-17 15:45:01 +00:00

264 lines
16 KiB
HTML

<!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>ParadisEO-MOEO: moeoVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt; 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.5.1 -->
<div class="tabs">
<ul>
<li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
<li id="current"><a href="classes.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
<li>
<form action="search.php" method="get">
<table cellspacing="0" cellpadding="0" border="0">
<tr>
<td><label>&nbsp;<u>S</u>earch&nbsp;for&nbsp;</label></td>
<td><input type="text" name="query" value="" size="20" accesskey="s"/></td>
</tr>
</table>
</form>
</li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="classes.html"><span>Alphabetical&nbsp;List</span></a></li>
<li><a href="annotated.html"><span>Class&nbsp;List</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>
<h1>moeoVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt; Class Template Reference</h1><!-- doxytag: class="moeoVector" --><!-- doxytag: inherits="MOEO" -->Base class for fixed length chromosomes, just derives from <a class="el" href="classMOEO.html">MOEO</a> and std::vector and redirects the smaller than operator to MOEO (objective vector based comparison).
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>&gt;</code>
<p>
<p>Inheritance diagram for moeoVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;:
<p><center><img src="classmoeoVector.png" usemap="#moeoVector< MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType >_map" border="0" alt=""></center>
<map name="moeoVector< MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType >_map">
<area href="classMOEO.html" alt="MOEO< MOEOObjectiveVector, MOEOFitness, MOEODiversity >" shape="rect" coords="249,168,737,192">
<area doxygen="eo.doxytag:../../../paradiseo-eo/doc/html/" href="../../../paradiseo-eo/doc/html/class_e_o.html" alt="EO< MOEOObjectiveVector >" shape="rect" coords="249,112,737,136">
<area doxygen="eo.doxytag:../../../paradiseo-eo/doc/html/" href="../../../paradiseo-eo/doc/html/classeo_object.html" alt="eoObject" shape="rect" coords="0,56,488,80">
<area doxygen="eo.doxytag:../../../paradiseo-eo/doc/html/" href="../../../paradiseo-eo/doc/html/classeo_persistent.html" alt="eoPersistent" shape="rect" coords="498,56,986,80">
<area doxygen="eo.doxytag:../../../paradiseo-eo/doc/html/" href="../../../paradiseo-eo/doc/html/classeo_printable.html" alt="eoPrintable" shape="rect" coords="498,0,986,24">
</map>
<a href="classmoeoVector-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 Types</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="9d4400084dec28c37e392bb8b0a0b452"></a><!-- doxytag: member="moeoVector::AtomType" ref="9d4400084dec28c37e392bb8b0a0b452" args="" -->
typedef GeneType&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#9d4400084dec28c37e392bb8b0a0b452">AtomType</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">the atomic type <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="b0fb83132e1f2c8b8258013a01aeb364"></a><!-- doxytag: member="moeoVector::ContainerType" ref="b0fb83132e1f2c8b8258013a01aeb364" args="" -->
typedef std::vector&lt; GeneType &gt;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#b0fb83132e1f2c8b8258013a01aeb364">ContainerType</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">the container 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">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#69ea6b5008e6103bf0ae5089302c3b96">moeoVector</a> (unsigned _size=0, GeneType _value=GeneType())</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default ctor. <a href="#69ea6b5008e6103bf0ae5089302c3b96"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#a7fadd876fe492717815510f68a921c5">value</a> (const std::vector&lt; GeneType &gt; &amp;_v)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">We can't have a Ctor from a std::vector as it would create ambiguity with the copy Ctor. <a href="#a7fadd876fe492717815510f68a921c5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#d7a5feff640f00e5d6a29c3ebd11e90b">operator&lt;</a> (const <a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt; &amp;_moeo) const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">To avoid conflicts between <a class="el" href="classMOEO.html#d38eef435511ba3a5a310712a608f4ab">MOEO::operator&lt;</a> and std::vector&lt;GeneType&gt;::operator&lt;. <a href="#d7a5feff640f00e5d6a29c3ebd11e90b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#c327325a47954f69df985da96d2c171a">printOn</a> (std::ostream &amp;_os) const</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Writing object. <a href="#c327325a47954f69df985da96d2c171a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmoeoVector.html#cd8ee0fe79bb9515b29e2a4d3fee5ab9">readFrom</a> (std::istream &amp;_is)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Reading object. <a href="#cd8ee0fe79bb9515b29e2a4d3fee5ab9"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<h3>template&lt;class MOEOObjectiveVector, class MOEOFitness, class MOEODiversity, class GeneType&gt;<br>
class moeoVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;</h3>
Base class for fixed length chromosomes, just derives from <a class="el" href="classMOEO.html">MOEO</a> and std::vector and redirects the smaller than operator to MOEO (objective vector based comparison).
<p>
GeneType must have the following methods: void ctor (needed for the std::vector&lt;&gt;), copy ctor.
<p>
<p>
Definition at line <a class="el" href="moeoVector_8h-source.html#l00025">25</a> of file <a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>.<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="69ea6b5008e6103bf0ae5089302c3b96"></a><!-- doxytag: member="moeoVector::moeoVector" ref="69ea6b5008e6103bf0ae5089302c3b96" args="(unsigned _size=0, GeneType _value=GeneType())" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MOEOObjectiveVector, class MOEOFitness, class MOEODiversity, class GeneType&gt; </div>
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;::<a class="el" href="classmoeoVector.html">moeoVector</a> </td>
<td>(</td>
<td class="paramtype">unsigned&nbsp;</td>
<td class="paramname"> <em>_size</em> = <code>0</code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">GeneType&nbsp;</td>
<td class="paramname"> <em>_value</em> = <code>GeneType()</code></td><td>&nbsp;</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>
Default ctor.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>_size</em>&nbsp;</td><td>Length of vector (default is 0) </td></tr>
<tr><td valign="top"></td><td valign="top"><em>_value</em>&nbsp;</td><td>Initial value of all elements (default is default value of type GeneType) </td></tr>
</table>
</dl>
<p>
Definition at line <a class="el" href="moeoVector_8h-source.html#l00047">47</a> of file <a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>.
</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="a7fadd876fe492717815510f68a921c5"></a><!-- doxytag: member="moeoVector::value" ref="a7fadd876fe492717815510f68a921c5" args="(const std::vector&lt; GeneType &gt; &amp;_v)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MOEOObjectiveVector, class MOEOFitness, class MOEODiversity, class GeneType&gt; </div>
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;::value </td>
<td>(</td>
<td class="paramtype">const std::vector&lt; GeneType &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>_v</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"><code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
We can't have a Ctor from a std::vector as it would create ambiguity with the copy Ctor.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>_v</em>&nbsp;</td><td>a vector of GeneType </td></tr>
</table>
</dl>
<p>
Definition at line <a class="el" href="moeoVector_8h-source.html#l00056">56</a> of file <a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>.
</div>
</div><p>
<a class="anchor" name="d7a5feff640f00e5d6a29c3ebd11e90b"></a><!-- doxytag: member="moeoVector::operator&lt;" ref="d7a5feff640f00e5d6a29c3ebd11e90b" args="(const moeoVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt; &amp;_moeo) const " -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MOEOObjectiveVector, class MOEOFitness, class MOEODiversity, class GeneType&gt; </div>
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;::operator&lt; </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt; &amp;&nbsp;</td>
<td class="paramname"> <em>_moeo</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"> const<code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
To avoid conflicts between <a class="el" href="classMOEO.html#d38eef435511ba3a5a310712a608f4ab">MOEO::operator&lt;</a> and std::vector&lt;GeneType&gt;::operator&lt;.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>_moeo</em>&nbsp;</td><td>the object to compare with </td></tr>
</table>
</dl>
<p>
Definition at line <a class="el" href="moeoVector_8h-source.html#l00075">75</a> of file <a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>.
</div>
</div><p>
<a class="anchor" name="c327325a47954f69df985da96d2c171a"></a><!-- doxytag: member="moeoVector::printOn" ref="c327325a47954f69df985da96d2c171a" args="(std::ostream &amp;_os) const" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MOEOObjectiveVector, class MOEOFitness, class MOEODiversity, class GeneType&gt; </div>
<table class="memname">
<tr>
<td class="memname">virtual void <a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;::printOn </td>
<td>(</td>
<td class="paramtype">std::ostream &amp;&nbsp;</td>
<td class="paramname"> <em>_os</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"> const<code> [inline, virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Writing object.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>_os</em>&nbsp;</td><td>output stream </td></tr>
</table>
</dl>
<p>
Reimplemented from <a class="el" href="classMOEO.html#99e3dbc645fd2c23a82e9303683a05c5">MOEO&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity &gt;</a>.
<p>
Reimplemented in <a class="el" href="classmoeoBitVector.html#e54c36ce64b849a6846953a25247a861">moeoBitVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity &gt;</a>.
<p>
Definition at line <a class="el" href="moeoVector_8h-source.html#l00085">85</a> of file <a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>.
</div>
</div><p>
<a class="anchor" name="cd8ee0fe79bb9515b29e2a4d3fee5ab9"></a><!-- doxytag: member="moeoVector::readFrom" ref="cd8ee0fe79bb9515b29e2a4d3fee5ab9" args="(std::istream &amp;_is)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MOEOObjectiveVector, class MOEOFitness, class MOEODiversity, class GeneType&gt; </div>
<table class="memname">
<tr>
<td class="memname">virtual void <a class="el" href="classmoeoVector.html">moeoVector</a>&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity, GeneType &gt;::readFrom </td>
<td>(</td>
<td class="paramtype">std::istream &amp;&nbsp;</td>
<td class="paramname"> <em>_is</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"><code> [inline, virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Reading object.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>_is</em>&nbsp;</td><td>input stream </td></tr>
</table>
</dl>
<p>
Reimplemented from <a class="el" href="classMOEO.html#1bbd9cb1a7709592bf4bc29dff8c5273">MOEO&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity &gt;</a>.
<p>
Reimplemented in <a class="el" href="classmoeoBitVector.html#31cd3f894615d0a27dd116a5c8082521">moeoBitVector&lt; MOEOObjectiveVector, MOEOFitness, MOEODiversity &gt;</a>.
<p>
Definition at line <a class="el" href="moeoVector_8h-source.html#l00098">98</a> of file <a class="el" href="moeoVector_8h-source.html">moeoVector.h</a>.
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="moeoVector_8h-source.html">moeoVector.h</a></ul>
<hr size="1"><address style="align: right;"><small>Generated on Tue Apr 17 16:53:22 2007 for ParadisEO-MOEO by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.1 </small></address>
</body>
</html>