doc/TaskJuggler/SyntaxReference.html in taskjuggler-0.0.8 vs doc/TaskJuggler/SyntaxReference.html in taskjuggler-0.0.9
- old
+ new
@@ -143,10 +143,12 @@
<li><a href="../TaskJuggler/AttributeBase.html">TaskJuggler::AttributeBase</a></li>
<li><a href="../TaskJuggler/AttributeDefinition.html">TaskJuggler::AttributeDefinition</a></li>
+ <li><a href="../TaskJuggler/AttributeOverwrite.html">TaskJuggler::AttributeOverwrite</a></li>
+
<li><a href="../TaskJuggler/BatchProcessor.html">TaskJuggler::BatchProcessor</a></li>
<li><a href="../TaskJuggler/Booking.html">TaskJuggler::Booking</a></li>
<li><a href="../TaskJuggler/BookingListAttribute.html">TaskJuggler::BookingListAttribute</a></li>
@@ -221,10 +223,12 @@
<li><a href="../TaskJuggler/HTMLGraphics.html">TaskJuggler::HTMLGraphics</a></li>
<li><a href="../TaskJuggler/Interval.html">TaskJuggler::Interval</a></li>
+ <li><a href="../TaskJuggler/IntervalList.html">TaskJuggler::IntervalList</a></li>
+
<li><a href="../TaskJuggler/IntervalListAttribute.html">TaskJuggler::IntervalListAttribute</a></li>
<li><a href="../TaskJuggler/JobInfo.html">TaskJuggler::JobInfo</a></li>
<li><a href="../TaskJuggler/Journal.html">TaskJuggler::Journal</a></li>
@@ -253,10 +257,12 @@
<li><a href="../TaskJuggler/LogicalExpression.html">TaskJuggler::LogicalExpression</a></li>
<li><a href="../TaskJuggler/LogicalExpressionAttribute.html">TaskJuggler::LogicalExpressionAttribute</a></li>
+ <li><a href="../TaskJuggler/LogicalExpressionListAttribute.html">TaskJuggler::LogicalExpressionListAttribute</a></li>
+
<li><a href="../TaskJuggler/LogicalFlag.html">TaskJuggler::LogicalFlag</a></li>
<li><a href="../TaskJuggler/LogicalFunction.html">TaskJuggler::LogicalFunction</a></li>
<li><a href="../TaskJuggler/LogicalOperation.html">TaskJuggler::LogicalOperation</a></li>
@@ -533,10 +539,12 @@
<li><a href="../TaskJuggler/VimSyntax.html">TaskJuggler::VimSyntax</a></li>
<li><a href="../TaskJuggler/WebServer.html">TaskJuggler::WebServer</a></li>
+ <li><a href="../TaskJuggler/WelcomePage.html">TaskJuggler::WelcomePage</a></li>
+
<li><a href="../TaskJuggler/WorkingHours.html">TaskJuggler::WorkingHours</a></li>
<li><a href="../TaskJuggler/WorkingHoursAttribute.html">TaskJuggler::WorkingHoursAttribute</a></li>
<li><a href="../TaskJuggler/XMLBlob.html">TaskJuggler::XMLBlob</a></li>
@@ -559,12 +567,10 @@
<li><a href="../RuntimeConfig.html">RuntimeConfig</a></li>
<li><a href="../String.html">String</a></li>
- <li><a href="../StringIO.html">StringIO</a></li>
-
</ul>
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
</div>
@@ -645,51 +651,51 @@
<div class="method-source-code"
id="new-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 35</span>
-35: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">manual</span> = <span class="ruby-keyword kw">nil</span>)
-36: <span class="ruby-ivar">@manual</span> = <span class="ruby-identifier">manual</span>
-37: <span class="ruby-ivar">@messageHandler</span> = <span class="ruby-constant">MessageHandler</span>.<span class="ruby-identifier">new</span>(<span class="ruby-keyword kw">true</span>)
-38: <span class="ruby-ivar">@parser</span> = <span class="ruby-constant">ProjectFileParser</span>.<span class="ruby-identifier">new</span>(<span class="ruby-ivar">@messageHandler</span>)
-39: <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">updateParserTables</span>
-40:
-41: <span class="ruby-comment cmt"># This hash stores all documented keywords using the keyword as</span>
-42: <span class="ruby-comment cmt"># index.</span>
-43: <span class="ruby-ivar">@keywords</span> = {}
-44: <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">rule</span><span class="ruby-operator">|</span>
-45: <span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pattern</span><span class="ruby-operator">|</span>
-46: <span class="ruby-comment cmt"># Only patterns that are documented are of interest.</span>
-47: <span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">doc</span>.<span class="ruby-identifier">nil?</span>
-48:
-49: <span class="ruby-comment cmt"># Make sure each keyword is unique.</span>
-50: <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">keyword</span>)
-51: <span class="ruby-identifier">raise</span> <span class="ruby-node">"Multiple patterns have the same keyword #{pattern.keyword}"</span>
-52: <span class="ruby-keyword kw">end</span>
-53:
-54: <span class="ruby-identifier">argDocs</span> = []
-55: <span class="ruby-comment cmt"># Create a new KeywordDocumentation object and fill-in all extracted</span>
-56: <span class="ruby-comment cmt"># values.</span>
-57: <span class="ruby-identifier">kwd</span> = <span class="ruby-constant">KeywordDocumentation</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">rule</span>, <span class="ruby-identifier">pattern</span>,
-58: <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">to_syntax</span>(<span class="ruby-identifier">argDocs</span>, <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>), <span class="ruby-identifier">argDocs</span>,
-59: <span class="ruby-identifier">optionalAttributes</span>(<span class="ruby-identifier">pattern</span>, {}), <span class="ruby-ivar">@manual</span>)
-60: <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">keyword</span>] = <span class="ruby-identifier">kwd</span>
-61: <span class="ruby-keyword kw">end</span>
-62: <span class="ruby-keyword kw">end</span>
-63:
-64: <span class="ruby-comment cmt"># Make sure all references to other keywords are present.</span>
-65: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
-66: <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">crossReference</span>(<span class="ruby-ivar">@keywords</span>, <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>)
-67: <span class="ruby-keyword kw">end</span>
-68:
-69: <span class="ruby-comment cmt"># Figure out whether the keyword describes an inheritable attribute or</span>
-70: <span class="ruby-comment cmt"># not.</span>
-71: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
-72: <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">computeInheritance</span>(<span class="ruby-ivar">@keywords</span>, <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>)
-73: <span class="ruby-keyword kw">end</span>
-74: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 36</span>
+36: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">manual</span> = <span class="ruby-keyword kw">nil</span>)
+37: <span class="ruby-ivar">@manual</span> = <span class="ruby-identifier">manual</span>
+38: <span class="ruby-ivar">@messageHandler</span> = <span class="ruby-constant">MessageHandler</span>.<span class="ruby-identifier">new</span>(<span class="ruby-keyword kw">true</span>)
+39: <span class="ruby-ivar">@parser</span> = <span class="ruby-constant">ProjectFileParser</span>.<span class="ruby-identifier">new</span>(<span class="ruby-ivar">@messageHandler</span>)
+40: <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">updateParserTables</span>
+41:
+42: <span class="ruby-comment cmt"># This hash stores all documented keywords using the keyword as</span>
+43: <span class="ruby-comment cmt"># index.</span>
+44: <span class="ruby-ivar">@keywords</span> = {}
+45: <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">rule</span><span class="ruby-operator">|</span>
+46: <span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pattern</span><span class="ruby-operator">|</span>
+47: <span class="ruby-comment cmt"># Only patterns that are documented are of interest.</span>
+48: <span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">doc</span>.<span class="ruby-identifier">nil?</span>
+49:
+50: <span class="ruby-comment cmt"># Make sure each keyword is unique.</span>
+51: <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">keyword</span>)
+52: <span class="ruby-identifier">raise</span> <span class="ruby-node">"Multiple patterns have the same keyword #{pattern.keyword}"</span>
+53: <span class="ruby-keyword kw">end</span>
+54:
+55: <span class="ruby-identifier">argDocs</span> = []
+56: <span class="ruby-comment cmt"># Create a new KeywordDocumentation object and fill-in all extracted</span>
+57: <span class="ruby-comment cmt"># values.</span>
+58: <span class="ruby-identifier">kwd</span> = <span class="ruby-constant">KeywordDocumentation</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">rule</span>, <span class="ruby-identifier">pattern</span>,
+59: <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">to_syntax</span>(<span class="ruby-identifier">argDocs</span>, <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>), <span class="ruby-identifier">argDocs</span>,
+60: <span class="ruby-identifier">optionalAttributes</span>(<span class="ruby-identifier">pattern</span>, {}), <span class="ruby-ivar">@manual</span>)
+61: <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">keyword</span>] = <span class="ruby-identifier">kwd</span>
+62: <span class="ruby-keyword kw">end</span>
+63: <span class="ruby-keyword kw">end</span>
+64:
+65: <span class="ruby-comment cmt"># Make sure all references to other keywords are present.</span>
+66: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
+67: <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">crossReference</span>(<span class="ruby-ivar">@keywords</span>, <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>)
+68: <span class="ruby-keyword kw">end</span>
+69:
+70: <span class="ruby-comment cmt"># Figure out whether the keyword describes an inheritable attribute or</span>
+71: <span class="ruby-comment cmt"># not.</span>
+72: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
+73: <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">computeInheritance</span>(<span class="ruby-ivar">@keywords</span>, <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>)
+74: <span class="ruby-keyword kw">end</span>
+75: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -725,23 +731,23 @@
<div class="method-source-code"
id="all-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 77</span>
-77: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">all</span>
-78: <span class="ruby-identifier">sorted</span> = <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">keys</span>.<span class="ruby-identifier">sort</span>
-79: <span class="ruby-comment cmt"># Register the neighbours with each keyword so we can use this info in</span>
-80: <span class="ruby-comment cmt"># navigation bars.</span>
-81: <span class="ruby-identifier">pred</span> = <span class="ruby-keyword kw">nil</span>
-82: <span class="ruby-identifier">sorted</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
-83: <span class="ruby-identifier">keyword</span> = <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">kwd</span>]
-84: <span class="ruby-identifier">pred</span>.<span class="ruby-identifier">successor</span> = <span class="ruby-identifier">keyword</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pred</span>
-85: <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">predecessor</span> = <span class="ruby-identifier">pred</span>
-86: <span class="ruby-identifier">pred</span> = <span class="ruby-identifier">keyword</span>
-87: <span class="ruby-keyword kw">end</span>
-88: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 78</span>
+78: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">all</span>
+79: <span class="ruby-identifier">sorted</span> = <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">keys</span>.<span class="ruby-identifier">sort</span>
+80: <span class="ruby-comment cmt"># Register the neighbours with each keyword so we can use this info in</span>
+81: <span class="ruby-comment cmt"># navigation bars.</span>
+82: <span class="ruby-identifier">pred</span> = <span class="ruby-keyword kw">nil</span>
+83: <span class="ruby-identifier">sorted</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
+84: <span class="ruby-identifier">keyword</span> = <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">kwd</span>]
+85: <span class="ruby-identifier">pred</span>.<span class="ruby-identifier">successor</span> = <span class="ruby-identifier">keyword</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pred</span>
+86: <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">predecessor</span> = <span class="ruby-identifier">pred</span>
+87: <span class="ruby-identifier">pred</span> = <span class="ruby-identifier">keyword</span>
+88: <span class="ruby-keyword kw">end</span>
+89: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -771,53 +777,53 @@
<div class="method-source-code"
id="generate-navbar-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 141</span>
-141: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generateHTMLnavbar</span>(<span class="ruby-identifier">directory</span>, <span class="ruby-identifier">keywords</span>)
-142: <span class="ruby-identifier">html</span> = <span class="ruby-constant">HTMLDocument</span>.<span class="ruby-identifier">new</span>
-143: <span class="ruby-identifier">head</span> = <span class="ruby-identifier">html</span>.<span class="ruby-identifier">generateHead</span>(<span class="ruby-value str">'TaskJuggler Syntax Reference Navigator'</span>)
-144: <span class="ruby-identifier">head</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'base'</span>, <span class="ruby-value str">'target'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'display'</span>)
-145: <span class="ruby-identifier">html</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">body</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'body'</span>))
-146:
-147: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'Table Of Contents'</span>, <span class="ruby-value str">'a'</span>, <span class="ruby-value str">'href'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'toc.html'</span>)
-148: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'br'</span>)
-149:
-150: <span class="ruby-identifier">normalizedKeywords</span> = {}
-151: <span class="ruby-identifier">keywords</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">keyword</span><span class="ruby-operator">|</span>
-152: <span class="ruby-identifier">normalizedKeywords</span>[<span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">title</span>] = <span class="ruby-identifier">keyword</span>
-153: <span class="ruby-keyword kw">end</span>
-154: <span class="ruby-identifier">letter</span> = <span class="ruby-keyword kw">nil</span>
-155: <span class="ruby-identifier">letters</span> = []
-156: <span class="ruby-identifier">normalizedKeywords</span>.<span class="ruby-identifier">keys</span>.<span class="ruby-identifier">sort!</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">normalized</span><span class="ruby-operator">|</span>
-157: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">normalized</span>[<span class="ruby-value">0</span>, <span class="ruby-value">1</span>] <span class="ruby-operator">!=</span> <span class="ruby-identifier">letter</span>
-158: <span class="ruby-identifier">letter</span> = <span class="ruby-identifier">normalized</span>[<span class="ruby-value">0</span>, <span class="ruby-value">1</span>]
-159: <span class="ruby-identifier">letters</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">letter</span>
-160: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">h</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'h3'</span>))
-161: <span class="ruby-identifier">h</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">letter</span>.<span class="ruby-identifier">upcase</span>, <span class="ruby-value str">'a'</span>, <span class="ruby-value str">'name'</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">letter</span>)
-162: <span class="ruby-keyword kw">end</span>
-163: <span class="ruby-identifier">keyword</span> = <span class="ruby-identifier">normalizedKeywords</span>[<span class="ruby-identifier">normalized</span>]
-164: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-node">"#{normalized}"</span>, <span class="ruby-value str">'a'</span>,
-165: <span class="ruby-value str">'href'</span> =<span class="ruby-operator">></span> <span class="ruby-node">"#{keyword}.html"</span>)
-166: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'br'</span>)
-167: <span class="ruby-keyword kw">end</span>
-168:
-169: <span class="ruby-identifier">html</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">directory</span> <span class="ruby-operator">+</span> <span class="ruby-value str">'navbar.html'</span>)
-170:
-171: <span class="ruby-identifier">html</span> = <span class="ruby-constant">HTMLDocument</span>.<span class="ruby-identifier">new</span>
-172: <span class="ruby-identifier">head</span> = <span class="ruby-identifier">html</span>.<span class="ruby-identifier">generateHead</span>(<span class="ruby-value str">'TaskJuggler Syntax Reference Navigator'</span>)
-173: <span class="ruby-identifier">head</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'base'</span>, <span class="ruby-value str">'target'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'navigator'</span>)
-174: <span class="ruby-identifier">html</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">body</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'body'</span>))
-175:
-176: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">h3</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'h3'</span>))
-177: <span class="ruby-identifier">letters</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">l</span><span class="ruby-operator">|</span>
-178: <span class="ruby-identifier">h3</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">l</span>.<span class="ruby-identifier">upcase</span>, <span class="ruby-value str">'a'</span>,
-179: <span class="ruby-value str">'href'</span> =<span class="ruby-operator">></span> <span class="ruby-node">"navbar.html##{l}"</span>)
-180: <span class="ruby-keyword kw">end</span>
-181: <span class="ruby-identifier">html</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">directory</span> <span class="ruby-operator">+</span> <span class="ruby-value str">'alphabet.html'</span>)
-182: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 142</span>
+142: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generateHTMLnavbar</span>(<span class="ruby-identifier">directory</span>, <span class="ruby-identifier">keywords</span>)
+143: <span class="ruby-identifier">html</span> = <span class="ruby-constant">HTMLDocument</span>.<span class="ruby-identifier">new</span>
+144: <span class="ruby-identifier">head</span> = <span class="ruby-identifier">html</span>.<span class="ruby-identifier">generateHead</span>(<span class="ruby-value str">'TaskJuggler Syntax Reference Navigator'</span>)
+145: <span class="ruby-identifier">head</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'base'</span>, <span class="ruby-value str">'target'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'display'</span>)
+146: <span class="ruby-identifier">html</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">body</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'body'</span>))
+147:
+148: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'Table Of Contents'</span>, <span class="ruby-value str">'a'</span>, <span class="ruby-value str">'href'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'toc.html'</span>)
+149: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'br'</span>)
+150:
+151: <span class="ruby-identifier">normalizedKeywords</span> = {}
+152: <span class="ruby-identifier">keywords</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">keyword</span><span class="ruby-operator">|</span>
+153: <span class="ruby-identifier">normalizedKeywords</span>[<span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">title</span>] = <span class="ruby-identifier">keyword</span>
+154: <span class="ruby-keyword kw">end</span>
+155: <span class="ruby-identifier">letter</span> = <span class="ruby-keyword kw">nil</span>
+156: <span class="ruby-identifier">letters</span> = []
+157: <span class="ruby-identifier">normalizedKeywords</span>.<span class="ruby-identifier">keys</span>.<span class="ruby-identifier">sort!</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">normalized</span><span class="ruby-operator">|</span>
+158: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">normalized</span>[<span class="ruby-value">0</span>, <span class="ruby-value">1</span>] <span class="ruby-operator">!=</span> <span class="ruby-identifier">letter</span>
+159: <span class="ruby-identifier">letter</span> = <span class="ruby-identifier">normalized</span>[<span class="ruby-value">0</span>, <span class="ruby-value">1</span>]
+160: <span class="ruby-identifier">letters</span> <span class="ruby-operator"><<</span> <span class="ruby-identifier">letter</span>
+161: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">h</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'h3'</span>))
+162: <span class="ruby-identifier">h</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">letter</span>.<span class="ruby-identifier">upcase</span>, <span class="ruby-value str">'a'</span>, <span class="ruby-value str">'name'</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">letter</span>)
+163: <span class="ruby-keyword kw">end</span>
+164: <span class="ruby-identifier">keyword</span> = <span class="ruby-identifier">normalizedKeywords</span>[<span class="ruby-identifier">normalized</span>]
+165: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-node">"#{normalized}"</span>, <span class="ruby-value str">'a'</span>,
+166: <span class="ruby-value str">'href'</span> =<span class="ruby-operator">></span> <span class="ruby-node">"#{keyword}.html"</span>)
+167: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'br'</span>)
+168: <span class="ruby-keyword kw">end</span>
+169:
+170: <span class="ruby-identifier">html</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">directory</span> <span class="ruby-operator">+</span> <span class="ruby-value str">'navbar.html'</span>)
+171:
+172: <span class="ruby-identifier">html</span> = <span class="ruby-constant">HTMLDocument</span>.<span class="ruby-identifier">new</span>
+173: <span class="ruby-identifier">head</span> = <span class="ruby-identifier">html</span>.<span class="ruby-identifier">generateHead</span>(<span class="ruby-value str">'TaskJuggler Syntax Reference Navigator'</span>)
+174: <span class="ruby-identifier">head</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'base'</span>, <span class="ruby-value str">'target'</span> =<span class="ruby-operator">></span> <span class="ruby-value str">'navigator'</span>)
+175: <span class="ruby-identifier">html</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">body</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'body'</span>))
+176:
+177: <span class="ruby-identifier">body</span> <span class="ruby-operator"><<</span> (<span class="ruby-identifier">h3</span> = <span class="ruby-constant">XMLElement</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value str">'h3'</span>))
+178: <span class="ruby-identifier">letters</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">l</span><span class="ruby-operator">|</span>
+179: <span class="ruby-identifier">h3</span> <span class="ruby-operator"><<</span> <span class="ruby-constant">XMLNamedText</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">l</span>.<span class="ruby-identifier">upcase</span>, <span class="ruby-value str">'a'</span>,
+180: <span class="ruby-value str">'href'</span> =<span class="ruby-operator">></span> <span class="ruby-node">"navbar.html##{l}"</span>)
+181: <span class="ruby-keyword kw">end</span>
+182: <span class="ruby-identifier">html</span>.<span class="ruby-identifier">write</span>(<span class="ruby-identifier">directory</span> <span class="ruby-operator">+</span> <span class="ruby-value str">'alphabet.html'</span>)
+183: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -848,18 +854,18 @@
<div class="method-source-code"
id="generate-reference-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 131</span>
-131: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generateHTMLreference</span>(<span class="ruby-identifier">directory</span>, <span class="ruby-identifier">keyword</span>)
-132: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">checkKeyword</span>(<span class="ruby-identifier">keyword</span>)
-133: <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">generateHTML</span>(<span class="ruby-identifier">directory</span>)
-134: <span class="ruby-keyword kw">else</span>
-135: <span class="ruby-value str">''</span>
-136: <span class="ruby-keyword kw">end</span>
-137: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 132</span>
+132: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generateHTMLreference</span>(<span class="ruby-identifier">directory</span>, <span class="ruby-identifier">keyword</span>)
+133: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">checkKeyword</span>(<span class="ruby-identifier">keyword</span>)
+134: <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">generateHTML</span>(<span class="ruby-identifier">directory</span>)
+135: <span class="ruby-keyword kw">else</span>
+136: <span class="ruby-value str">''</span>
+137: <span class="ruby-keyword kw">end</span>
+138: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -886,19 +892,19 @@
<div class="method-source-code"
id="internal-eferences-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 108</span>
-108: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">internalReferences</span>
-109: <span class="ruby-identifier">references</span> = {}
-110: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">keyword</span><span class="ruby-operator">|</span>
-111: (<span class="ruby-identifier">refs</span> = <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">references</span>.<span class="ruby-identifier">uniq</span>).<span class="ruby-identifier">empty?</span> <span class="ruby-operator">||</span>
-112: <span class="ruby-identifier">references</span>[<span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">keyword</span>] = <span class="ruby-identifier">refs</span>
-113: <span class="ruby-keyword kw">end</span>
-114: <span class="ruby-identifier">references</span>
-115: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 109</span>
+109: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">internalReferences</span>
+110: <span class="ruby-identifier">references</span> = {}
+111: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">keyword</span><span class="ruby-operator">|</span>
+112: (<span class="ruby-identifier">refs</span> = <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">references</span>.<span class="ruby-identifier">uniq</span>).<span class="ruby-identifier">empty?</span> <span class="ruby-operator">||</span>
+113: <span class="ruby-identifier">references</span>[<span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">keyword</span>] = <span class="ruby-identifier">refs</span>
+114: <span class="ruby-keyword kw">end</span>
+115: <span class="ruby-identifier">references</span>
+116: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -932,23 +938,23 @@
<div class="method-source-code"
id="table-f-ontents-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 95</span>
- 95: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">tableOfContents</span>(<span class="ruby-identifier">toc</span>, <span class="ruby-identifier">sectionPrefix</span>)
- 96: <span class="ruby-identifier">keywords</span> = <span class="ruby-identifier">all</span>
- 97: <span class="ruby-comment cmt"># Set the chapter name to 'Syntax Reference' with a link to the first</span>
- 98: <span class="ruby-comment cmt"># keyword.</span>
- 99: <span class="ruby-identifier">toc</span>.<span class="ruby-identifier">addEntry</span>(<span class="ruby-constant">TOCEntry</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">sectionPrefix</span>, <span class="ruby-value str">'Syntax Reference'</span>, <span class="ruby-identifier">keywords</span>[<span class="ruby-value">0</span>]))
-100: <span class="ruby-identifier">i</span> = <span class="ruby-value">1</span>
-101: <span class="ruby-identifier">keywords</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">keyword</span><span class="ruby-operator">|</span>
-102: <span class="ruby-identifier">title</span> = <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">title</span>
-103: <span class="ruby-identifier">toc</span>.<span class="ruby-identifier">addEntry</span>(<span class="ruby-constant">TOCEntry</span>.<span class="ruby-identifier">new</span>(<span class="ruby-node">"#{sectionPrefix}.#{i}"</span>, <span class="ruby-identifier">title</span>, <span class="ruby-identifier">keyword</span>))
-104: <span class="ruby-identifier">i</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>
-105: <span class="ruby-keyword kw">end</span>
-106: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 96</span>
+ 96: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">tableOfContents</span>(<span class="ruby-identifier">toc</span>, <span class="ruby-identifier">sectionPrefix</span>)
+ 97: <span class="ruby-identifier">keywords</span> = <span class="ruby-identifier">all</span>
+ 98: <span class="ruby-comment cmt"># Set the chapter name to 'Syntax Reference' with a link to the first</span>
+ 99: <span class="ruby-comment cmt"># keyword.</span>
+100: <span class="ruby-identifier">toc</span>.<span class="ruby-identifier">addEntry</span>(<span class="ruby-constant">TOCEntry</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">sectionPrefix</span>, <span class="ruby-value str">'Syntax Reference'</span>, <span class="ruby-identifier">keywords</span>[<span class="ruby-value">0</span>]))
+101: <span class="ruby-identifier">i</span> = <span class="ruby-value">1</span>
+102: <span class="ruby-identifier">keywords</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">keyword</span><span class="ruby-operator">|</span>
+103: <span class="ruby-identifier">title</span> = <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">title</span>
+104: <span class="ruby-identifier">toc</span>.<span class="ruby-identifier">addEntry</span>(<span class="ruby-constant">TOCEntry</span>.<span class="ruby-identifier">new</span>(<span class="ruby-node">"#{sectionPrefix}.#{i}"</span>, <span class="ruby-identifier">title</span>, <span class="ruby-identifier">keyword</span>))
+105: <span class="ruby-identifier">i</span> <span class="ruby-operator">+=</span> <span class="ruby-value">1</span>
+106: <span class="ruby-keyword kw">end</span>
+107: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -980,18 +986,18 @@
<div class="method-source-code"
id="to-s-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 120</span>
-120: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_s</span>(<span class="ruby-identifier">keyword</span>)
-121: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">checkKeyword</span>(<span class="ruby-identifier">keyword</span>)
-122: <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">to_s</span>
-123: <span class="ruby-keyword kw">else</span>
-124: <span class="ruby-value str">''</span>
-125: <span class="ruby-keyword kw">end</span>
-126: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 121</span>
+121: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_s</span>(<span class="ruby-identifier">keyword</span>)
+122: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">checkKeyword</span>(<span class="ruby-identifier">keyword</span>)
+123: <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">to_s</span>
+124: <span class="ruby-keyword kw">else</span>
+125: <span class="ruby-value str">''</span>
+126: <span class="ruby-keyword kw">end</span>
+127: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -1029,43 +1035,43 @@
<div class="method-source-code"
id="attributes-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 223</span>
-223: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">token</span>, <span class="ruby-identifier">scenarioSpecific</span>)
-224: <span class="ruby-identifier">raise</span> <span class="ruby-node">"Token #{token} must reference a rule"</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">token</span>[<span class="ruby-value">0</span>] <span class="ruby-operator">!=</span> <span class="ruby-value">:reference</span>
-225: <span class="ruby-identifier">token</span> = <span class="ruby-identifier">token</span>[<span class="ruby-value">1</span>]
-226: <span class="ruby-comment cmt"># Find the matching rule.</span>
-227: <span class="ruby-identifier">rule</span> = <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>[<span class="ruby-identifier">token</span>]
-228: <span class="ruby-identifier">attrs</span> = {}
-229: <span class="ruby-comment cmt"># Now we look at the first token of each pattern.</span>
-230: <span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pattern</span><span class="ruby-operator">|</span>
-231: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:literal</span>
-232: <span class="ruby-comment cmt"># If it's a terminal symbol, we found what we are looking for. We add</span>
-233: <span class="ruby-comment cmt"># it to the attrs hash and mark it as non scenario specific.</span>
-234: <span class="ruby-identifier">attrs</span>[<span class="ruby-identifier">pattern</span>] = <span class="ruby-identifier">scenarioSpecific</span>
-235: <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:reference</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">1</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:scenarioIdCol</span>
-236: <span class="ruby-comment cmt"># A reference to the !scenarioId rule marks the next token of the</span>
-237: <span class="ruby-comment cmt"># pattern as a reference to a rule with all scenario specific</span>
-238: <span class="ruby-comment cmt"># attributes.</span>
-239: <span class="ruby-identifier">attrs</span>.<span class="ruby-identifier">merge!</span>(<span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">pattern</span>[<span class="ruby-value">1</span>], <span class="ruby-keyword kw">true</span>))
-240: <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:reference</span>
-241: <span class="ruby-comment cmt"># In case we have a reference to another rule, we just follow the</span>
-242: <span class="ruby-comment cmt"># reference. If the pattern is documented we don't have to follow the</span>
-243: <span class="ruby-comment cmt"># reference. We can use the pattern instead.</span>
-244: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">doc</span>.<span class="ruby-identifier">nil?</span>
-245: <span class="ruby-identifier">attrs</span>.<span class="ruby-identifier">merge!</span>(<span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>], <span class="ruby-identifier">scenarioSpecific</span>))
-246: <span class="ruby-keyword kw">else</span>
-247: <span class="ruby-identifier">attrs</span>[<span class="ruby-identifier">pattern</span>] = <span class="ruby-identifier">scenarioSpecific</span>
-248: <span class="ruby-keyword kw">end</span>
-249: <span class="ruby-keyword kw">else</span>
-250: <span class="ruby-identifier">raise</span> <span class="ruby-node">"Hit unknown token #{token}"</span>
-251: <span class="ruby-keyword kw">end</span>
-252: <span class="ruby-keyword kw">end</span>
-253: <span class="ruby-identifier">attrs</span>
-254: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 224</span>
+224: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">token</span>, <span class="ruby-identifier">scenarioSpecific</span>)
+225: <span class="ruby-identifier">raise</span> <span class="ruby-node">"Token #{token} must reference a rule"</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">token</span>[<span class="ruby-value">0</span>] <span class="ruby-operator">!=</span> <span class="ruby-value">:reference</span>
+226: <span class="ruby-identifier">token</span> = <span class="ruby-identifier">token</span>[<span class="ruby-value">1</span>]
+227: <span class="ruby-comment cmt"># Find the matching rule.</span>
+228: <span class="ruby-identifier">rule</span> = <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>[<span class="ruby-identifier">token</span>]
+229: <span class="ruby-identifier">attrs</span> = {}
+230: <span class="ruby-comment cmt"># Now we look at the first token of each pattern.</span>
+231: <span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">pattern</span><span class="ruby-operator">|</span>
+232: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:literal</span>
+233: <span class="ruby-comment cmt"># If it's a terminal symbol, we found what we are looking for. We add</span>
+234: <span class="ruby-comment cmt"># it to the attrs hash and mark it as non scenario specific.</span>
+235: <span class="ruby-identifier">attrs</span>[<span class="ruby-identifier">pattern</span>] = <span class="ruby-identifier">scenarioSpecific</span>
+236: <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:reference</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">1</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:scenarioIdCol</span>
+237: <span class="ruby-comment cmt"># A reference to the !scenarioId rule marks the next token of the</span>
+238: <span class="ruby-comment cmt"># pattern as a reference to a rule with all scenario specific</span>
+239: <span class="ruby-comment cmt"># attributes.</span>
+240: <span class="ruby-identifier">attrs</span>.<span class="ruby-identifier">merge!</span>(<span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">pattern</span>[<span class="ruby-value">1</span>], <span class="ruby-keyword kw">true</span>))
+241: <span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-value">:reference</span>
+242: <span class="ruby-comment cmt"># In case we have a reference to another rule, we just follow the</span>
+243: <span class="ruby-comment cmt"># reference. If the pattern is documented we don't have to follow the</span>
+244: <span class="ruby-comment cmt"># reference. We can use the pattern instead.</span>
+245: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">doc</span>.<span class="ruby-identifier">nil?</span>
+246: <span class="ruby-identifier">attrs</span>.<span class="ruby-identifier">merge!</span>(<span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>], <span class="ruby-identifier">scenarioSpecific</span>))
+247: <span class="ruby-keyword kw">else</span>
+248: <span class="ruby-identifier">attrs</span>[<span class="ruby-identifier">pattern</span>] = <span class="ruby-identifier">scenarioSpecific</span>
+249: <span class="ruby-keyword kw">end</span>
+250: <span class="ruby-keyword kw">else</span>
+251: <span class="ruby-identifier">raise</span> <span class="ruby-node">"Hit unknown token #{token}"</span>
+252: <span class="ruby-keyword kw">end</span>
+253: <span class="ruby-keyword kw">end</span>
+254: <span class="ruby-identifier">attrs</span>
+255: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -1092,33 +1098,33 @@
<div class="method-source-code"
id="check-eyword-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 256</span>
-256: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">checkKeyword</span>(<span class="ruby-identifier">keyword</span>)
-257: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">nil?</span>
-258: <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">nil?</span>
-259: <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"ERROR: #{keyword} is not a known keyword.\n\n"</span>
-260: <span class="ruby-keyword kw">end</span>
-261: <span class="ruby-comment cmt"># Create list of top-level keywords.</span>
-262: <span class="ruby-identifier">kwdStr</span> = <span class="ruby-value str">''</span>
-263: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
-264: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">contexts</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-operator">||</span>
-265: (<span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">contexts</span>.<span class="ruby-identifier">length</span> <span class="ruby-operator">==</span> <span class="ruby-value">1</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">contexts</span>[<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-identifier">kwd</span>)
-266: <span class="ruby-identifier">kwdStr</span> <span class="ruby-operator">+=</span> <span class="ruby-value str">', '</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">kwdStr</span>.<span class="ruby-identifier">empty?</span>
-267: <span class="ruby-identifier">kwdStr</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">keyword</span>
-268: <span class="ruby-keyword kw">end</span>
-269: <span class="ruby-keyword kw">end</span>
-270: <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-value str">"Try one of the following keywords as argument to this "</span> <span class="ruby-operator">+</span>
-271: <span class="ruby-value str">"program:\n"</span>
-272: <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"#{kwdStr}"</span>
-273: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">false</span>
-274: <span class="ruby-keyword kw">end</span>
-275:
-276: <span class="ruby-keyword kw">true</span>
-277: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 257</span>
+257: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">checkKeyword</span>(<span class="ruby-identifier">keyword</span>)
+258: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span class="ruby-ivar">@keywords</span>[<span class="ruby-identifier">keyword</span>].<span class="ruby-identifier">nil?</span>
+259: <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">keyword</span>.<span class="ruby-identifier">nil?</span>
+260: <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"ERROR: #{keyword} is not a known keyword.\n\n"</span>
+261: <span class="ruby-keyword kw">end</span>
+262: <span class="ruby-comment cmt"># Create list of top-level keywords.</span>
+263: <span class="ruby-identifier">kwdStr</span> = <span class="ruby-value str">''</span>
+264: <span class="ruby-ivar">@keywords</span>.<span class="ruby-identifier">each_value</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">kwd</span><span class="ruby-operator">|</span>
+265: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">contexts</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-operator">||</span>
+266: (<span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">contexts</span>.<span class="ruby-identifier">length</span> <span class="ruby-operator">==</span> <span class="ruby-value">1</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">contexts</span>[<span class="ruby-value">0</span>] <span class="ruby-operator">==</span> <span class="ruby-identifier">kwd</span>)
+267: <span class="ruby-identifier">kwdStr</span> <span class="ruby-operator">+=</span> <span class="ruby-value str">', '</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">kwdStr</span>.<span class="ruby-identifier">empty?</span>
+268: <span class="ruby-identifier">kwdStr</span> <span class="ruby-operator">+=</span> <span class="ruby-identifier">kwd</span>.<span class="ruby-identifier">keyword</span>
+269: <span class="ruby-keyword kw">end</span>
+270: <span class="ruby-keyword kw">end</span>
+271: <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-value str">"Try one of the following keywords as argument to this "</span> <span class="ruby-operator">+</span>
+272: <span class="ruby-value str">"program:\n"</span>
+273: <span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"#{kwdStr}"</span>
+274: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">false</span>
+275: <span class="ruby-keyword kw">end</span>
+276:
+277: <span class="ruby-keyword kw">true</span>
+278: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>
@@ -1147,41 +1153,41 @@
<div class="method-source-code"
id="optional-ttributes-source">
<pre>
- <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 187</span>
-187: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">optionalAttributes</span>(<span class="ruby-identifier">pattern</span>, <span class="ruby-identifier">stack</span>)
-188: <span class="ruby-comment cmt"># If we hit an endless recursion we won't find any attributes. So we push</span>
-189: <span class="ruby-comment cmt"># each pattern we process on the 'stack'. If we hit it again, we just</span>
-190: <span class="ruby-comment cmt"># return an empty hash.</span>
-191: <span class="ruby-keyword kw">return</span> {} <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">stack</span>[<span class="ruby-identifier">pattern</span>]
-192:
-193: <span class="ruby-comment cmt"># If we hit a pattern that is documented, we ignore it.</span>
-194: <span class="ruby-keyword kw">return</span> {} <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">stack</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">doc</span>
-195:
-196: <span class="ruby-comment cmt"># Push pattern onto 'stack'.</span>
-197: <span class="ruby-identifier">stack</span>[<span class="ruby-identifier">pattern</span>] = <span class="ruby-keyword kw">true</span>
-198:
-199: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">1</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">'{'</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">2</span>][<span class="ruby-value">1</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">'}'</span>
-200: <span class="ruby-comment cmt"># We have found an optional attribute pattern!</span>
-201: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">pattern</span>[<span class="ruby-value">1</span>], <span class="ruby-keyword kw">false</span>)
-202: <span class="ruby-keyword kw">end</span>
-203:
-204: <span class="ruby-comment cmt"># If a token of the pattern is a reference, we recursively</span>
-205: <span class="ruby-comment cmt"># follow the reference to the next pattern.</span>
-206: <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">type</span>, <span class="ruby-identifier">name</span><span class="ruby-operator">|</span>
-207: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">type</span> <span class="ruby-operator">==</span> <span class="ruby-value">:reference</span>
-208: <span class="ruby-identifier">rule</span> = <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>[<span class="ruby-identifier">name</span>]
-209: <span class="ruby-comment cmt"># Rules with multiple patterns won't lead to attributes.</span>
-210: <span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">length</span> <span class="ruby-operator">></span> <span class="ruby-value">1</span>
-211:
-212: <span class="ruby-identifier">attrs</span> = <span class="ruby-identifier">optionalAttributes</span>(<span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>[<span class="ruby-value">0</span>], <span class="ruby-identifier">stack</span>)
-213: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">attrs</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">attrs</span>.<span class="ruby-identifier">empty?</span>
-214: <span class="ruby-keyword kw">end</span>
-215: <span class="ruby-keyword kw">end</span>
-216: {}
-217: <span class="ruby-keyword kw">end</span></pre>
+ <span class="ruby-comment cmt"># File lib/SyntaxReference.rb, line 188</span>
+188: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">optionalAttributes</span>(<span class="ruby-identifier">pattern</span>, <span class="ruby-identifier">stack</span>)
+189: <span class="ruby-comment cmt"># If we hit an endless recursion we won't find any attributes. So we push</span>
+190: <span class="ruby-comment cmt"># each pattern we process on the 'stack'. If we hit it again, we just</span>
+191: <span class="ruby-comment cmt"># return an empty hash.</span>
+192: <span class="ruby-keyword kw">return</span> {} <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">stack</span>[<span class="ruby-identifier">pattern</span>]
+193:
+194: <span class="ruby-comment cmt"># If we hit a pattern that is documented, we ignore it.</span>
+195: <span class="ruby-keyword kw">return</span> {} <span class="ruby-keyword kw">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">stack</span>.<span class="ruby-identifier">empty?</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">doc</span>
+196:
+197: <span class="ruby-comment cmt"># Push pattern onto 'stack'.</span>
+198: <span class="ruby-identifier">stack</span>[<span class="ruby-identifier">pattern</span>] = <span class="ruby-keyword kw">true</span>
+199:
+200: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">0</span>][<span class="ruby-value">1</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">'{'</span> <span class="ruby-operator">&&</span> <span class="ruby-identifier">pattern</span>[<span class="ruby-value">2</span>][<span class="ruby-value">1</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">'}'</span>
+201: <span class="ruby-comment cmt"># We have found an optional attribute pattern!</span>
+202: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">attributes</span>(<span class="ruby-identifier">pattern</span>[<span class="ruby-value">1</span>], <span class="ruby-keyword kw">false</span>)
+203: <span class="ruby-keyword kw">end</span>
+204:
+205: <span class="ruby-comment cmt"># If a token of the pattern is a reference, we recursively</span>
+206: <span class="ruby-comment cmt"># follow the reference to the next pattern.</span>
+207: <span class="ruby-identifier">pattern</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">type</span>, <span class="ruby-identifier">name</span><span class="ruby-operator">|</span>
+208: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">type</span> <span class="ruby-operator">==</span> <span class="ruby-value">:reference</span>
+209: <span class="ruby-identifier">rule</span> = <span class="ruby-ivar">@parser</span>.<span class="ruby-identifier">rules</span>[<span class="ruby-identifier">name</span>]
+210: <span class="ruby-comment cmt"># Rules with multiple patterns won't lead to attributes.</span>
+211: <span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>.<span class="ruby-identifier">length</span> <span class="ruby-operator">></span> <span class="ruby-value">1</span>
+212:
+213: <span class="ruby-identifier">attrs</span> = <span class="ruby-identifier">optionalAttributes</span>(<span class="ruby-identifier">rule</span>.<span class="ruby-identifier">patterns</span>[<span class="ruby-value">0</span>], <span class="ruby-identifier">stack</span>)
+214: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">attrs</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">attrs</span>.<span class="ruby-identifier">empty?</span>
+215: <span class="ruby-keyword kw">end</span>
+216: <span class="ruby-keyword kw">end</span>
+217: {}
+218: <span class="ruby-keyword kw">end</span></pre>
</div>
</div>