<!-- HTML header for doxygen 1.8.3.1--> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.6"/> <title>Templates -- Meow: meowpp/oo/Register_Implement.h Source File</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="navtree.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="resize.js"></script> <script type="text/javascript" src="navtree.js"></script> <script type="text/javascript"> $(document).ready(initResizable); $(window).load(resizeHeight); </script> <link href="stylesheet.css" rel="stylesheet" type="text/css" /> <link href="custom.css" rel="stylesheet" type="text/css"/> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectlogo"><img alt="Logo" src="logo.png"/></td> <td style="padding-left: 0.5em;"> <div id="projectname">Templates -- Meow  <span id="projectnumber">1.1.4</span> </div> <div id="projectbrief">A C++ template contains kinds of interesting classes and functions</div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.6 --> </div><!-- top --> <div id="side-nav" class="ui-resizable side-nav-resizable"> <div id="nav-tree"> <div id="nav-tree-contents"> <div id="nav-sync" class="sync"></div> </div> </div> <div id="splitbar" style="-moz-user-select:none;" class="ui-resizable-handle"> </div> </div> <script type="text/javascript"> $(document).ready(function(){initNavTree('Register__Implement_8h_source.html','');}); </script> <div id="doc-content"> <div class="header"> <div class="headertitle"> <div class="title">Register_Implement.h</div> </div> </div><!--header--> <div class="contents"> <a href="Register__Implement_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="preprocessor">#ifndef REGISTER_IMPLEMENT_H_</span></div> <div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="preprocessor"></span><span class="preprocessor">#define REGISTER_IMPLEMENT_H_</span></div> <div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="preprocessor">#include <map></span></div> <div class="line"><a name="l00005"></a><span class="lineno"> 5</span> </div> <div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="keyword">namespace </span>meow{</div> <div class="line"><a name="l00007"></a><span class="lineno"><a class="line" href="classmeow_1_1ImplementInterface.html"> 7</a></span>  <span class="keyword">template</span><<span class="keyword">class</span> T> <span class="keyword">class </span><a class="code" href="classmeow_1_1ImplementInterface.html">ImplementInterface</a>{</div> <div class="line"><a name="l00008"></a><span class="lineno"> 8</span>  <span class="keyword">private</span>:</div> <div class="line"><a name="l00009"></a><span class="lineno"> 9</span>  T identify_;</div> <div class="line"><a name="l00010"></a><span class="lineno"> 10</span>  <span class="keyword">protected</span>:</div> <div class="line"><a name="l00011"></a><span class="lineno"><a class="line" href="classmeow_1_1ImplementInterface.html#ae9a6b17845cc8b850fb5a97e706396e0"> 11</a></span>  <a class="code" href="classmeow_1_1ImplementInterface.html#ae9a6b17845cc8b850fb5a97e706396e0">ImplementInterface</a>(T <span class="keyword">const</span>& <span class="keywordtype">id</span>): identify_(id) { }</div> <div class="line"><a name="l00012"></a><span class="lineno"> 12</span>  <span class="keyword">public</span>:</div> <div class="line"><a name="l00013"></a><span class="lineno"><a class="line" href="classmeow_1_1ImplementInterface.html#af9de10bbb43c81258baeecccbc3f1431"> 13</a></span>  T <span class="keyword">const</span>& <a class="code" href="classmeow_1_1ImplementInterface.html#af9de10bbb43c81258baeecccbc3f1431">identify</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> identify_; }</div> <div class="line"><a name="l00014"></a><span class="lineno"><a class="line" href="classmeow_1_1ImplementInterface.html#a59ffd1b1c11642588d1ecb0a716ef48a"> 14</a></span>  <span class="keyword">virtual</span> <a class="code" href="classmeow_1_1ImplementInterface.html#a59ffd1b1c11642588d1ecb0a716ef48a">~ImplementInterface</a>(){ }</div> <div class="line"><a name="l00015"></a><span class="lineno"> 15</span>  };</div> <div class="line"><a name="l00016"></a><span class="lineno"> 16</span>  <span class="comment">//</span></div> <div class="line"><a name="l00017"></a><span class="lineno"><a class="line" href="classmeow_1_1RegisterInterface.html"> 17</a></span>  <span class="keyword">template</span><<span class="keyword">class</span> T> <span class="keyword">class </span><a class="code" href="classmeow_1_1RegisterInterface.html">RegisterInterface</a>{</div> <div class="line"><a name="l00018"></a><span class="lineno"> 18</span>  <span class="keyword">private</span>:</div> <div class="line"><a name="l00019"></a><span class="lineno"> 19</span>  std::map<T, ImplementInterface<T>*> implements;</div> <div class="line"><a name="l00020"></a><span class="lineno"> 20</span>  <span class="keyword">protected</span>:</div> <div class="line"><a name="l00021"></a><span class="lineno"> 21</span>  <a class="code" href="classmeow_1_1RegisterInterface.html#ac18ca2aeac72ece9f85c3632436426d5">RegisterInterface</a>();</div> <div class="line"><a name="l00022"></a><span class="lineno"> 22</span>  <span class="keyword">public</span>:</div> <div class="line"><a name="l00023"></a><span class="lineno"> 23</span>  <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="classmeow_1_1RegisterInterface.html#ab94831367f6f8226f668886ceaa99b2c">regImplement</a>(<a class="code" href="classmeow_1_1ImplementInterface.html">ImplementInterface<T></a>*imp);</div> <div class="line"><a name="l00024"></a><span class="lineno"> 24</span>  <span class="keyword">virtual</span> <a class="code" href="classmeow_1_1ImplementInterface.html">ImplementInterface<T></a>*<a class="code" href="classmeow_1_1RegisterInterface.html#aa0f73c861a4b917085eed724e61661cf">getImplement</a>(T <span class="keyword">const</span>& identify);</div> <div class="line"><a name="l00025"></a><span class="lineno"><a class="line" href="classmeow_1_1RegisterInterface.html#affce62cb4c25e89a55fe3a3718c6dd3e"> 25</a></span>  <span class="keyword">virtual</span> <a class="code" href="classmeow_1_1RegisterInterface.html#affce62cb4c25e89a55fe3a3718c6dd3e">~RegisterInterface</a>(){ }</div> <div class="line"><a name="l00026"></a><span class="lineno"> 26</span>  };</div> <div class="line"><a name="l00027"></a><span class="lineno"> 27</span> }</div> <div class="line"><a name="l00028"></a><span class="lineno"> 28</span> </div> <div class="line"><a name="l00029"></a><span class="lineno"> 29</span> <span class="preprocessor">#include "<a class="code" href="Register__Implement_8hpp.html">Register_Implement.hpp</a>"</span></div> <div class="line"><a name="l00030"></a><span class="lineno"> 30</span> </div> <div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="preprocessor">#endif // REGISTER_IMPLEMENT_H_</span></div> <div class="ttc" id="Register__Implement_8hpp_html"><div class="ttname"><a href="Register__Implement_8hpp.html">Register_Implement.hpp</a></div></div> <div class="ttc" id="classmeow_1_1RegisterInterface_html_aa0f73c861a4b917085eed724e61661cf"><div class="ttname"><a href="classmeow_1_1RegisterInterface.html#aa0f73c861a4b917085eed724e61661cf">meow::RegisterInterface::getImplement</a></div><div class="ttdeci">virtual ImplementInterface< T > * getImplement(T const &identify)</div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8hpp_source.html#l00016">Register_Implement.hpp:16</a></div></div> <div class="ttc" id="classmeow_1_1RegisterInterface_html_ac18ca2aeac72ece9f85c3632436426d5"><div class="ttname"><a href="classmeow_1_1RegisterInterface.html#ac18ca2aeac72ece9f85c3632436426d5">meow::RegisterInterface::RegisterInterface</a></div><div class="ttdeci">RegisterInterface()</div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8hpp_source.html#l00005">Register_Implement.hpp:5</a></div></div> <div class="ttc" id="classmeow_1_1ImplementInterface_html"><div class="ttname"><a href="classmeow_1_1ImplementInterface.html">meow::ImplementInterface</a></div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8h_source.html#l00007">Register_Implement.h:7</a></div></div> <div class="ttc" id="classmeow_1_1ImplementInterface_html_ae9a6b17845cc8b850fb5a97e706396e0"><div class="ttname"><a href="classmeow_1_1ImplementInterface.html#ae9a6b17845cc8b850fb5a97e706396e0">meow::ImplementInterface::ImplementInterface</a></div><div class="ttdeci">ImplementInterface(T const &id)</div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8h_source.html#l00011">Register_Implement.h:11</a></div></div> <div class="ttc" id="classmeow_1_1RegisterInterface_html_affce62cb4c25e89a55fe3a3718c6dd3e"><div class="ttname"><a href="classmeow_1_1RegisterInterface.html#affce62cb4c25e89a55fe3a3718c6dd3e">meow::RegisterInterface::~RegisterInterface</a></div><div class="ttdeci">virtual ~RegisterInterface()</div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8h_source.html#l00025">Register_Implement.h:25</a></div></div> <div class="ttc" id="classmeow_1_1RegisterInterface_html_ab94831367f6f8226f668886ceaa99b2c"><div class="ttname"><a href="classmeow_1_1RegisterInterface.html#ab94831367f6f8226f668886ceaa99b2c">meow::RegisterInterface::regImplement</a></div><div class="ttdeci">virtual bool regImplement(ImplementInterface< T > *imp)</div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8hpp_source.html#l00007">Register_Implement.hpp:7</a></div></div> <div class="ttc" id="classmeow_1_1ImplementInterface_html_af9de10bbb43c81258baeecccbc3f1431"><div class="ttname"><a href="classmeow_1_1ImplementInterface.html#af9de10bbb43c81258baeecccbc3f1431">meow::ImplementInterface::identify</a></div><div class="ttdeci">T const & identify() const </div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8h_source.html#l00013">Register_Implement.h:13</a></div></div> <div class="ttc" id="classmeow_1_1ImplementInterface_html_a59ffd1b1c11642588d1ecb0a716ef48a"><div class="ttname"><a href="classmeow_1_1ImplementInterface.html#a59ffd1b1c11642588d1ecb0a716ef48a">meow::ImplementInterface::~ImplementInterface</a></div><div class="ttdeci">virtual ~ImplementInterface()</div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8h_source.html#l00014">Register_Implement.h:14</a></div></div> <div class="ttc" id="classmeow_1_1RegisterInterface_html"><div class="ttname"><a href="classmeow_1_1RegisterInterface.html">meow::RegisterInterface</a></div><div class="ttdef"><b>Definition:</b> <a href="Register__Implement_8h_source.html#l00017">Register_Implement.h:17</a></div></div> </div><!-- fragment --></div><!-- contents --> </div><!-- doc-content --> <!-- HTML footer for doxygen 1.8.3.1--> <!-- start footer part --> <div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> <ul> <li class="navelem"><a class="el" href="dir_92fecd8d02dd5e7a67429447fdf0f60f.html">meowpp</a></li><li class="navelem"><a class="el" href="dir_540a4c8f2977878a343351220ffba92b.html">oo</a></li><li class="navelem"><a class="el" href="Register__Implement_8h.html">Register_Implement.h</a></li> <li class="footer">Generated on Mon Jun 23 2014 18:37:27 for Templates -- Meow by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.6 </li> </ul> </div> </body> </html>