Sophie

Sophie

distrib > Mandriva > 2010.1 > x86_64 > by-pkgid > aaf33964de706a538481c929c1da6a44 > files > 4243

faust-doc-0.9.10-5mdv2010.1.x86_64.rpm

<!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"/>
<title>FAUST compiler: labels.cpp File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.6.3 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>File&nbsp;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>labels.cpp File Reference</h1><code>#include &quot;<a class="el" href="labels_8cpp_source.html">labels.hh</a>&quot;</code><br/>
<code>#include &quot;<a class="el" href="tlib_8hh_source.html">tlib.hh</a>&quot;</code><br/>
<code>#include &quot;<a class="el" href="boxes_8hh_source.html">boxes.hh</a>&quot;</code><br/>
<code>#include &quot;<a class="el" href="signals_8hh_source.html">signals.hh</a>&quot;</code><br/>
<div class="dynheader">
Include dependency graph for labels.cpp:</div>
<div class="dynsection">
</div>
<div class="dynheader">
This graph shows which files directly or indirectly include this file:</div>
<div class="dynsection">
</div>

<p><a href="labels_8cpp_source.html">Go to the source code of this file.</a></p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td colspan="2"><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a0e3389d777f9a0e89e85123a7ce91976">pathRoot</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a29a3dea1e6ab4039ba7da6dda9ef1a7c">isPathRoot</a> (<a class="el" href="classCTree.html">Tree</a> t)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#ad33d38970d9445fb1a4324ffa0d22537">pathParent</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a5bfedfc5998d42333728c6f60667568a">isPathParent</a> (<a class="el" href="classCTree.html">Tree</a> t)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#aafaf5a475b77126670f0e49d864aac31">pathCurrent</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#ae90fbab193b30fa7b70f8f55ad483956">isPathCurrent</a> (<a class="el" href="classCTree.html">Tree</a> t)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#aea7d5137855b830b140c22a09744f0fe">encodeName</a> (char g, const string &amp;name)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">analyze name for "H:name" | "V:name" etc  <a href="#aea7d5137855b830b140c22a09744f0fe"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a8e07db8682a579529270ae62d5a24ec6">label2path</a> (const char *label)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Analyzes a label and converts it as a path.  <a href="#a8e07db8682a579529270ae62d5a24ec6"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76">concatPath</a> (<a class="el" href="classCTree.html">Tree</a> relpath, <a class="el" href="classCTree.html">Tree</a> abspath)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Concatenate the relative path to the absolute path Note that the relpath is top-down while the abspath is bottom-up.  <a href="#a5f1201c3a38839b6ee81b22c2ddd5a76"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a278d43b52191749283aa8074557cd8af">normalizeLabel</a> (<a class="el" href="classCTree.html">Tree</a> label, <a class="el" href="classCTree.html">Tree</a> path)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a8118f87a9c00e0b0fca7eb97e52bde95">normalizePath</a> (<a class="el" href="classCTree.html">Tree</a> path)</td></tr>
<tr><td colspan="2"><h2>Variables</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSymbol.html">Sym</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a34b0488a5a59c45bc4b66465668fde5d">PATHROOT</a> = symbol (&quot;/&quot;)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Grammar for labels with pathnames ----------------------------------- &lt;label&gt; = &lt;name&gt; | &lt;path&gt; &lt;name&gt; &lt;name&gt; = [^/]+ &lt;path&gt; = &lt;apath&gt; | &lt;rpath&gt; &lt;apath&gt; = '/' | '/' &lt;rpath&gt; &lt;rpath&gt; = (&lt;gname&gt; '/')+ &lt;gname&gt; = ".." | "." | &lt;gtype&gt; &lt;name&gt; &lt;gtype&gt; = "h:" | "H:" | "v:" | V:" | "t:" | "T:".  <a href="#a34b0488a5a59c45bc4b66465668fde5d"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSymbol.html">Sym</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a6736725938d785b87ecc5c1db17a0aeb">PATHPARENT</a> = symbol (&quot;..&quot;)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classSymbol.html">Sym</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="labels_8cpp.html#a550f3e737e9a1d00bdf6624e68d7e230">PATHCURRENT</a> = symbol (&quot;.&quot;)</td></tr>
</table>
<hr/><h2>Function Documentation</h2>
<a class="anchor" id="a5f1201c3a38839b6ee81b22c2ddd5a76"></a><!-- doxytag: member="labels.cpp::concatPath" ref="a5f1201c3a38839b6ee81b22c2ddd5a76" args="(Tree relpath, Tree abspath)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="classCTree.html">Tree</a> concatPath </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>relpath</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>abspath</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Concatenate the relative path to the absolute path Note that the relpath is top-down while the abspath is bottom-up. </p>

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00094">94</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="list_8hh_source.html#l00124">cons()</a>, <a class="el" href="list_8hh_source.html#l00133">hd()</a>, <a class="el" href="list_8hh_source.html#l00138">isList()</a>, <a class="el" href="list_8hh_source.html#l00137">isNil()</a>, <a class="el" href="labels_8cpp_source.html#l00028">isPathCurrent()</a>, <a class="el" href="labels_8cpp_source.html#l00024">isPathParent()</a>, <a class="el" href="labels_8cpp_source.html#l00020">isPathRoot()</a>, <a class="el" href="list_8cpp_source.html#l00116">nil</a>, and <a class="el" href="list_8hh_source.html#l00134">tl()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00119">normalizeLabel()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00095"></a>00095 {
<a name="l00096"></a>00096     <span class="keywordflow">if</span> (<a class="code" href="list_8hh.html#a8bdd73641276e0c0f999f504348eacc1">isList</a>(relpath)) {
<a name="l00097"></a>00097         <a class="code" href="classCTree.html" title="A CTree = (Node x [CTree]) is a Node associated with a list of subtrees called branches...">Tree</a> head = <a class="code" href="list_8hh.html#a067ad6f83087b420a1c44e48e56be389">hd</a>(relpath);
<a name="l00098"></a>00098         <span class="keywordflow">if</span> (<a class="code" href="labels_8cpp.html#a29a3dea1e6ab4039ba7da6dda9ef1a7c">isPathRoot</a>(head)) {
<a name="l00099"></a>00099             <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76" title="Concatenate the relative path to the absolute path Note that the relpath is top-down...">concatPath</a>(<a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(relpath), <a class="code" href="list_8cpp.html#a538b704dd07794b7237108f1917c471e">nil</a>);
<a name="l00100"></a>00100         } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="labels_8cpp.html#a5bfedfc5998d42333728c6f60667568a">isPathParent</a>(head)) {
<a name="l00101"></a>00101             <span class="keywordflow">if</span> (!<a class="code" href="list_8hh.html#a8bdd73641276e0c0f999f504348eacc1">isList</a>(abspath)) { 
<a name="l00102"></a>00102                 <span class="comment">//cerr &lt;&lt; &quot;abspath : &quot; &lt;&lt; *abspath &lt;&lt; endl; </span>
<a name="l00103"></a>00103                 <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76" title="Concatenate the relative path to the absolute path Note that the relpath is top-down...">concatPath</a>(<a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(relpath), <a class="code" href="list_8hh.html#a067ad6f83087b420a1c44e48e56be389">hd</a>(relpath));
<a name="l00104"></a>00104             } <span class="keywordflow">else</span> {
<a name="l00105"></a>00105                 <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76" title="Concatenate the relative path to the absolute path Note that the relpath is top-down...">concatPath</a>(<a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(relpath), <a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(abspath));
<a name="l00106"></a>00106             }
<a name="l00107"></a>00107         } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (<a class="code" href="labels_8cpp.html#ae90fbab193b30fa7b70f8f55ad483956">isPathCurrent</a>(head)) {
<a name="l00108"></a>00108             <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76" title="Concatenate the relative path to the absolute path Note that the relpath is top-down...">concatPath</a>(<a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(relpath), abspath);
<a name="l00109"></a>00109         } <span class="keywordflow">else</span> {
<a name="l00110"></a>00110             <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76" title="Concatenate the relative path to the absolute path Note that the relpath is top-down...">concatPath</a>(<a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(relpath), <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(head,abspath));
<a name="l00111"></a>00111         }
<a name="l00112"></a>00112     } <span class="keywordflow">else</span> {
<a name="l00113"></a>00113         assert(<a class="code" href="list_8hh.html#a2569c3a07bbbfa55e0afde62de62aeec">isNil</a>(relpath));
<a name="l00114"></a>00114         <span class="keywordflow">return</span> abspath;
<a name="l00115"></a>00115     }
<a name="l00116"></a>00116 }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="aea7d5137855b830b140c22a09744f0fe"></a><!-- doxytag: member="labels.cpp::encodeName" ref="aea7d5137855b830b140c22a09744f0fe" args="(char g, const string &amp;name)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="classCTree.html">Tree</a> encodeName </td>
          <td>(</td>
          <td class="paramtype">char&nbsp;</td>
          <td class="paramname"> <em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const string &amp;&nbsp;</td>
          <td class="paramname"> <em>name</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>analyze name for "H:name" | "V:name" etc </p>

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00036">36</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="list_8hh_source.html#l00124">cons()</a>, and <a class="el" href="tree_8hh_source.html#l00173">tree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00057">label2path()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00037"></a>00037 {
<a name="l00038"></a>00038     <span class="keywordflow">switch</span> (g) {
<a name="l00039"></a>00039         <span class="keywordflow">case</span> <span class="charliteral">&#39;v&#39;</span>:
<a name="l00040"></a>00040         <span class="keywordflow">case</span> <span class="charliteral">&#39;V&#39;</span>: <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(0), <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="symbol_8hh.html#a8243134fbbd9d924ebbb3f833922e310" title="Returns the name of a symbol.">name</a>));
<a name="l00041"></a>00041 
<a name="l00042"></a>00042         <span class="keywordflow">case</span> <span class="charliteral">&#39;h&#39;</span>:
<a name="l00043"></a>00043         <span class="keywordflow">case</span> <span class="charliteral">&#39;H&#39;</span>: <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(1), <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="symbol_8hh.html#a8243134fbbd9d924ebbb3f833922e310" title="Returns the name of a symbol.">name</a>));
<a name="l00044"></a>00044 
<a name="l00045"></a>00045         <span class="keywordflow">case</span> <span class="charliteral">&#39;t&#39;</span>:
<a name="l00046"></a>00046         <span class="keywordflow">case</span> <span class="charliteral">&#39;T&#39;</span>: <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(2), <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="symbol_8hh.html#a8243134fbbd9d924ebbb3f833922e310" title="Returns the name of a symbol.">name</a>));
<a name="l00047"></a>00047 
<a name="l00048"></a>00048         <span class="keywordflow">default</span> : <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(0), <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="symbol_8hh.html#a8243134fbbd9d924ebbb3f833922e310" title="Returns the name of a symbol.">name</a>));
<a name="l00049"></a>00049     }
<a name="l00050"></a>00050 }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="ae90fbab193b30fa7b70f8f55ad483956"></a><!-- doxytag: member="labels.cpp::isPathCurrent" ref="ae90fbab193b30fa7b70f8f55ad483956" args="(Tree t)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool isPathCurrent </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>t</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00028">28</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="tree_8cpp_source.html#l00319">isTree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00094">concatPath()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00028"></a>00028 { <span class="keywordflow">return</span> <a class="code" href="tree_8cpp.html#a06be972e0437c7c09e8a1274586fe176">isTree</a>(t, <a class="code" href="labels_8cpp.html#a550f3e737e9a1d00bdf6624e68d7e230">PATHCURRENT</a>); }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="a5bfedfc5998d42333728c6f60667568a"></a><!-- doxytag: member="labels.cpp::isPathParent" ref="a5bfedfc5998d42333728c6f60667568a" args="(Tree t)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool isPathParent </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>t</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00024">24</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="tree_8cpp_source.html#l00319">isTree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00094">concatPath()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00024"></a>00024 { <span class="keywordflow">return</span> <a class="code" href="tree_8cpp.html#a06be972e0437c7c09e8a1274586fe176">isTree</a>(t, <a class="code" href="labels_8cpp.html#a6736725938d785b87ecc5c1db17a0aeb">PATHPARENT</a>); }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="a29a3dea1e6ab4039ba7da6dda9ef1a7c"></a><!-- doxytag: member="labels.cpp::isPathRoot" ref="a29a3dea1e6ab4039ba7da6dda9ef1a7c" args="(Tree t)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool isPathRoot </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>t</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00020">20</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="tree_8cpp_source.html#l00319">isTree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00094">concatPath()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00020"></a>00020 { <span class="keywordflow">return</span> <a class="code" href="tree_8cpp.html#a06be972e0437c7c09e8a1274586fe176">isTree</a>(t, <a class="code" href="labels_8cpp.html#a34b0488a5a59c45bc4b66465668fde5d" title="Grammar for labels with pathnames ----------------------------------- &amp;lt;label&amp;gt;...">PATHROOT</a>); }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="a8e07db8682a579529270ae62d5a24ec6"></a><!-- doxytag: member="labels.cpp::label2path" ref="a8e07db8682a579529270ae62d5a24ec6" args="(const char *label)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="classCTree.html">Tree</a> label2path </td>
          <td>(</td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>label</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Analyzes a label and converts it as a path. </p>

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00057">57</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="list_8hh_source.html#l00124">cons()</a>, <a class="el" href="labels_8cpp_source.html#l00036">encodeName()</a>, <a class="el" href="list_8cpp_source.html#l00116">nil</a>, <a class="el" href="labels_8cpp_source.html#l00023">pathParent()</a>, <a class="el" href="labels_8cpp_source.html#l00019">pathRoot()</a>, and <a class="el" href="tree_8hh_source.html#l00173">tree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00119">normalizeLabel()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00058"></a>00058 {
<a name="l00059"></a>00059     <span class="keywordflow">if</span> (label[0] == 0) {
<a name="l00060"></a>00060         <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<span class="stringliteral">&quot;&quot;</span>), <a class="code" href="list_8cpp.html#a538b704dd07794b7237108f1917c471e">nil</a>);
<a name="l00061"></a>00061 
<a name="l00062"></a>00062     } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (label[0] == <span class="charliteral">&#39;/&#39;</span>) {
<a name="l00063"></a>00063         <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="labels_8cpp.html#a0e3389d777f9a0e89e85123a7ce91976">pathRoot</a>(), <a class="code" href="labels_8cpp.html#a8e07db8682a579529270ae62d5a24ec6" title="Analyzes a label and converts it as a path.">label2path</a>(&amp;label[1]));
<a name="l00064"></a>00064 
<a name="l00065"></a>00065     } <span class="keywordflow">else</span> <span class="keywordflow">if</span> ((label[0] == <span class="charliteral">&#39;.&#39;</span>) &amp;&amp; (label[1] == <span class="charliteral">&#39;/&#39;</span>)) {
<a name="l00066"></a>00066         <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a8e07db8682a579529270ae62d5a24ec6" title="Analyzes a label and converts it as a path.">label2path</a>(&amp;label[2]);
<a name="l00067"></a>00067 
<a name="l00068"></a>00068     } <span class="keywordflow">else</span> <span class="keywordflow">if</span> ((label[0] == <span class="charliteral">&#39;.&#39;</span>) &amp;&amp; (label[1] == <span class="charliteral">&#39;.&#39;</span>) &amp;&amp; (label[2] == <span class="charliteral">&#39;/&#39;</span>)) {
<a name="l00069"></a>00069         <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="labels_8cpp.html#ad33d38970d9445fb1a4324ffa0d22537">pathParent</a>(), <a class="code" href="labels_8cpp.html#a8e07db8682a579529270ae62d5a24ec6" title="Analyzes a label and converts it as a path.">label2path</a>(&amp;label[3]));
<a name="l00070"></a>00070 
<a name="l00071"></a>00071     } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (label[1] == <span class="charliteral">&#39;:&#39;</span>) {
<a name="l00072"></a>00072         <span class="keywordtype">char</span>    g = label[0];
<a name="l00073"></a>00073         <span class="keywordtype">string</span>  s;
<a name="l00074"></a>00074         <span class="keywordtype">int</span>     i = 2;
<a name="l00075"></a>00075         <span class="keywordflow">while</span> ((label[i] != 0) &amp;&amp; (label[i] != <span class="charliteral">&#39;/&#39;</span>)) {
<a name="l00076"></a>00076             s.push_back(label[i]);
<a name="l00077"></a>00077             i++;
<a name="l00078"></a>00078         }
<a name="l00079"></a>00079         <span class="keywordflow">if</span> (label[i] == <span class="charliteral">&#39;/&#39;</span>) i++;
<a name="l00080"></a>00080         <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="labels_8cpp.html#aea7d5137855b830b140c22a09744f0fe" title="analyze name for &amp;quot;H:name&amp;quot; | &amp;quot;V:name&amp;quot; etc">encodeName</a>(g,s), <a class="code" href="labels_8cpp.html#a8e07db8682a579529270ae62d5a24ec6" title="Analyzes a label and converts it as a path.">label2path</a>(&amp;label[i]));
<a name="l00081"></a>00081 
<a name="l00082"></a>00082     } <span class="keywordflow">else</span> {
<a name="l00083"></a>00083         <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(<a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(label),<a class="code" href="list_8cpp.html#a538b704dd07794b7237108f1917c471e">nil</a>);
<a name="l00084"></a>00084     }
<a name="l00085"></a>00085 }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="a278d43b52191749283aa8074557cd8af"></a><!-- doxytag: member="labels.cpp::normalizeLabel" ref="a278d43b52191749283aa8074557cd8af" args="(Tree label, Tree path)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="classCTree.html">Tree</a> normalizeLabel </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>label</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>path</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00119">119</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="labels_8cpp_source.html#l00094">concatPath()</a>, <a class="el" href="list_8hh_source.html#l00124">cons()</a>, <a class="el" href="list_8hh_source.html#l00138">isList()</a>, <a class="el" href="node_8hh_source.html#l00193">isSym()</a>, <a class="el" href="labels_8cpp_source.html#l00057">label2path()</a>, <a class="el" href="symbol_8hh_source.html#l00098">name()</a>, and <a class="el" href="tree_8hh_source.html#l00141">CTree::node()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00132">normalizePath()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00120"></a>00120 {
<a name="l00121"></a>00121     <span class="comment">// we suppose label = &quot;../label&quot; ou &quot;name/label&quot; ou &quot;name&quot;  </span>
<a name="l00122"></a>00122     <span class="comment">//cout &lt;&lt; &quot;Normalize Label &quot; &lt;&lt; *label &lt;&lt; &quot; with path &quot; &lt;&lt; *path &lt;&lt; endl;</span>
<a name="l00123"></a>00123     <span class="keywordflow">if</span> (<a class="code" href="list_8hh.html#a8bdd73641276e0c0f999f504348eacc1">isList</a>(label)) {
<a name="l00124"></a>00124         <span class="keywordflow">return</span> <a class="code" href="list_8hh.html#ae1ed153946fcfc025009c6d9c9c40bee">cons</a>(label, path);
<a name="l00125"></a>00125     } <span class="keywordflow">else</span> {
<a name="l00126"></a>00126         <a class="code" href="classSymbol.html" title="Symbols are unique objects with a name stored in a hash table.">Sym</a> s;
<a name="l00127"></a>00127         assert (<a class="code" href="node_8hh.html#ab714e75c43d570297ff54578dc7e9ce3">isSym</a>(label-&gt;<a class="code" href="classCTree.html#a8de786fec095c8304b9ffa7c1c316237" title="return the content of the tree">node</a>(),&amp;s));
<a name="l00128"></a>00128         <span class="keywordflow">return</span> <a class="code" href="labels_8cpp.html#a5f1201c3a38839b6ee81b22c2ddd5a76" title="Concatenate the relative path to the absolute path Note that the relpath is top-down...">concatPath</a>(<a class="code" href="labels_8cpp.html#a8e07db8682a579529270ae62d5a24ec6" title="Analyzes a label and converts it as a path.">label2path</a>(<a class="code" href="symbol_8hh.html#a8243134fbbd9d924ebbb3f833922e310" title="Returns the name of a symbol.">name</a>(s)),path);
<a name="l00129"></a>00129     }
<a name="l00130"></a>00130 }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="a8118f87a9c00e0b0fca7eb97e52bde95"></a><!-- doxytag: member="labels.cpp::normalizePath" ref="a8118f87a9c00e0b0fca7eb97e52bde95" args="(Tree path)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classCTree.html">Tree</a> normalizePath </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classCTree.html">Tree</a>&nbsp;</td>
          <td class="paramname"> <em>path</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00132">132</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="list_8hh_source.html#l00133">hd()</a>, <a class="el" href="list_8hh_source.html#l00137">isNil()</a>, <a class="el" href="labels_8cpp_source.html#l00119">normalizeLabel()</a>, <a class="el" href="labels_8cpp_source.html#l00132">normalizePath()</a>, and <a class="el" href="list_8hh_source.html#l00134">tl()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00132">normalizePath()</a>, and <a class="el" href="propagate_8cpp_source.html#l00196">propagate()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00133"></a>00133 {
<a name="l00134"></a>00134     <span class="comment">//cout &lt;&lt; &quot;Normalize Path [[&quot; &lt;&lt; *path &lt;&lt; &quot;]]&quot; &lt;&lt; endl;</span>
<a name="l00135"></a>00135     <a class="code" href="classCTree.html" title="A CTree = (Node x [CTree]) is a Node associated with a list of subtrees called branches...">Tree</a> npath;
<a name="l00136"></a>00136     <span class="keywordflow">if</span> (<a class="code" href="list_8hh.html#a2569c3a07bbbfa55e0afde62de62aeec">isNil</a>(path)) {
<a name="l00137"></a>00137         npath = path;
<a name="l00138"></a>00138     } <span class="keywordflow">else</span> {
<a name="l00139"></a>00139         npath = <a class="code" href="labels_8cpp.html#a278d43b52191749283aa8074557cd8af">normalizeLabel</a>(<a class="code" href="list_8hh.html#a067ad6f83087b420a1c44e48e56be389">hd</a>(path), <a class="code" href="labels_8cpp.html#a8118f87a9c00e0b0fca7eb97e52bde95">normalizePath</a>(<a class="code" href="list_8hh.html#a4075748f5c7156306ec898795313a2e0">tl</a>(path)));
<a name="l00140"></a>00140     }
<a name="l00141"></a>00141     <span class="comment">//cout &lt;&lt; &quot;              -&gt; [[&quot; &lt;&lt; *npath &lt;&lt; &quot;]]&quot; &lt;&lt; endl;</span>
<a name="l00142"></a>00142     <span class="keywordflow">return</span> npath;
<a name="l00143"></a>00143 }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="aafaf5a475b77126670f0e49d864aac31"></a><!-- doxytag: member="labels.cpp::pathCurrent" ref="aafaf5a475b77126670f0e49d864aac31" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classCTree.html">Tree</a> pathCurrent </td>
          <td>(</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00027">27</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="tree_8hh_source.html#l00173">tree()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00027"></a>00027 { <span class="keywordflow">return</span> <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="labels_8cpp.html#a550f3e737e9a1d00bdf6624e68d7e230">PATHCURRENT</a>); }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="ad33d38970d9445fb1a4324ffa0d22537"></a><!-- doxytag: member="labels.cpp::pathParent" ref="ad33d38970d9445fb1a4324ffa0d22537" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classCTree.html">Tree</a> pathParent </td>
          <td>(</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00023">23</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="tree_8hh_source.html#l00173">tree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00057">label2path()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00023"></a>00023 { <span class="keywordflow">return</span> <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="labels_8cpp.html#a6736725938d785b87ecc5c1db17a0aeb">PATHPARENT</a>); }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<a class="anchor" id="a0e3389d777f9a0e89e85123a7ce91976"></a><!-- doxytag: member="labels.cpp::pathRoot" ref="a0e3389d777f9a0e89e85123a7ce91976" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classCTree.html">Tree</a> pathRoot </td>
          <td>(</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00019">19</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

<p>References <a class="el" href="tree_8hh_source.html#l00173">tree()</a>.</p>

<p>Referenced by <a class="el" href="labels_8cpp_source.html#l00057">label2path()</a>.</p>

<p><div class="fragment"><pre class="fragment"><a name="l00019"></a>00019 { <span class="keywordflow">return</span> <a class="code" href="tree_8hh.html#a61c13e9361cfa80bbb3cd6ce60a8f595">tree</a>(<a class="code" href="labels_8cpp.html#a34b0488a5a59c45bc4b66465668fde5d" title="Grammar for labels with pathnames ----------------------------------- &amp;lt;label&amp;gt;...">PATHROOT</a>); }
</pre></div></p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dynsection">
</div>
</p>

</div>
</div>
<hr/><h2>Variable Documentation</h2>
<a class="anchor" id="a550f3e737e9a1d00bdf6624e68d7e230"></a><!-- doxytag: member="labels.cpp::PATHCURRENT" ref="a550f3e737e9a1d00bdf6624e68d7e230" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSymbol.html">Sym</a> <a class="el" href="labels_8cpp.html#a550f3e737e9a1d00bdf6624e68d7e230">PATHCURRENT</a> = symbol (&quot;.&quot;)</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00026">26</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a6736725938d785b87ecc5c1db17a0aeb"></a><!-- doxytag: member="labels.cpp::PATHPARENT" ref="a6736725938d785b87ecc5c1db17a0aeb" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSymbol.html">Sym</a> <a class="el" href="labels_8cpp.html#a6736725938d785b87ecc5c1db17a0aeb">PATHPARENT</a> = symbol (&quot;..&quot;)</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00022">22</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a34b0488a5a59c45bc4b66465668fde5d"></a><!-- doxytag: member="labels.cpp::PATHROOT" ref="a34b0488a5a59c45bc4b66465668fde5d" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classSymbol.html">Sym</a> <a class="el" href="labels_8cpp.html#a34b0488a5a59c45bc4b66465668fde5d">PATHROOT</a> = symbol (&quot;/&quot;)</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Grammar for labels with pathnames ----------------------------------- &lt;label&gt; = &lt;name&gt; | &lt;path&gt; &lt;name&gt; &lt;name&gt; = [^/]+ &lt;path&gt; = &lt;apath&gt; | &lt;rpath&gt; &lt;apath&gt; = '/' | '/' &lt;rpath&gt; &lt;rpath&gt; = (&lt;gname&gt; '/')+ &lt;gname&gt; = ".." | "." | &lt;gtype&gt; &lt;name&gt; &lt;gtype&gt; = "h:" | "H:" | "v:" | V:" | "t:" | "T:". </p>

<p>Definition at line <a class="el" href="labels_8cpp_source.html#l00018">18</a> of file <a class="el" href="labels_8cpp_source.html">labels.cpp</a>.</p>

</div>
</div>
</div>
<hr class="footer"/><address style="text-align: right;"><small>Generated on Thu Apr 29 00:00:07 2010 for FAUST compiler by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
</body>
</html>