term_utils 0.1.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/AUTHORS +1 -0
- data/CHANGELOG.md +51 -0
- data/COPYING +674 -0
- data/README.md +99 -0
- data/Rakefile +55 -0
- data/doc/TermUtils.html +138 -0
- data/doc/TermUtils/AP.html +394 -0
- data/doc/TermUtils/AP/Article.html +993 -0
- data/doc/TermUtils/AP/ArticleResult.html +584 -0
- data/doc/TermUtils/AP/Flag.html +756 -0
- data/doc/TermUtils/AP/NoSuchValueError.html +217 -0
- data/doc/TermUtils/AP/Parameter.html +1592 -0
- data/doc/TermUtils/AP/ParameterResult.html +980 -0
- data/doc/TermUtils/AP/ParameterWalkerHooks.html +409 -0
- data/doc/TermUtils/AP/ParseError.html +217 -0
- data/doc/TermUtils/AP/Parser.html +604 -0
- data/doc/TermUtils/AP/Result.html +837 -0
- data/doc/TermUtils/AP/Syntax.html +761 -0
- data/doc/TermUtils/AP/SyntaxError.html +217 -0
- data/doc/TermUtils/AP/Walker.html +686 -0
- data/doc/TermUtils/FF.html +128 -0
- data/doc/TermUtils/FF/Config.html +774 -0
- data/doc/TermUtils/FF/Context.html +585 -0
- data/doc/TermUtils/FF/Entry.html +626 -0
- data/doc/TermUtils/FF/Query.html +1085 -0
- data/doc/TermUtils/PropertyTreeNode.html +2113 -0
- data/doc/TermUtils/Tab.html +1486 -0
- data/doc/TermUtils/Tab/Column.html +1263 -0
- data/doc/TermUtils/Tab/Header.html +536 -0
- data/doc/TermUtils/Tab/Holder.html +1210 -0
- data/doc/TermUtils/Tab/Printer.html +967 -0
- data/doc/TermUtils/Tab/Table.html +1966 -0
- data/doc/TermUtils/Tab/TableError.html +217 -0
- data/doc/_index.html +387 -0
- data/doc/class_list.html +51 -0
- data/doc/css/common.css +1 -0
- data/doc/css/full_list.css +58 -0
- data/doc/css/style.css +496 -0
- data/doc/file.README.html +170 -0
- data/doc/file_list.html +56 -0
- data/doc/frames.html +17 -0
- data/doc/index.html +170 -0
- data/doc/js/app.js +314 -0
- data/doc/js/full_list.js +216 -0
- data/doc/js/jquery.js +4 -0
- data/doc/method_list.html +1539 -0
- data/doc/top-level-namespace.html +110 -0
- data/lib/term_utils.rb +11 -0
- data/lib/term_utils/ap.rb +70 -0
- data/lib/term_utils/ap/article.rb +74 -0
- data/lib/term_utils/ap/flag.rb +65 -0
- data/lib/term_utils/ap/parameter.rb +144 -0
- data/lib/term_utils/ap/parser.rb +211 -0
- data/lib/term_utils/ap/result.rb +244 -0
- data/lib/term_utils/ap/syntax.rb +96 -0
- data/lib/term_utils/ff.rb +27 -0
- data/lib/term_utils/ff/config.rb +55 -0
- data/lib/term_utils/ff/entry.rb +45 -0
- data/lib/term_utils/ff/query.rb +145 -0
- data/lib/term_utils/property_tree_node.rb +228 -0
- data/lib/term_utils/tab.rb +338 -88
- data/term_utils.gemspec +16 -0
- metadata +69 -7
@@ -0,0 +1,837 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
|
+
<title>
|
7
|
+
Class: TermUtils::AP::Result
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.25
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="../../css/style.css" type="text/css" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="../../css/common.css" type="text/css" />
|
16
|
+
|
17
|
+
<script type="text/javascript">
|
18
|
+
pathId = "TermUtils::AP::Result";
|
19
|
+
relpath = '../../';
|
20
|
+
</script>
|
21
|
+
|
22
|
+
|
23
|
+
<script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
|
24
|
+
|
25
|
+
<script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
|
26
|
+
|
27
|
+
|
28
|
+
</head>
|
29
|
+
<body>
|
30
|
+
<div class="nav_wrap">
|
31
|
+
<iframe id="nav" src="../../class_list.html?1"></iframe>
|
32
|
+
<div id="resizer"></div>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div id="main" tabindex="-1">
|
36
|
+
<div id="header">
|
37
|
+
<div id="menu">
|
38
|
+
|
39
|
+
<a href="../../_index.html">Index (R)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../../TermUtils.html" title="TermUtils (module)">TermUtils</a></span></span> » <span class='title'><span class='object_link'><a href="../AP.html" title="TermUtils::AP (module)">AP</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">Result</span>
|
43
|
+
|
44
|
+
</div>
|
45
|
+
|
46
|
+
<div id="search">
|
47
|
+
|
48
|
+
<a class="full_list_link" id="class_list_link"
|
49
|
+
href="../../class_list.html">
|
50
|
+
|
51
|
+
<svg width="24" height="24">
|
52
|
+
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
53
|
+
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
54
|
+
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
55
|
+
</svg>
|
56
|
+
</a>
|
57
|
+
|
58
|
+
</div>
|
59
|
+
<div class="clear"></div>
|
60
|
+
</div>
|
61
|
+
|
62
|
+
<div id="content"><h1>Class: TermUtils::AP::Result
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
<dl>
|
70
|
+
<dt>Inherits:</dt>
|
71
|
+
<dd>
|
72
|
+
<span class="inheritName">Object</span>
|
73
|
+
|
74
|
+
<ul class="fullTree">
|
75
|
+
<li>Object</li>
|
76
|
+
|
77
|
+
<li class="next">TermUtils::AP::Result</li>
|
78
|
+
|
79
|
+
</ul>
|
80
|
+
<a href="#" class="inheritanceTree">show all</a>
|
81
|
+
|
82
|
+
</dd>
|
83
|
+
</dl>
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
<dl>
|
96
|
+
<dt>Defined in:</dt>
|
97
|
+
<dd>lib/term_utils/ap/result.rb</dd>
|
98
|
+
</dl>
|
99
|
+
|
100
|
+
</div>
|
101
|
+
|
102
|
+
<h2>Overview</h2><div class="docstring">
|
103
|
+
<div class="discussion">
|
104
|
+
|
105
|
+
<p>Represents an argument parsing Result.</p>
|
106
|
+
|
107
|
+
|
108
|
+
</div>
|
109
|
+
</div>
|
110
|
+
<div class="tags">
|
111
|
+
|
112
|
+
|
113
|
+
</div>
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
<h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
|
118
|
+
<ul class="summary">
|
119
|
+
|
120
|
+
<li class="public ">
|
121
|
+
<span class="summary_signature">
|
122
|
+
|
123
|
+
<a href="#parameter-instance_method" title="#parameter (instance method)">#<strong>parameter</strong> ⇒ Syntax </a>
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
</span>
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
<span class="note title readonly">readonly</span>
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
|
142
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
143
|
+
|
144
|
+
</li>
|
145
|
+
|
146
|
+
|
147
|
+
<li class="public ">
|
148
|
+
<span class="summary_signature">
|
149
|
+
|
150
|
+
<a href="#remaining_arguments-instance_method" title="#remaining_arguments (instance method)">#<strong>remaining_arguments</strong> ⇒ Array<String> </a>
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
</span>
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
168
|
+
|
169
|
+
</li>
|
170
|
+
|
171
|
+
|
172
|
+
<li class="public ">
|
173
|
+
<span class="summary_signature">
|
174
|
+
|
175
|
+
<a href="#results-instance_method" title="#results (instance method)">#<strong>results</strong> ⇒ Array<ParameterResult> </a>
|
176
|
+
|
177
|
+
|
178
|
+
|
179
|
+
</span>
|
180
|
+
|
181
|
+
|
182
|
+
|
183
|
+
|
184
|
+
<span class="note title readonly">readonly</span>
|
185
|
+
|
186
|
+
|
187
|
+
|
188
|
+
|
189
|
+
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
|
194
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
195
|
+
|
196
|
+
</li>
|
197
|
+
|
198
|
+
|
199
|
+
</ul>
|
200
|
+
|
201
|
+
|
202
|
+
|
203
|
+
|
204
|
+
|
205
|
+
<h2>
|
206
|
+
Instance Method Summary
|
207
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
208
|
+
</h2>
|
209
|
+
|
210
|
+
<ul class="summary">
|
211
|
+
|
212
|
+
<li class="public ">
|
213
|
+
<span class="summary_signature">
|
214
|
+
|
215
|
+
<a href="#add_result-instance_method" title="#add_result (instance method)">#<strong>add_result</strong>(result) ⇒ Object </a>
|
216
|
+
|
217
|
+
|
218
|
+
|
219
|
+
</span>
|
220
|
+
|
221
|
+
|
222
|
+
|
223
|
+
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
<span class="summary_desc"><div class='inline'>
|
230
|
+
<p>Adds a ParameterResult.</p>
|
231
|
+
</div></span>
|
232
|
+
|
233
|
+
</li>
|
234
|
+
|
235
|
+
|
236
|
+
<li class="public ">
|
237
|
+
<span class="summary_signature">
|
238
|
+
|
239
|
+
<a href="#find_parameter-instance_method" title="#find_parameter (instance method)">#<strong>find_parameter</strong>(id) ⇒ ParameterResult </a>
|
240
|
+
|
241
|
+
|
242
|
+
|
243
|
+
</span>
|
244
|
+
|
245
|
+
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
<span class="summary_desc"><div class='inline'>
|
254
|
+
<p>Returns the first ParameterResult for a given parameter id.</p>
|
255
|
+
</div></span>
|
256
|
+
|
257
|
+
</li>
|
258
|
+
|
259
|
+
|
260
|
+
<li class="public ">
|
261
|
+
<span class="summary_signature">
|
262
|
+
|
263
|
+
<a href="#find_parameters-instance_method" title="#find_parameters (instance method)">#<strong>find_parameters</strong>(id) ⇒ Array<ParameterResult> </a>
|
264
|
+
|
265
|
+
|
266
|
+
|
267
|
+
</span>
|
268
|
+
|
269
|
+
|
270
|
+
|
271
|
+
|
272
|
+
|
273
|
+
|
274
|
+
|
275
|
+
|
276
|
+
|
277
|
+
<span class="summary_desc"><div class='inline'>
|
278
|
+
<p>Returns all ParameterResult(s) for a given parameter id.</p>
|
279
|
+
</div></span>
|
280
|
+
|
281
|
+
</li>
|
282
|
+
|
283
|
+
|
284
|
+
<li class="public ">
|
285
|
+
<span class="summary_signature">
|
286
|
+
|
287
|
+
<a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(syntax) ⇒ Result </a>
|
288
|
+
|
289
|
+
|
290
|
+
|
291
|
+
</span>
|
292
|
+
|
293
|
+
|
294
|
+
<span class="note title constructor">constructor</span>
|
295
|
+
|
296
|
+
|
297
|
+
|
298
|
+
|
299
|
+
|
300
|
+
|
301
|
+
|
302
|
+
|
303
|
+
<span class="summary_desc"><div class='inline'>
|
304
|
+
<p>Constructs a new Result.</p>
|
305
|
+
</div></span>
|
306
|
+
|
307
|
+
</li>
|
308
|
+
|
309
|
+
|
310
|
+
<li class="public ">
|
311
|
+
<span class="summary_signature">
|
312
|
+
|
313
|
+
<a href="#walk-instance_method" title="#walk (instance method)">#<strong>walk</strong>(&block) ⇒ Object </a>
|
314
|
+
|
315
|
+
|
316
|
+
|
317
|
+
</span>
|
318
|
+
|
319
|
+
|
320
|
+
|
321
|
+
|
322
|
+
|
323
|
+
|
324
|
+
|
325
|
+
|
326
|
+
|
327
|
+
<span class="summary_desc"><div class='inline'>
|
328
|
+
<p>Walks through this one.</p>
|
329
|
+
</div></span>
|
330
|
+
|
331
|
+
</li>
|
332
|
+
|
333
|
+
|
334
|
+
</ul>
|
335
|
+
|
336
|
+
|
337
|
+
<div id="constructor_details" class="method_details_list">
|
338
|
+
<h2>Constructor Details</h2>
|
339
|
+
|
340
|
+
<div class="method_details first">
|
341
|
+
<h3 class="signature first" id="initialize-instance_method">
|
342
|
+
|
343
|
+
#<strong>initialize</strong>(syntax) ⇒ <tt><span class='object_link'><a href="" title="TermUtils::AP::Result (class)">Result</a></span></tt>
|
344
|
+
|
345
|
+
|
346
|
+
|
347
|
+
|
348
|
+
|
349
|
+
</h3><div class="docstring">
|
350
|
+
<div class="discussion">
|
351
|
+
|
352
|
+
<p>Constructs a new Result.</p>
|
353
|
+
|
354
|
+
|
355
|
+
</div>
|
356
|
+
</div>
|
357
|
+
<div class="tags">
|
358
|
+
<p class="tag_title">Parameters:</p>
|
359
|
+
<ul class="param">
|
360
|
+
|
361
|
+
<li>
|
362
|
+
|
363
|
+
<span class='name'>syntax</span>
|
364
|
+
|
365
|
+
|
366
|
+
<span class='type'>(<tt><span class='object_link'><a href="Syntax.html" title="TermUtils::AP::Syntax (class)">Syntax</a></span></tt>)</span>
|
367
|
+
|
368
|
+
|
369
|
+
|
370
|
+
</li>
|
371
|
+
|
372
|
+
</ul>
|
373
|
+
|
374
|
+
|
375
|
+
</div><table class="source_code">
|
376
|
+
<tr>
|
377
|
+
<td>
|
378
|
+
<pre class="lines">
|
379
|
+
|
380
|
+
|
381
|
+
32
|
382
|
+
33
|
383
|
+
34
|
384
|
+
35
|
385
|
+
36</pre>
|
386
|
+
</td>
|
387
|
+
<td>
|
388
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 32</span>
|
389
|
+
|
390
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_syntax'>syntax</span><span class='rparen'>)</span>
|
391
|
+
<span class='ivar'>@syntax</span> <span class='op'>=</span> <span class='id identifier rubyid_syntax'>syntax</span>
|
392
|
+
<span class='ivar'>@results</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
|
393
|
+
<span class='ivar'>@remaining_arguments</span> <span class='op'>=</span> <span class='kw'>nil</span>
|
394
|
+
<span class='kw'>end</span></pre>
|
395
|
+
</td>
|
396
|
+
</tr>
|
397
|
+
</table>
|
398
|
+
</div>
|
399
|
+
|
400
|
+
</div>
|
401
|
+
|
402
|
+
<div id="instance_attr_details" class="attr_details">
|
403
|
+
<h2>Instance Attribute Details</h2>
|
404
|
+
|
405
|
+
|
406
|
+
<span id=""></span>
|
407
|
+
<div class="method_details first">
|
408
|
+
<h3 class="signature first" id="parameter-instance_method">
|
409
|
+
|
410
|
+
#<strong>parameter</strong> ⇒ <tt><span class='object_link'><a href="Syntax.html" title="TermUtils::AP::Syntax (class)">Syntax</a></span></tt> <span class="extras">(readonly)</span>
|
411
|
+
|
412
|
+
|
413
|
+
|
414
|
+
|
415
|
+
|
416
|
+
</h3><div class="docstring">
|
417
|
+
<div class="discussion">
|
418
|
+
|
419
|
+
|
420
|
+
</div>
|
421
|
+
</div>
|
422
|
+
<div class="tags">
|
423
|
+
|
424
|
+
<p class="tag_title">Returns:</p>
|
425
|
+
<ul class="return">
|
426
|
+
|
427
|
+
<li>
|
428
|
+
|
429
|
+
|
430
|
+
<span class='type'>(<tt><span class='object_link'><a href="Syntax.html" title="TermUtils::AP::Syntax (class)">Syntax</a></span></tt>)</span>
|
431
|
+
|
432
|
+
|
433
|
+
|
434
|
+
</li>
|
435
|
+
|
436
|
+
</ul>
|
437
|
+
|
438
|
+
</div><table class="source_code">
|
439
|
+
<tr>
|
440
|
+
<td>
|
441
|
+
<pre class="lines">
|
442
|
+
|
443
|
+
|
444
|
+
24
|
445
|
+
25
|
446
|
+
26</pre>
|
447
|
+
</td>
|
448
|
+
<td>
|
449
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 24</span>
|
450
|
+
|
451
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_parameter'>parameter</span>
|
452
|
+
<span class='ivar'>@parameter</span>
|
453
|
+
<span class='kw'>end</span></pre>
|
454
|
+
</td>
|
455
|
+
</tr>
|
456
|
+
</table>
|
457
|
+
</div>
|
458
|
+
|
459
|
+
|
460
|
+
<span id="remaining_arguments=-instance_method"></span>
|
461
|
+
<div class="method_details ">
|
462
|
+
<h3 class="signature " id="remaining_arguments-instance_method">
|
463
|
+
|
464
|
+
#<strong>remaining_arguments</strong> ⇒ <tt>Array<String></tt>
|
465
|
+
|
466
|
+
|
467
|
+
|
468
|
+
|
469
|
+
|
470
|
+
</h3><div class="docstring">
|
471
|
+
<div class="discussion">
|
472
|
+
|
473
|
+
|
474
|
+
</div>
|
475
|
+
</div>
|
476
|
+
<div class="tags">
|
477
|
+
|
478
|
+
<p class="tag_title">Returns:</p>
|
479
|
+
<ul class="return">
|
480
|
+
|
481
|
+
<li>
|
482
|
+
|
483
|
+
|
484
|
+
<span class='type'>(<tt>Array<String></tt>)</span>
|
485
|
+
|
486
|
+
|
487
|
+
|
488
|
+
</li>
|
489
|
+
|
490
|
+
</ul>
|
491
|
+
|
492
|
+
</div><table class="source_code">
|
493
|
+
<tr>
|
494
|
+
<td>
|
495
|
+
<pre class="lines">
|
496
|
+
|
497
|
+
|
498
|
+
28
|
499
|
+
29
|
500
|
+
30</pre>
|
501
|
+
</td>
|
502
|
+
<td>
|
503
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 28</span>
|
504
|
+
|
505
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_remaining_arguments'>remaining_arguments</span>
|
506
|
+
<span class='ivar'>@remaining_arguments</span>
|
507
|
+
<span class='kw'>end</span></pre>
|
508
|
+
</td>
|
509
|
+
</tr>
|
510
|
+
</table>
|
511
|
+
</div>
|
512
|
+
|
513
|
+
|
514
|
+
<span id=""></span>
|
515
|
+
<div class="method_details ">
|
516
|
+
<h3 class="signature " id="results-instance_method">
|
517
|
+
|
518
|
+
#<strong>results</strong> ⇒ <tt>Array<<span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span>></tt> <span class="extras">(readonly)</span>
|
519
|
+
|
520
|
+
|
521
|
+
|
522
|
+
|
523
|
+
|
524
|
+
</h3><div class="docstring">
|
525
|
+
<div class="discussion">
|
526
|
+
|
527
|
+
|
528
|
+
</div>
|
529
|
+
</div>
|
530
|
+
<div class="tags">
|
531
|
+
|
532
|
+
<p class="tag_title">Returns:</p>
|
533
|
+
<ul class="return">
|
534
|
+
|
535
|
+
<li>
|
536
|
+
|
537
|
+
|
538
|
+
<span class='type'>(<tt>Array<<span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span>></tt>)</span>
|
539
|
+
|
540
|
+
|
541
|
+
|
542
|
+
</li>
|
543
|
+
|
544
|
+
</ul>
|
545
|
+
|
546
|
+
</div><table class="source_code">
|
547
|
+
<tr>
|
548
|
+
<td>
|
549
|
+
<pre class="lines">
|
550
|
+
|
551
|
+
|
552
|
+
26
|
553
|
+
27
|
554
|
+
28</pre>
|
555
|
+
</td>
|
556
|
+
<td>
|
557
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 26</span>
|
558
|
+
|
559
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_results'>results</span>
|
560
|
+
<span class='ivar'>@results</span>
|
561
|
+
<span class='kw'>end</span></pre>
|
562
|
+
</td>
|
563
|
+
</tr>
|
564
|
+
</table>
|
565
|
+
</div>
|
566
|
+
|
567
|
+
</div>
|
568
|
+
|
569
|
+
|
570
|
+
<div id="instance_method_details" class="method_details_list">
|
571
|
+
<h2>Instance Method Details</h2>
|
572
|
+
|
573
|
+
|
574
|
+
<div class="method_details first">
|
575
|
+
<h3 class="signature first" id="add_result-instance_method">
|
576
|
+
|
577
|
+
#<strong>add_result</strong>(result) ⇒ <tt>Object</tt>
|
578
|
+
|
579
|
+
|
580
|
+
|
581
|
+
|
582
|
+
|
583
|
+
</h3><div class="docstring">
|
584
|
+
<div class="discussion">
|
585
|
+
|
586
|
+
<p>Adds a ParameterResult.</p>
|
587
|
+
|
588
|
+
|
589
|
+
</div>
|
590
|
+
</div>
|
591
|
+
<div class="tags">
|
592
|
+
<p class="tag_title">Parameters:</p>
|
593
|
+
<ul class="param">
|
594
|
+
|
595
|
+
<li>
|
596
|
+
|
597
|
+
<span class='name'>result</span>
|
598
|
+
|
599
|
+
|
600
|
+
<span class='type'>(<tt><span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span></tt>)</span>
|
601
|
+
|
602
|
+
|
603
|
+
|
604
|
+
</li>
|
605
|
+
|
606
|
+
</ul>
|
607
|
+
|
608
|
+
|
609
|
+
</div><table class="source_code">
|
610
|
+
<tr>
|
611
|
+
<td>
|
612
|
+
<pre class="lines">
|
613
|
+
|
614
|
+
|
615
|
+
40
|
616
|
+
41
|
617
|
+
42</pre>
|
618
|
+
</td>
|
619
|
+
<td>
|
620
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 40</span>
|
621
|
+
|
622
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_add_result'>add_result</span><span class='lparen'>(</span><span class='id identifier rubyid_result'>result</span><span class='rparen'>)</span>
|
623
|
+
<span class='ivar'>@results</span> <span class='op'><<</span> <span class='id identifier rubyid_result'>result</span>
|
624
|
+
<span class='kw'>end</span></pre>
|
625
|
+
</td>
|
626
|
+
</tr>
|
627
|
+
</table>
|
628
|
+
</div>
|
629
|
+
|
630
|
+
<div class="method_details ">
|
631
|
+
<h3 class="signature " id="find_parameter-instance_method">
|
632
|
+
|
633
|
+
#<strong>find_parameter</strong>(id) ⇒ <tt><span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span></tt>
|
634
|
+
|
635
|
+
|
636
|
+
|
637
|
+
|
638
|
+
|
639
|
+
</h3><div class="docstring">
|
640
|
+
<div class="discussion">
|
641
|
+
|
642
|
+
<p>Returns the first ParameterResult for a given parameter id.</p>
|
643
|
+
|
644
|
+
|
645
|
+
</div>
|
646
|
+
</div>
|
647
|
+
<div class="tags">
|
648
|
+
<p class="tag_title">Parameters:</p>
|
649
|
+
<ul class="param">
|
650
|
+
|
651
|
+
<li>
|
652
|
+
|
653
|
+
<span class='name'>id</span>
|
654
|
+
|
655
|
+
|
656
|
+
<span class='type'>(<tt>Symbol</tt>)</span>
|
657
|
+
|
658
|
+
|
659
|
+
|
660
|
+
</li>
|
661
|
+
|
662
|
+
</ul>
|
663
|
+
|
664
|
+
<p class="tag_title">Returns:</p>
|
665
|
+
<ul class="return">
|
666
|
+
|
667
|
+
<li>
|
668
|
+
|
669
|
+
|
670
|
+
<span class='type'>(<tt><span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span></tt>)</span>
|
671
|
+
|
672
|
+
|
673
|
+
|
674
|
+
</li>
|
675
|
+
|
676
|
+
</ul>
|
677
|
+
|
678
|
+
</div><table class="source_code">
|
679
|
+
<tr>
|
680
|
+
<td>
|
681
|
+
<pre class="lines">
|
682
|
+
|
683
|
+
|
684
|
+
47
|
685
|
+
48
|
686
|
+
49</pre>
|
687
|
+
</td>
|
688
|
+
<td>
|
689
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 47</span>
|
690
|
+
|
691
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_find_parameter'>find_parameter</span><span class='lparen'>(</span><span class='id identifier rubyid_id'>id</span><span class='rparen'>)</span>
|
692
|
+
<span class='ivar'>@results</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_r'>r</span><span class='op'>|</span> <span class='id identifier rubyid_r'>r</span><span class='period'>.</span><span class='id identifier rubyid_param_id'>param_id</span> <span class='op'>==</span> <span class='id identifier rubyid_id'>id</span> <span class='rbrace'>}</span>
|
693
|
+
<span class='kw'>end</span></pre>
|
694
|
+
</td>
|
695
|
+
</tr>
|
696
|
+
</table>
|
697
|
+
</div>
|
698
|
+
|
699
|
+
<div class="method_details ">
|
700
|
+
<h3 class="signature " id="find_parameters-instance_method">
|
701
|
+
|
702
|
+
#<strong>find_parameters</strong>(id) ⇒ <tt>Array<<span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span>></tt>
|
703
|
+
|
704
|
+
|
705
|
+
|
706
|
+
|
707
|
+
|
708
|
+
</h3><div class="docstring">
|
709
|
+
<div class="discussion">
|
710
|
+
|
711
|
+
<p>Returns all ParameterResult(s) for a given parameter id.</p>
|
712
|
+
|
713
|
+
|
714
|
+
</div>
|
715
|
+
</div>
|
716
|
+
<div class="tags">
|
717
|
+
<p class="tag_title">Parameters:</p>
|
718
|
+
<ul class="param">
|
719
|
+
|
720
|
+
<li>
|
721
|
+
|
722
|
+
<span class='name'>id</span>
|
723
|
+
|
724
|
+
|
725
|
+
<span class='type'>(<tt>Symbol</tt>)</span>
|
726
|
+
|
727
|
+
|
728
|
+
|
729
|
+
</li>
|
730
|
+
|
731
|
+
</ul>
|
732
|
+
|
733
|
+
<p class="tag_title">Returns:</p>
|
734
|
+
<ul class="return">
|
735
|
+
|
736
|
+
<li>
|
737
|
+
|
738
|
+
|
739
|
+
<span class='type'>(<tt>Array<<span class='object_link'><a href="ParameterResult.html" title="TermUtils::AP::ParameterResult (class)">ParameterResult</a></span>></tt>)</span>
|
740
|
+
|
741
|
+
|
742
|
+
|
743
|
+
</li>
|
744
|
+
|
745
|
+
</ul>
|
746
|
+
|
747
|
+
</div><table class="source_code">
|
748
|
+
<tr>
|
749
|
+
<td>
|
750
|
+
<pre class="lines">
|
751
|
+
|
752
|
+
|
753
|
+
54
|
754
|
+
55
|
755
|
+
56</pre>
|
756
|
+
</td>
|
757
|
+
<td>
|
758
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 54</span>
|
759
|
+
|
760
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_find_parameters'>find_parameters</span><span class='lparen'>(</span><span class='id identifier rubyid_id'>id</span><span class='rparen'>)</span>
|
761
|
+
<span class='ivar'>@results</span><span class='period'>.</span><span class='id identifier rubyid_find_all'>find_all</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_r'>r</span><span class='op'>|</span> <span class='id identifier rubyid_r'>r</span><span class='period'>.</span><span class='id identifier rubyid_param_id'>param_id</span> <span class='op'>==</span> <span class='id identifier rubyid_id'>id</span> <span class='rbrace'>}</span>
|
762
|
+
<span class='kw'>end</span></pre>
|
763
|
+
</td>
|
764
|
+
</tr>
|
765
|
+
</table>
|
766
|
+
</div>
|
767
|
+
|
768
|
+
<div class="method_details ">
|
769
|
+
<h3 class="signature " id="walk-instance_method">
|
770
|
+
|
771
|
+
#<strong>walk</strong>(&block) ⇒ <tt>Object</tt>
|
772
|
+
|
773
|
+
|
774
|
+
|
775
|
+
|
776
|
+
|
777
|
+
</h3><div class="docstring">
|
778
|
+
<div class="discussion">
|
779
|
+
|
780
|
+
<p>Walks through this one.</p>
|
781
|
+
|
782
|
+
|
783
|
+
</div>
|
784
|
+
</div>
|
785
|
+
<div class="tags">
|
786
|
+
|
787
|
+
|
788
|
+
</div><table class="source_code">
|
789
|
+
<tr>
|
790
|
+
<td>
|
791
|
+
<pre class="lines">
|
792
|
+
|
793
|
+
|
794
|
+
59
|
795
|
+
60
|
796
|
+
61
|
797
|
+
62
|
798
|
+
63
|
799
|
+
64
|
800
|
+
65
|
801
|
+
66
|
802
|
+
67
|
803
|
+
68
|
804
|
+
69</pre>
|
805
|
+
</td>
|
806
|
+
<td>
|
807
|
+
<pre class="code"><span class="info file"># File 'lib/term_utils/ap/result.rb', line 59</span>
|
808
|
+
|
809
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_walk'>walk</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_block'>block</span><span class='rparen'>)</span>
|
810
|
+
<span class='id identifier rubyid_walker'>walker</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="Walker.html" title="TermUtils::AP::Walker (class)">Walker</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Walker.html#initialize-instance_method" title="TermUtils::AP::Walker#initialize (method)">new</a></span></span>
|
811
|
+
<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_walker'>walker</span><span class='rparen'>)</span>
|
812
|
+
<span class='ivar'>@results</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>
|
813
|
+
<span class='id identifier rubyid_p'>p</span><span class='period'>.</span><span class='id identifier rubyid_results'>results</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_a'>a</span><span class='op'>|</span>
|
814
|
+
<span class='id identifier rubyid_walker'>walker</span><span class='period'>.</span><span class='id identifier rubyid_notify_article'>notify_article</span><span class='lparen'>(</span><span class='id identifier rubyid_a'>a</span><span class='rparen'>)</span>
|
815
|
+
<span class='kw'>end</span>
|
816
|
+
<span class='id identifier rubyid_walker'>walker</span><span class='period'>.</span><span class='id identifier rubyid_notify_parameter'>notify_parameter</span><span class='lparen'>(</span><span class='id identifier rubyid_p'>p</span><span class='rparen'>)</span>
|
817
|
+
<span class='kw'>end</span>
|
818
|
+
<span class='id identifier rubyid_walker'>walker</span><span class='period'>.</span><span class='id identifier rubyid_notify_finished'>notify_finished</span><span class='lparen'>(</span><span class='ivar'>@remaining_arguments</span><span class='rparen'>)</span>
|
819
|
+
<span class='kw'>end</span></pre>
|
820
|
+
</td>
|
821
|
+
</tr>
|
822
|
+
</table>
|
823
|
+
</div>
|
824
|
+
|
825
|
+
</div>
|
826
|
+
|
827
|
+
</div>
|
828
|
+
|
829
|
+
<div id="footer">
|
830
|
+
Generated on Sun Aug 2 18:35:09 2020 by
|
831
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
832
|
+
0.9.25 (ruby-2.6.5).
|
833
|
+
</div>
|
834
|
+
|
835
|
+
</div>
|
836
|
+
</body>
|
837
|
+
</html>
|