⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 eoonemaxinit.html

📁 这是linux下的进化计算的源代码。 === === === === === === === === === === === ===== check latest news at http:
💻 HTML
字号:
<!doctype html public "-//w3c//dtd html 4.0 transitional//en"><html><head>   <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">   <meta name="GENERATOR" content="Mozilla/4.78 [en] (X11; U; Linux 2.4.7-10 i686) [Netscape]">   <title>Templates/eoOneMaxInit.h</title></head><body text="#000000" bgcolor="#C3C2B4" link="#0000EE" vlink="#551A8B" alink="#FF0000"><a href="eoLesson5.html">Back to Lesson 5</a> -<a href="eoTutorial.html">Tutorial main page </a>- <a href="eoTopDown.html">Top-Downpage</a> - <a href="eoBottomUp.html">Bottom-up page</a> - <a href="eoProgramming.html">Programminghints</a> - <font face="Arial,Helvetica"><a href="doc/html/index.html">EOdocumentation</a></font><br><hr WIDTH="100%"><!-- -------------- End of header ------------------ --><!-- ----------------------------------------------- --><center><h1><font color="#FF0000">Templates/eoOneMaxInit.h</font></h1></center>The places where you have to put some code are on <b><font color="#FF6666">pinkbackground</font></b>.. Only the the <a href="eoTutorial.html#colors">charactercolors have the usual meaning</a>.<br><a NAME="start"></a><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#CCCCCC" NOSAVE ><tr NOSAVE><td NOSAVE><tt><font color="#993300">/** -*- mode: c++; c-indent-level:4; c++-member-init-indent: 8; comment-column: 35; -*-</font></tt><br><tt><font color="#993300">The above line is usefulin Emacs-like editors</font></tt><br><tt><font color="#993300">*/</font></tt><p><tt><font color="#993300">/*</font></tt><br><tt><font color="#993300">Template for EO objects initialization inEO</font></tt><br><tt><font color="#993300">============================================</font></tt><br><tt><font color="#993300">*/</font></tt><p><b><tt><font color="#993300">#ifndef _eoOneMaxInit_h</font></tt></b><br><b><tt><font color="#993300">#define _eoOneMaxInit_h</font></tt></b><p><tt><font color="#993300">// include the base definition of eoInit</font></tt><br><b><tt><font color="#993300">#include &lt;eoInit.h></font></tt></b><p><tt><font color="#993300">/**&nbsp;</font></tt><br><tt><font color="#993300">*&nbsp; Always write a comment in this formatbefore class definition</font></tt><br><tt><font color="#993300">*&nbsp; if you want the class to be documentedby Doxygen</font></tt><br><tt><font color="#993300">*</font></tt><br><tt><font color="#993300">* There is NO ASSUMPTION on the class GenoypeT.</font></tt><br><tt><font color="#993300">* In particular, it does not need to derivefrom EO (e.g. to initialize&nbsp;</font></tt><br><tt><font color="#993300">*&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; atoms ofan eoVector you will need an eoInit&lt;AtomType>)</font></tt><br><tt><font color="#993300">*/</font></tt></td></tr></table><a NAME="init"></a><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#CCCCCC" NOSAVE ><tr><td><b><tt><font color="#993399">template &lt;class GenotypeT></font></tt></b><br><b><tt><font color="#993399">class eoOneMaxInit: public eoInit&lt;GenotypeT>{</font></tt></b><br><b><tt><font color="#993399">public:</font></tt></b><br><tt><font color="#993399">/// Ctor - no requirement</font></tt></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#FFCCCC" NOSAVE ><tr><td><a NAME="constructor"></a><tt><font color="#993399">// START eventuallyadd or modify the anyVariable argument</font></tt><br><b><tt><font color="#993399">&nbsp;eoOneMaxInit()</font></tt></b><br><tt><font color="#993399"><b>&nbsp;</b> //&nbsp; eoOneMaxInit( varType&nbsp;_anyVariable) : anyVariable(_anyVariable)&nbsp;</font></tt><br><tt><font color="#993399">// END eventually add or modify the anyVariableargument</font></tt></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#CCCCCC" NOSAVE ><tr><td><b><tt><font color="#993399">&nbsp;{</font></tt></b></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#FFCCCC" NOSAVE ><tr><td><tt><font color="#993399"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</b> //START Code of Ctor of an eoOneMaxInit object</font></tt><br><tt><font color="#993399"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</b> //END&nbsp;&nbsp;&nbsp; Code of Ctor of an eoOneMaxInit object</font></tt></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#CCCCCC" NOSAVE ><tr><td><b><tt><font color="#993399">&nbsp;}</font></tt></b><p><tt><font color="#993399"><b>&nbsp;</b> /** initialize a genotype</font></tt><br><tt><font color="#993399">&nbsp;&nbsp; *</font></tt><br><tt><font color="#993399">&nbsp;&nbsp; * @param _genotype&nbsp; generallya genotype that has been default-constructed</font></tt><br><tt><font color="#993399">&nbsp;&nbsp; *&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;whatever it contains will be lost</font></tt><br><tt><font color="#993399">&nbsp;&nbsp; */</font></tt><br><b><tt><font color="#993399">&nbsp;void operator()(GenotypeT &amp;_genotype)</font></tt></b><br><b><tt><font color="#993399">&nbsp;{</font></tt></b></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#FFCCCC" NOSAVE ><tr><td><a NAME="operator"></a><tt><font color="#993399"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</b>// START Code of random initialization of an eoOneMax object</font></tt><br><tt><font color="#993399"><b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</b> //END&nbsp;&nbsp;&nbsp; Code of random initialization of an eoOneMax object</font></tt></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#CCCCCC" NOSAVE ><tr><td><tt><font color="#993399"><b>&nbsp;&nbsp;&nbsp;&nbsp; _genotype.invalidate();&nbsp;&nbsp;&nbsp;&nbsp;</b>// IMPORTANT in case the _genotype is old</font></tt><br><b><tt><font color="#993399">&nbsp;}</font></tt></b><p><b><tt><font color="#993399">private:</font></tt></b></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#FFCCCC" NOSAVE ><tr><td><a NAME="data"></a><tt><font color="#993399">// START Private dataof an eoOneMaxInit object</font></tt><br><tt><font color="#993399"><b>&nbsp;</b> //&nbsp; varType anyVariable;&nbsp;&nbsp;&nbsp;// for example ...</font></tt><br><tt><font color="#993399">// END&nbsp;&nbsp;&nbsp; Private data ofan eoOneMaxInit object</font></tt></td></tr></table><table BORDER=0 CELLSPACING=0 COLS=1 WIDTH="100%" BGCOLOR="#CCCCCC" NOSAVE ><tr><td><b><tt><font color="#993399">};</font></tt></b><p><b><tt><font color="#993399">#endif</font></tt></b></td></tr></table><hr WIDTH="100%"><a href="eoLesson5.html">Back to Lesson 5</a> - <a href="eoTutorial.html">Tutorialmain page </a>- <a href="eoTopDown.html">Top-Down page</a> - <a href="eoBottomUp.html">Bottom-uppage</a> - <a href="eoProgramming.html">Programming hints</a> - <font face="Arial,Helvetica"><a href="doc/html/index.html">EOdocumentation</a></font><hr><address><a href="mailto:marc.schoenauer@inria.fr">Marc Schoenauer</a></address><br><!-- Created: Nov 2000 --><!-- hhmts start -->Last modified: Fri May3 06:17:21 2002<!-- hhmts end --></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -