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

📄 group__forth__test.html

📁 这个是关于G.726算法的源程序
💻 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>Test - Test code for forth virtual machine</title><link href="doxygen.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.4.4 --><div class="qindex"><a class="qindex" href="index.html">Main&nbsp;Page</a> | <a class="qindex" href="modules.html">Modules</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="annotated.html">Class&nbsp;List</a> | <a class="qindex" href="dirs.html">Directories</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="functions.html">Class&nbsp;Members</a> | <a class="qindex" href="globals.html">File&nbsp;Members</a></div><h1>Test - Test code for forth virtual machine<br><small>[<a class="el" href="group__forth.html">Forth - Forth virtual machine</a>]</small></h1><hr><a name="_details"></a><h2>Detailed Description</h2>This code has been placed in the Public Domain by J.D.Medhurst (a.k.a. Tixy). It may be used, modified and distributed in any manner, without any restriction.<p><table border="0" cellpadding="0" cellspacing="0"><tr><td></td></tr><tr><td colspan="2"><br><h2>Classes</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStdForthIo.html">StdForthIo</a></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">class &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classForthTest.html">ForthTest</a></td></tr><tr><td colspan="2"><br><h2>Defines</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga2">SOURCE_ROOT_PATH</a>&nbsp;&nbsp;&nbsp;&quot;..\\forth\\&quot;</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga3">STRING</a>(string)&nbsp;&nbsp;&nbsp;string</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga4">LINE</a>(string)&nbsp;&nbsp;&nbsp;string &quot;\n&quot;</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga5">COUNTED_STRING</a>(string)&nbsp;&nbsp;&nbsp;(<a class="el" href="group__forth.html#ga2">CHAR</a>*)STRING(string),(sizeof(string)-1)</td></tr><tr><td colspan="2"><br><h2>Functions</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga0">ReadFile</a> (const char *name, void *&amp;address, <a class="el" href="group__integers.html#ga6">uint</a> &amp;size)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga1">TestForth</a> ()</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="group__forth.html#ga0">CELL</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga6">ForthTest::Include</a> (const char *fileName)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="group__forth.html#ga0">CELL</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__forth__test.html#ga7">ForthTest::IncludeLines</a> (const char *fileName)</td></tr></table><hr><h2>Define Documentation</h2><a class="anchor" name="ga2"></a><!-- doxytag: member="forthtest.cpp::SOURCE_ROOT_PATH" ref="ga2" args="" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">#define SOURCE_ROOT_PATH&nbsp;&nbsp;&nbsp;&quot;..\\forth\\&quot;          </td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Path for source code location <p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00022">22</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><a class="anchor" name="ga3"></a><!-- doxytag: member="forthtest.cpp::STRING" ref="ga3" args="(string)" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">#define STRING          </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top">string&nbsp;</td>          <td class="mdname1" valign="top" nowrap>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap>&nbsp;&nbsp;&nbsp;string</td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Macro to include string constants in source which match the width of the <code>CHAR</code> type. <p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00086">86</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><a class="anchor" name="ga4"></a><!-- doxytag: member="forthtest.cpp::LINE" ref="ga4" args="(string)" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">#define LINE          </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top">string&nbsp;</td>          <td class="mdname1" valign="top" nowrap>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap>&nbsp;&nbsp;&nbsp;string &quot;\n&quot;</td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Macro to include a line of text as an in-source constant . <p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00088">88</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><a class="anchor" name="ga5"></a><!-- doxytag: member="forthtest.cpp::COUNTED_STRING" ref="ga5" args="(string)" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">#define COUNTED_STRING          </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top">string&nbsp;</td>          <td class="mdname1" valign="top" nowrap>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap>&nbsp;&nbsp;&nbsp;(<a class="el" href="group__forth.html#ga2">CHAR</a>*)STRING(string),(sizeof(string)-1)</td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Construct counted string arguments in the form <code> (CHAR*)string,(CELL)stringLength </code> <dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>string</em>&nbsp;</td><td>A quoted string, e.g. <code> "A string" </code></td></tr>  </table></dl><p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00183">183</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><hr><h2>Function Documentation</h2><a class="anchor" name="ga0"></a><!-- doxytag: member="forthtest.cpp::ReadFile" ref="ga0" args="(const char *name, void *&amp;address, uint &amp;size)" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">bool ReadFile           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top">const char *&nbsp;</td>          <td class="mdname" nowrap> <em>name</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap>void *&amp;&nbsp;</td>          <td class="mdname" nowrap> <em>address</em>, </td>        </tr>        <tr>          <td class="md" nowrap align="right"></td>          <td class="md"></td>          <td class="md" nowrap><a class="el" href="group__integers.html#ga6">uint</a> &amp;&nbsp;</td>          <td class="mdname" nowrap> <em>size</em></td>        </tr>        <tr>          <td class="md"></td>          <td class="md">)&nbsp;</td>          <td class="md" colspan="2"></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Read a files contents into memory. The file is assumed to contain characters of 8 bit size but they are stored in memory as characters the same size as the <a class="el" href="classForth.html">Forth</a> VM's <code>CHAR</code>. <dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>The file name. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>address</em>&nbsp;</td><td>On success, this is the address of the memory cell containing the read contents. This memory must be freed when it is no longer required. </td></tr>    <tr><td valign="top"></td><td valign="top"><em>size</em>&nbsp;</td><td>On success, this is the number of characters in the file.</td></tr>  </table></dl><dl compact><dt><b>Returns:</b></dt><dd>True, if the read was successful, false otherwise.</dd></dl><p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00056">56</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><a class="anchor" name="ga1"></a><!-- doxytag: member="forthtest.cpp::TestForth" ref="ga1" args="()" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top">void TestForth           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="mdname1" valign="top" nowrap>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Top level test function. Call this to perform all tests.<p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00189">189</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><a class="anchor" name="ga6"></a><!-- doxytag: member="ForthTest::Include" ref="ga6" args="(const char *fileName)" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top"><a class="el" href="group__forth.html#ga0">CELL</a> ForthTest::Include           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top">const char *&nbsp;</td>          <td class="mdname1" valign="top" nowrap> <em>fileName</em>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap><code> [inherited]</code></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Load the contents of a file and <code>EVALUATE</code> it. <dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>fileName</em>&nbsp;</td><td>The name of the file. </td></tr>  </table></dl><dl compact><dt><b>Returns:</b></dt><dd>0 or a forth execption value.</dd></dl><p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00114">114</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><a class="anchor" name="ga7"></a><!-- doxytag: member="ForthTest::IncludeLines" ref="ga7" args="(const char *fileName)" --><p><table class="mdTable" cellpadding="2" cellspacing="0">  <tr>    <td class="mdRow">      <table cellpadding="0" cellspacing="0" border="0">        <tr>          <td class="md" nowrap valign="top"><a class="el" href="group__forth.html#ga0">CELL</a> ForthTest::IncludeLines           </td>          <td class="md" valign="top">(&nbsp;</td>          <td class="md" nowrap valign="top">const char *&nbsp;</td>          <td class="mdname1" valign="top" nowrap> <em>fileName</em>          </td>          <td class="md" valign="top">&nbsp;)&nbsp;</td>          <td class="md" nowrap><code> [inherited]</code></td>        </tr>      </table>    </td>  </tr></table><table cellspacing="5" cellpadding="0" border="0">  <tr>    <td>      &nbsp;    </td>    <td><p>Load the contents of a file and <code>EVALUATE</code> it a line at a time. <dl compact><dt><b>Parameters:</b></dt><dd>  <table border="0" cellspacing="2" cellpadding="0">    <tr><td valign="top"></td><td valign="top"><em>fileName</em>&nbsp;</td><td>The name of the file. </td></tr>  </table></dl><dl compact><dt><b>Returns:</b></dt><dd>0 or a forth execption value.</dd></dl><p>Definition at line <a class="el" href="forthtest_8cpp-source.html#l00129">129</a> of file <a class="el" href="forthtest_8cpp-source.html">forthtest.cpp</a>.    </td>  </tr></table><HR><ADDRESS STYLE="align: right;"><SMALL>Generated by&nbsp; <A HREF="http://www.doxygen.org/index.html"><IMG SRC="doxygen.png" ALT="doxygen" ALIGN="middle" BORDER="0"></A> 1.4.4</SMALL></ADDRESS></BODY></HTML>

⌨️ 快捷键说明

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