doc/TermUtils/AP/Syntax.html in term_utils-0.3.2 vs doc/TermUtils/AP/Syntax.html in term_utils-0.4.0

- old
+ new

@@ -4,19 +4,19 @@ <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title> Class: TermUtils::AP::Syntax - &mdash; Documentation by YARD 0.9.20 + &mdash; Documentation by YARD 0.9.25 </title> - <link rel="stylesheet" href="../../css/style.css" type="text/css" charset="utf-8" /> + <link rel="stylesheet" href="../../css/style.css" type="text/css" /> - <link rel="stylesheet" href="../../css/common.css" type="text/css" charset="utf-8" /> + <link rel="stylesheet" href="../../css/common.css" type="text/css" /> -<script type="text/javascript" charset="utf-8"> +<script type="text/javascript"> pathId = "TermUtils::AP::Syntax"; relpath = '../../'; </script> @@ -100,11 +100,11 @@ </div> <h2>Overview</h2><div class="docstring"> <div class="discussion"> -<p>Represents the argument list syntax. It holds a list of parameters and levels.</p> +<p>Represents the argument list syntax. It holds a list of parameters.</p> </div> </div> <div class="tags"> @@ -118,11 +118,11 @@ <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#elements-instance_method" title="#elements (instance method)">#<strong>elements</strong> &#x21d2; Array&lt;TermUtils::AP::Element&gt; </a> + <a href="#parameters-instance_method" title="#parameters (instance method)">#<strong>parameters</strong> &#x21d2; Array&lt;Parameter&gt; </a> </span> @@ -156,11 +156,11 @@ <ul class="summary"> <li class="public "> <span class="summary_signature"> - <a href="#define_level-instance_method" title="#define_level (instance method)">#<strong>define_level</strong>(opts = {}, &amp;block) &#x21d2; TermUtils::AP::Level </a> + <a href="#define_parameter-instance_method" title="#define_parameter (instance method)">#<strong>define_parameter</strong>(id = nil, opts = {}, &amp;block) &#x21d2; Parameter </a> </span> @@ -171,44 +171,20 @@ <span class="summary_desc"><div class='inline'> -<p>Creates and adds a new Level.</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#define_parameter-instance_method" title="#define_parameter (instance method)">#<strong>define_parameter</strong>(opts = {}, &amp;block) &#x21d2; TermUtils::AP::Parameter </a> - - - - </span> - - - - - - - - - - <span class="summary_desc"><div class='inline'> <p>Creates and adds a new Parameter.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> - <a href="#fetch_elements-instance_method" title="#fetch_elements (instance method)">#<strong>fetch_elements</strong> &#x21d2; Array </a> + <a href="#fetch_parameters-instance_method" title="#fetch_parameters (instance method)">#<strong>fetch_parameters</strong> &#x21d2; Array </a> </span> @@ -219,67 +195,19 @@ <span class="summary_desc"><div class='inline'> -<p>Fetches all direct flagged parameters and levels.</p> +<p>Fetches all flagged parameters and unflagged parameters.</p> </div></span> </li> <li class="public "> <span class="summary_signature"> - <a href="#fetch_flagged_elements-instance_method" title="#fetch_flagged_elements (instance method)">#<strong>fetch_flagged_elements</strong> &#x21d2; Hash&lt;String, TermUtils::AP::Element&gt; </a> - - - - </span> - - - - - - - - - - <span class="summary_desc"><div class='inline'> -<p>Fetches all direct flagged parameters and levels.</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - - <a href="#fetch_unflagged_parameters-instance_method" title="#fetch_unflagged_parameters (instance method)">#<strong>fetch_unflagged_parameters</strong> &#x21d2; Array&lt;TermUtils::AP::Parameter&gt; </a> - - - - </span> - - - - - - - - - - <span class="summary_desc"><div class='inline'> -<p>Fetches all direct unflagged.</p> -</div></span> - -</li> - - - <li class="public "> - <span class="summary_signature"> - <a href="#finalize!-instance_method" title="#finalize! (instance method)">#<strong>finalize!</strong>(opts = {}) &#x21d2; nil </a> </span> @@ -379,19 +307,19 @@ <tr> <td> <pre class="lines"> -26 27 -28</pre> +28 +29</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 26</span> + <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 27</span> <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span> - <span class='ivar'>@elements</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> + <span class='ivar'>@parameters</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> @@ -400,15 +328,15 @@ <div id="instance_attr_details" class="attr_details"> <h2>Instance Attribute Details</h2> - <span id="elements=-instance_method"></span> + <span id="parameters=-instance_method"></span> <div class="method_details first"> - <h3 class="signature first" id="elements-instance_method"> + <h3 class="signature first" id="parameters-instance_method"> - #<strong>elements</strong> &#x21d2; <tt>Array&lt;<span class='object_link'><a href="Element.html" title="TermUtils::AP::Element (class)">TermUtils::AP::Element</a></span>&gt;</tt> + #<strong>parameters</strong> &#x21d2; <tt>Array&lt;<span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">Parameter</a></span>&gt;</tt> @@ -424,11 +352,11 @@ <ul class="return"> <li> - <span class='type'>(<tt>Array&lt;<span class='object_link'><a href="Element.html" title="TermUtils::AP::Element (class)">TermUtils::AP::Element</a></span>&gt;</tt>)</span> + <span class='type'>(<tt>Array&lt;<span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">Parameter</a></span>&gt;</tt>)</span> </li> @@ -445,12 +373,12 @@ 26</pre> </td> <td> <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 24</span> -<span class='kw'>def</span> <span class='id identifier rubyid_elements'>elements</span> - <span class='ivar'>@elements</span> +<span class='kw'>def</span> <span class='id identifier rubyid_parameters'>parameters</span> + <span class='ivar'>@parameters</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> @@ -461,155 +389,45 @@ <div id="instance_method_details" class="method_details_list"> <h2>Instance Method Details</h2> <div class="method_details first"> - <h3 class="signature first" id="define_level-instance_method"> + <h3 class="signature first" id="define_parameter-instance_method"> - #<strong>define_level</strong>(opts = {}, &amp;block) &#x21d2; <tt><span class='object_link'><a href="Level.html" title="TermUtils::AP::Level (class)">TermUtils::AP::Level</a></span></tt> + #<strong>define_parameter</strong>(id = nil, opts = {}, &amp;block) &#x21d2; <tt><span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">Parameter</a></span></tt> </h3><div class="docstring"> <div class="discussion"> -<p>Creates and adds a new Level.</p> +<p>Creates and adds a new Parameter.</p> </div> </div> <div class="tags"> <p class="tag_title">Parameters:</p> <ul class="param"> <li> - <span class='name'>opts</span> + <span class='name'>id</span> - <span class='type'>(<tt>Hash</tt>)</span> + <span class='type'>(<tt>Symbol</tt>, <tt>nil</tt>)</span> - <em class="default">(defaults to: <tt>{}</tt>)</em> + <em class="default">(defaults to: <tt>nil</tt>)</em> </li> -</ul> - - - - - <p class="tag_title">Options Hash (<tt>opts</tt>):</p> - <ul class="option"> - - <li> - <span class="name">:id</span> - <span class="type">(<tt>Symbol</tt>)</span> - <span class="default"> - - </span> - - </li> - - <li> - <span class="name">:min_occurs</span> - <span class="type">(<tt>Integer</tt>)</span> - <span class="default"> - - </span> - - &mdash; <div class='inline'> -<p>Default value is `0`.</p> -</div> - - </li> - - <li> - <span class="name">:max_occurs</span> - <span class="type">(<tt>Integer</tt>)</span> - <span class="default"> - - </span> - - &mdash; <div class='inline'> -<p>Default value is `1`.</p> -</div> - - </li> - - </ul> - - - - -<p class="tag_title">Returns:</p> -<ul class="return"> - <li> - - <span class='type'>(<tt><span class='object_link'><a href="Level.html" title="TermUtils::AP::Level (class)">TermUtils::AP::Level</a></span></tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -63 -64 -65 -66 -67 -68</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 63</span> - -<span class='kw'>def</span> <span class='id identifier rubyid_define_level'>define_level</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span> - <span class='id identifier rubyid_new_level'>new_level</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../../TermUtils.html" title="TermUtils (module)">TermUtils</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="../AP.html" title="TermUtils::AP (module)">AP</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Level.html" title="TermUtils::AP::Level (class)">Level</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Level.html#initialize-instance_method" title="TermUtils::AP::Level#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span> - <span class='ivar'>@elements</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_new_level'>new_level</span> - <span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span><span class='lparen'>(</span><span class='id identifier rubyid_new_level'>new_level</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_block'>block</span> - <span class='id identifier rubyid_new_level'>new_level</span> -<span class='kw'>end</span></pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <h3 class="signature " id="define_parameter-instance_method"> - - #<strong>define_parameter</strong>(opts = {}, &amp;block) &#x21d2; <tt><span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">TermUtils::AP::Parameter</a></span></tt> - - - - - -</h3><div class="docstring"> - <div class="discussion"> - -<p>Creates and adds a new Parameter.</p> - - - </div> -</div> -<div class="tags"> - <p class="tag_title">Parameters:</p> -<ul class="param"> - - <li> - <span class='name'>opts</span> <span class='type'>(<tt>Hash</tt>)</span> @@ -622,10 +440,12 @@ </ul> + + <p class="tag_title">Options Hash (<tt>opts</tt>):</p> <ul class="option"> <li> <span class="name">:id</span> @@ -641,27 +461,19 @@ <span class="type">(<tt>Integer</tt>)</span> <span class="default"> </span> - &mdash; <div class='inline'> -<p>Default value is `0`.</p> -</div> - </li> <li> <span class="name">:max_occurs</span> <span class="type">(<tt>Integer</tt>)</span> <span class="default"> </span> - &mdash; <div class='inline'> -<p>Default value is `1`.</p> -</div> - </li> </ul> @@ -671,11 +483,11 @@ <ul class="return"> <li> - <span class='type'>(<tt><span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">TermUtils::AP::Parameter</a></span></tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">Parameter</a></span></tt>)</span> </li> @@ -685,44 +497,62 @@ <tr> <td> <pre class="lines"> -51 -52 -53 54 55 -56</pre> +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 51</span> + <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 54</span> -<span class='kw'>def</span> <span class='id identifier rubyid_define_parameter'>define_parameter</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span> +<span class='kw'>def</span> <span class='id identifier rubyid_define_parameter'>define_parameter</span><span class='lparen'>(</span><span class='id identifier rubyid_id'>id</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='comma'>,</span> <span class='op'>&amp;</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span> + <span class='kw'>if</span> <span class='id identifier rubyid_id'>id</span> + <span class='id identifier rubyid_param'>param</span> <span class='op'>=</span> <span class='ivar'>@parameters</span><span class='period'>.</span><span class='id identifier rubyid_find'>find</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_p'>p</span><span class='op'>|</span> <span class='id identifier rubyid_p'>p</span><span class='period'>.</span><span class='id identifier rubyid_id'>id</span> <span class='op'>==</span> <span class='id identifier rubyid_id'>id</span> <span class='rbrace'>}</span> + <span class='kw'>if</span> <span class='id identifier rubyid_param'>param</span> + <span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span><span class='lparen'>(</span><span class='id identifier rubyid_param'>param</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_block'>block</span> + <span class='kw'>return</span> <span class='id identifier rubyid_param'>param</span> + <span class='kw'>end</span> + + <span class='id identifier rubyid_opts'>opts</span><span class='lbracket'>[</span><span class='symbol'>:id</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_id'>id</span> + <span class='kw'>end</span> <span class='id identifier rubyid_new_parameter'>new_parameter</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../../TermUtils.html" title="TermUtils (module)">TermUtils</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="../AP.html" title="TermUtils::AP (module)">AP</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">Parameter</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Parameter.html#initialize-instance_method" title="TermUtils::AP::Parameter#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span> - <span class='ivar'>@elements</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_new_parameter'>new_parameter</span> + <span class='ivar'>@parameters</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_new_parameter'>new_parameter</span> <span class='id identifier rubyid_block'>block</span><span class='period'>.</span><span class='id identifier rubyid_call'>call</span><span class='lparen'>(</span><span class='id identifier rubyid_new_parameter'>new_parameter</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_block'>block</span> <span class='id identifier rubyid_new_parameter'>new_parameter</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <h3 class="signature " id="fetch_elements-instance_method"> + <h3 class="signature " id="fetch_parameters-instance_method"> - #<strong>fetch_elements</strong> &#x21d2; <tt>Array</tt> + #<strong>fetch_parameters</strong> &#x21d2; <tt>Array</tt> </h3><div class="docstring"> <div class="discussion"> -<p>Fetches all direct flagged parameters and levels.</p> +<p>Fetches all flagged parameters and unflagged parameters.</p> </div> </div> <div class="tags"> @@ -739,25 +569,17 @@ </li> </ul> - <p class="tag_title">See Also:</p> - <ul class="see"> - - <li><span class='object_link'><a href="#fetch_flagged_elements-instance_method" title="TermUtils::AP::Syntax#fetch_flagged_elements (method)">#fetch_flagged_elements</a></span></li> - - <li><span class='object_link'><a href="#fetch_unflagged_parameters-instance_method" title="TermUtils::AP::Syntax#fetch_unflagged_parameters (method)">#fetch_unflagged_parameters</a></span></li> - - </ul> - </div><table class="source_code"> <tr> <td> <pre class="lines"> +72 73 74 75 76 77 @@ -769,49 +591,60 @@ 83 84 85 86 87 -88</pre> +88 +89 +90 +91 +92 +93</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 73</span> + <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 72</span> -<span class='kw'>def</span> <span class='id identifier rubyid_fetch_elements'>fetch_elements</span> - <span class='id identifier rubyid_flagged_elems'>flagged_elems</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span> +<span class='kw'>def</span> <span class='id identifier rubyid_fetch_parameters'>fetch_parameters</span> <span class='id identifier rubyid_unflagged_params'>unflagged_params</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> - <span class='ivar'>@elements</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_e'>e</span><span class='op'>|</span> - <span class='kw'>if</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_flags'>flags</span><span class='period'>.</span><span class='id identifier rubyid_empty?'>empty?</span> - <span class='comment'># Parameter -</span> <span class='id identifier rubyid_unflagged_params'>unflagged_params</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_e'>e</span> - <span class='kw'>else</span> - <span class='comment'># Parameter or Level -</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_flags'>flags</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_f'>f</span><span class='op'>|</span> - <span class='id identifier rubyid_flagged_elems'>flagged_elems</span><span class='lbracket'>[</span><span class='id identifier rubyid_f'>f</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_e'>e</span> + <span class='id identifier rubyid_flagged_params'>flagged_params</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span> + <span class='id identifier rubyid_shortcut_flags'>shortcut_flags</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span> + <span class='ivar'>@parameters</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_p'>p</span><span class='op'>|</span> + <span class='kw'>if</span> <span class='id identifier rubyid_p'>p</span><span class='period'>.</span><span class='id identifier rubyid_flagged?'>flagged?</span> + <span class='comment'># Flagged +</span> <span class='id identifier rubyid_p'>p</span><span class='period'>.</span><span class='id identifier rubyid_flags'>flags</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_f'>f</span><span class='op'>|</span> + <span class='id identifier rubyid_flagged_params'>flagged_params</span><span class='lbracket'>[</span><span class='id identifier rubyid_f'>f</span><span class='period'>.</span><span class='id identifier rubyid_label'>label</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_p'>p</span> + <span class='kw'>if</span> <span class='id identifier rubyid_f'>f</span><span class='period'>.</span><span class='id identifier rubyid_long?'>long?</span> + <span class='id identifier rubyid_shortcut_flags'>shortcut_flags</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_f'>f</span><span class='period'>.</span><span class='id identifier rubyid_label'>label</span><span class='embexpr_end'>}</span><span class='tstring_content'>=</span><span class='tstring_end'>&quot;</span></span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_f'>f</span> + <span class='kw'>else</span> + <span class='id identifier rubyid_shortcut_flags'>shortcut_flags</span><span class='lbracket'>[</span><span class='id identifier rubyid_f'>f</span><span class='period'>.</span><span class='id identifier rubyid_label'>label</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_f'>f</span> + <span class='kw'>end</span> <span class='kw'>end</span> + <span class='kw'>else</span> + <span class='comment'># Unflagged +</span> <span class='id identifier rubyid_unflagged_params'>unflagged_params</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_p'>p</span> <span class='kw'>end</span> <span class='kw'>end</span> - <span class='lbracket'>[</span><span class='id identifier rubyid_flagged_elems'>flagged_elems</span><span class='comma'>,</span> <span class='id identifier rubyid_unflagged_params'>unflagged_params</span><span class='rbracket'>]</span> + <span class='lbracket'>[</span><span class='id identifier rubyid_unflagged_params'>unflagged_params</span><span class='comma'>,</span> <span class='id identifier rubyid_flagged_params'>flagged_params</span><span class='comma'>,</span> <span class='id identifier rubyid_shortcut_flags'>shortcut_flags</span><span class='rbracket'>]</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> <div class="method_details "> - <h3 class="signature " id="fetch_flagged_elements-instance_method"> + <h3 class="signature " id="finalize!-instance_method"> - #<strong>fetch_flagged_elements</strong> &#x21d2; <tt>Hash&lt;String, <span class='object_link'><a href="Element.html" title="TermUtils::AP::Element (class)">TermUtils::AP::Element</a></span>&gt;</tt> + #<strong>finalize!</strong>(opts = {}) &#x21d2; <tt>nil</tt> </h3><div class="docstring"> <div class="discussion"> -<p>Fetches all direct flagged parameters and levels.</p> +<p>Finalizes this one. Internal use.</p> </div> </div> <div class="tags"> @@ -820,77 +653,24 @@ <ul class="return"> <li> - <span class='type'>(<tt>Hash&lt;String, <span class='object_link'><a href="Element.html" title="TermUtils::AP::Element (class)">TermUtils::AP::Element</a></span>&gt;</tt>)</span> + <span class='type'>(<tt>nil</tt>)</span> </li> </ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - -91 -92 -93 -94 -95 -96 -97 -98 -99</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 91</span> - -<span class='kw'>def</span> <span class='id identifier rubyid_fetch_flagged_elements'>fetch_flagged_elements</span> - <span class='id identifier rubyid_elems'>elems</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span> - <span class='ivar'>@elements</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_e'>e</span><span class='op'>|</span> - <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_flags'>flags</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_f'>f</span><span class='op'>|</span> - <span class='id identifier rubyid_elems'>elems</span><span class='lbracket'>[</span><span class='id identifier rubyid_f'>f</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_e'>e</span> - <span class='kw'>end</span> - <span class='kw'>end</span> - <span class='id identifier rubyid_elems'>elems</span> -<span class='kw'>end</span></pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <h3 class="signature " id="fetch_unflagged_parameters-instance_method"> +<p class="tag_title">Raises:</p> +<ul class="raise"> - #<strong>fetch_unflagged_parameters</strong> &#x21d2; <tt>Array&lt;<span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">TermUtils::AP::Parameter</a></span>&gt;</tt> - - - - - -</h3><div class="docstring"> - <div class="discussion"> - -<p>Fetches all direct unflagged.</p> - - - </div> -</div> -<div class="tags"> - -<p class="tag_title">Returns:</p> -<ul class="return"> - <li> - <span class='type'>(<tt>Array&lt;<span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">TermUtils::AP::Parameter</a></span>&gt;</tt>)</span> + <span class='type'>(<tt><span class='object_link'><a href="SyntaxError.html" title="TermUtils::AP::SyntaxError (class)">SyntaxError</a></span></tt>)</span> </li> @@ -900,85 +680,25 @@ <tr> <td> <pre class="lines"> -102 -103 -104 -105 -106 -107 -108 -109</pre> - </td> - <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 102</span> - -<span class='kw'>def</span> <span class='id identifier rubyid_fetch_unflagged_parameters'>fetch_unflagged_parameters</span> - <span class='id identifier rubyid_params'>params</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> - <span class='ivar'>@elements</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_e'>e</span><span class='op'>|</span> - <span class='kw'>next</span> <span class='kw'>unless</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span> <span class='const'><span class='object_link'><a href="../../TermUtils.html" title="TermUtils (module)">TermUtils</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="../AP.html" title="TermUtils::AP (module)">AP</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Parameter.html" title="TermUtils::AP::Parameter (class)">Parameter</a></span></span> - <span class='id identifier rubyid_params'>params</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_e'>e</span> <span class='kw'>if</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_flags'>flags</span><span class='period'>.</span><span class='id identifier rubyid_empty?'>empty?</span> - <span class='kw'>end</span> - <span class='id identifier rubyid_params'>params</span> -<span class='kw'>end</span></pre> - </td> - </tr> -</table> -</div> - - <div class="method_details "> - <h3 class="signature " id="finalize!-instance_method"> - - #<strong>finalize!</strong>(opts = {}) &#x21d2; <tt>nil</tt> - - - - - -</h3><div class="docstring"> - <div class="discussion"> - -<p>Finalizes this one. Internal use.</p> - - - </div> -</div> -<div class="tags"> - -<p class="tag_title">Returns:</p> -<ul class="return"> - - <li> - - - <span class='type'>(<tt>nil</tt>)</span> - - - - </li> - -</ul> - -</div><table class="source_code"> - <tr> - <td> - <pre class="lines"> - - +40 41 42 43 -44</pre> +44 +45</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 41</span> + <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 40</span> <span class='kw'>def</span> <span class='id identifier rubyid_finalize!'>finalize!</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> - <span class='id identifier rubyid_opts'>opts</span><span class='lbracket'>[</span><span class='symbol'>:anonymous</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='int'>0</span> <span class='kw'>unless</span> <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_has_key?'>has_key?</span> <span class='symbol'>:anonymous</span> - <span class='ivar'>@elements</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_e'>e</span><span class='op'>|</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_finalize!'>finalize!</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='id identifier rubyid_opts'>opts</span><span class='lbracket'>[</span><span class='symbol'>:anonymous</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='int'>0</span> <span class='kw'>unless</span> <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_key?'>key?</span> <span class='symbol'>:anonymous</span> + <span class='id identifier rubyid_opts'>opts</span><span class='lbracket'>[</span><span class='symbol'>:flag_labels</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> + <span class='ivar'>@parameters</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_p'>p</span><span class='op'>|</span> <span class='id identifier rubyid_p'>p</span><span class='period'>.</span><span class='id identifier rubyid_finalize!'>finalize!</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span> <span class='rbrace'>}</span> + <span class='kw'>nil</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> @@ -1007,31 +727,21 @@ <tr> <td> <pre class="lines"> -30 -31 32 33 34 -35 -36 -37 -38</pre> +35</pre> </td> <td> - <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 30</span> + <pre class="code"><span class="info file"># File 'lib/term_utils/ap/syntax.rb', line 32</span> <span class='kw'>def</span> <span class='id identifier rubyid_initialize_dup'>initialize_dup</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span> - <span class='kw'>if</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_elements'>elements</span> - <span class='ivar'>@elements</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span> - <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_elements'>elements</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_e'>e</span><span class='op'>|</span> - <span class='ivar'>@elements</span> <span class='op'>&lt;&lt;</span> <span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span> - <span class='kw'>end</span> - <span class='kw'>end</span> - <span class='kw'>super</span> + <span class='kw'>super</span><span class='lparen'>(</span><span class='id identifier rubyid_other'>other</span><span class='rparen'>)</span> + <span class='ivar'>@parameters</span> <span class='op'>=</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_parameters'>parameters</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='symbol'>:dup</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_other'>other</span><span class='period'>.</span><span class='id identifier rubyid_parameters'>parameters</span> <span class='kw'>end</span></pre> </td> </tr> </table> </div> @@ -1039,12 +749,12 @@ </div> </div> <div id="footer"> - Generated on Fri Feb 7 18:54:40 2020 by + Generated on Sun Aug 2 18:35:10 2020 by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> - 0.9.20 (ruby-2.6.5). + 0.9.25 (ruby-2.6.5). </div> </div> </body> </html> \ No newline at end of file