1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
---|
2 | <html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> |
---|
3 | <title>mixpp: itppconf.h Source File</title> |
---|
4 | <link href="doxygen.css" rel="stylesheet" type="text/css"> |
---|
5 | <link href="tabs.css" rel="stylesheet" type="text/css"> |
---|
6 | </head><body> |
---|
7 | <!-- Generated by Doxygen 1.5.6 --> |
---|
8 | <div class="navigation" id="top"> |
---|
9 | <div class="tabs"> |
---|
10 | <ul> |
---|
11 | <li><a href="index.html"><span>Main Page</span></a></li> |
---|
12 | <li><a href="pages.html"><span>Related Pages</span></a></li> |
---|
13 | <li><a href="modules.html"><span>Modules</span></a></li> |
---|
14 | <li><a href="namespaces.html"><span>Namespaces</span></a></li> |
---|
15 | <li><a href="classes.html"><span>Classes</span></a></li> |
---|
16 | <li class="current"><a href="files.html"><span>Files</span></a></li> |
---|
17 | </ul> |
---|
18 | </div> |
---|
19 | <h1>itppconf.h</h1><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#include <libconfig.h++></span> |
---|
20 | <a name="l00002"></a>00002 <span class="preprocessor">#include <itpp/itbase.h></span> |
---|
21 | <a name="l00003"></a>00003 |
---|
22 | <a name="l00004"></a>00004 <span class="preprocessor">#ifndef ITPPCONF</span> |
---|
23 | <a name="l00005"></a>00005 <span class="preprocessor"></span><span class="preprocessor">#define ITPPCONF</span> |
---|
24 | <a name="l00006"></a>00006 <span class="preprocessor"></span> |
---|
25 | <a name="l00007"></a>00007 <span class="keyword">using namespace </span>libconfig; |
---|
26 | <a name="l00008"></a>00008 <span class="keyword">using namespace </span>bdm; |
---|
27 | <a name="l00009"></a>00009 |
---|
28 | <a name="l00010"></a>00010 vec getVec(Setting &S){ |
---|
29 | <a name="l00011"></a>00011 vec tmp; |
---|
30 | <a name="l00012"></a>00012 <span class="keywordtype">int</span> len; |
---|
31 | <a name="l00013"></a>00013 Setting::Type T=S.getType(); |
---|
32 | <a name="l00014"></a>00014 <span class="keywordflow">if</span>(T==Setting::TypeArray) { |
---|
33 | <a name="l00015"></a>00015 len = S.getLength(); |
---|
34 | <a name="l00016"></a>00016 tmp.set_length(len); |
---|
35 | <a name="l00017"></a>00017 <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=0; i<len;i++){ |
---|
36 | <a name="l00018"></a>00018 <span class="keywordflow">switch</span> (S[i].getType()) { |
---|
37 | <a name="l00019"></a>00019 <span class="keywordflow">case</span> Setting::TypeFloat : |
---|
38 | <a name="l00020"></a>00020 tmp[i]=double(S[i]);<span class="keywordflow">break</span>; |
---|
39 | <a name="l00021"></a>00021 <span class="keywordflow">case</span> Setting::TypeInt : |
---|
40 | <a name="l00022"></a>00022 tmp[i]=int(S[i]);<span class="keywordflow">break</span>; |
---|
41 | <a name="l00023"></a>00023 <span class="keywordflow">case</span> Setting::TypeBoolean : |
---|
42 | <a name="l00024"></a>00024 tmp[i]=bool(S[i]);<span class="keywordflow">break</span>; |
---|
43 | <a name="l00025"></a>00025 } |
---|
44 | <a name="l00026"></a>00026 } |
---|
45 | <a name="l00027"></a>00027 } |
---|
46 | <a name="l00028"></a>00028 <span class="keywordflow">return</span> tmp; |
---|
47 | <a name="l00029"></a>00029 } |
---|
48 | <a name="l00030"></a>00030 |
---|
49 | <a name="l00031"></a>00031 vec xxx(){<span class="keywordflow">return</span> vec_1(3.2);} |
---|
50 | <a name="l00032"></a>00032 |
---|
51 | <a name="l00033"></a>00033 <span class="preprocessor">#endif ITPPCONF</span> |
---|
52 | </pre></div></div> |
---|
53 | <hr size="1"><address style="text-align: right;"><small>Generated on Wed Feb 11 23:33:55 2009 for mixpp by |
---|
54 | <a href="http://www.doxygen.org/index.html"> |
---|
55 | <img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address> |
---|
56 | </body> |
---|
57 | </html> |
---|