csv_decision2 0.5.1
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 +7 -0
- data/.codeclimate.yml +3 -0
- data/.coveralls.yml +2 -0
- data/.gitignore +14 -0
- data/.rspec +2 -0
- data/.rubocop.yml +30 -0
- data/.travis.yml +6 -0
- data/CHANGELOG.md +85 -0
- data/Dockerfile +6 -0
- data/Gemfile +7 -0
- data/LICENSE +21 -0
- data/README.md +356 -0
- data/benchmarks/rufus_decision.rb +158 -0
- data/csv_decision2.gemspec +38 -0
- data/doc/CSVDecision/CellValidationError.html +143 -0
- data/doc/CSVDecision/Columns/Default.html +589 -0
- data/doc/CSVDecision/Columns/Dictionary.html +801 -0
- data/doc/CSVDecision/Columns/Entry.html +508 -0
- data/doc/CSVDecision/Columns.html +1259 -0
- data/doc/CSVDecision/Constant.html +254 -0
- data/doc/CSVDecision/Data.html +479 -0
- data/doc/CSVDecision/Decide.html +302 -0
- data/doc/CSVDecision/Decision.html +1011 -0
- data/doc/CSVDecision/Defaults.html +291 -0
- data/doc/CSVDecision/Dictionary/Entry.html +1147 -0
- data/doc/CSVDecision/Dictionary.html +426 -0
- data/doc/CSVDecision/Error.html +139 -0
- data/doc/CSVDecision/FileError.html +143 -0
- data/doc/CSVDecision/Function.html +240 -0
- data/doc/CSVDecision/Guard.html +245 -0
- data/doc/CSVDecision/Header.html +647 -0
- data/doc/CSVDecision/Index.html +741 -0
- data/doc/CSVDecision/Input.html +404 -0
- data/doc/CSVDecision/Load.html +296 -0
- data/doc/CSVDecision/Matchers/Constant.html +484 -0
- data/doc/CSVDecision/Matchers/Function.html +511 -0
- data/doc/CSVDecision/Matchers/Guard.html +503 -0
- data/doc/CSVDecision/Matchers/Matcher.html +507 -0
- data/doc/CSVDecision/Matchers/Numeric.html +415 -0
- data/doc/CSVDecision/Matchers/Pattern.html +491 -0
- data/doc/CSVDecision/Matchers/Proc.html +704 -0
- data/doc/CSVDecision/Matchers/Range.html +379 -0
- data/doc/CSVDecision/Matchers/Symbol.html +426 -0
- data/doc/CSVDecision/Matchers.html +1567 -0
- data/doc/CSVDecision/Numeric.html +259 -0
- data/doc/CSVDecision/Options.html +443 -0
- data/doc/CSVDecision/Parse.html +282 -0
- data/doc/CSVDecision/Paths.html +742 -0
- data/doc/CSVDecision/Result.html +1200 -0
- data/doc/CSVDecision/Scan/InputHashes.html +369 -0
- data/doc/CSVDecision/Scan.html +313 -0
- data/doc/CSVDecision/ScanRow.html +866 -0
- data/doc/CSVDecision/Symbol.html +256 -0
- data/doc/CSVDecision/Table.html +1470 -0
- data/doc/CSVDecision/TableValidationError.html +143 -0
- data/doc/CSVDecision/Validate.html +422 -0
- data/doc/CSVDecision.html +621 -0
- data/doc/_index.html +471 -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 +499 -0
- data/doc/file.README.html +421 -0
- data/doc/file_list.html +56 -0
- data/doc/frames.html +17 -0
- data/doc/index.html +421 -0
- data/doc/js/app.js +248 -0
- data/doc/js/full_list.js +216 -0
- data/doc/js/jquery.js +4 -0
- data/doc/method_list.html +1163 -0
- data/doc/top-level-namespace.html +110 -0
- data/docker-compose.yml +13 -0
- data/lib/csv_decision/columns.rb +192 -0
- data/lib/csv_decision/data.rb +92 -0
- data/lib/csv_decision/decision.rb +196 -0
- data/lib/csv_decision/defaults.rb +47 -0
- data/lib/csv_decision/dictionary.rb +180 -0
- data/lib/csv_decision/header.rb +83 -0
- data/lib/csv_decision/index.rb +107 -0
- data/lib/csv_decision/input.rb +121 -0
- data/lib/csv_decision/load.rb +36 -0
- data/lib/csv_decision/matchers/constant.rb +74 -0
- data/lib/csv_decision/matchers/function.rb +56 -0
- data/lib/csv_decision/matchers/guard.rb +142 -0
- data/lib/csv_decision/matchers/numeric.rb +44 -0
- data/lib/csv_decision/matchers/pattern.rb +94 -0
- data/lib/csv_decision/matchers/range.rb +95 -0
- data/lib/csv_decision/matchers/symbol.rb +149 -0
- data/lib/csv_decision/matchers.rb +220 -0
- data/lib/csv_decision/options.rb +124 -0
- data/lib/csv_decision/parse.rb +165 -0
- data/lib/csv_decision/paths.rb +78 -0
- data/lib/csv_decision/result.rb +204 -0
- data/lib/csv_decision/scan.rb +117 -0
- data/lib/csv_decision/scan_row.rb +142 -0
- data/lib/csv_decision/table.rb +101 -0
- data/lib/csv_decision/validate.rb +85 -0
- data/lib/csv_decision.rb +45 -0
- data/spec/csv_decision/columns_spec.rb +251 -0
- data/spec/csv_decision/constant_spec.rb +36 -0
- data/spec/csv_decision/data_spec.rb +50 -0
- data/spec/csv_decision/decision_spec.rb +19 -0
- data/spec/csv_decision/examples_spec.rb +242 -0
- data/spec/csv_decision/index_spec.rb +58 -0
- data/spec/csv_decision/input_spec.rb +55 -0
- data/spec/csv_decision/load_spec.rb +28 -0
- data/spec/csv_decision/matchers/function_spec.rb +82 -0
- data/spec/csv_decision/matchers/guard_spec.rb +170 -0
- data/spec/csv_decision/matchers/numeric_spec.rb +47 -0
- data/spec/csv_decision/matchers/pattern_spec.rb +183 -0
- data/spec/csv_decision/matchers/range_spec.rb +70 -0
- data/spec/csv_decision/matchers/symbol_spec.rb +67 -0
- data/spec/csv_decision/options_spec.rb +94 -0
- data/spec/csv_decision/parse_spec.rb +44 -0
- data/spec/csv_decision/table_spec.rb +683 -0
- data/spec/csv_decision_spec.rb +7 -0
- data/spec/data/invalid/empty.csv +0 -0
- data/spec/data/invalid/invalid_header1.csv +4 -0
- data/spec/data/invalid/invalid_header2.csv +4 -0
- data/spec/data/invalid/invalid_header3.csv +4 -0
- data/spec/data/invalid/invalid_header4.csv +4 -0
- data/spec/data/valid/benchmark_regexp.csv +10 -0
- data/spec/data/valid/index_example.csv +13 -0
- data/spec/data/valid/multi_column_index.csv +10 -0
- data/spec/data/valid/multi_column_index2.csv +12 -0
- data/spec/data/valid/options_in_file1.csv +5 -0
- data/spec/data/valid/options_in_file2.csv +5 -0
- data/spec/data/valid/options_in_file3.csv +13 -0
- data/spec/data/valid/regular_expressions.csv +11 -0
- data/spec/data/valid/simple_constants.csv +5 -0
- data/spec/data/valid/simple_example.csv +10 -0
- data/spec/data/valid/valid.csv +4 -0
- data/spec/spec_helper.rb +106 -0
- metadata +352 -0
@@ -0,0 +1,1259 @@
|
|
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: CSVDecision::Columns
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.12
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
|
16
|
+
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
18
|
+
pathId = "CSVDecision::Columns";
|
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 (C)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../CSVDecision.html" title="CSVDecision (module)">CSVDecision</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">Columns</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: CSVDecision::Columns
|
63
|
+
|
64
|
+
|
65
|
+
<span class="private note title">Private</span>
|
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">CSVDecision::Columns</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/csv_decision/columns.rb</dd>
|
98
|
+
</dl>
|
99
|
+
|
100
|
+
</div>
|
101
|
+
|
102
|
+
<h2>Overview</h2><div class="docstring">
|
103
|
+
<div class="discussion">
|
104
|
+
<p class="note private">
|
105
|
+
<strong>This class is part of a private API.</strong>
|
106
|
+
You should avoid using this class if possible, as it may be removed or be changed in the future.
|
107
|
+
</p>
|
108
|
+
|
109
|
+
<p>Dictionary of all this table's columns - inputs, outputs etc.</p>
|
110
|
+
|
111
|
+
|
112
|
+
</div>
|
113
|
+
</div>
|
114
|
+
<div class="tags">
|
115
|
+
|
116
|
+
|
117
|
+
</div><h2>Defined Under Namespace</h2>
|
118
|
+
<p class="children">
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Columns/Dictionary.html" title="CSVDecision::Columns::Dictionary (class)">Dictionary</a></span>
|
124
|
+
|
125
|
+
|
126
|
+
</p>
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
<h2>
|
136
|
+
Class Method Summary
|
137
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
138
|
+
</h2>
|
139
|
+
|
140
|
+
<ul class="summary">
|
141
|
+
|
142
|
+
<li class="public ">
|
143
|
+
<span class="summary_signature">
|
144
|
+
|
145
|
+
<a href="#ins_cell_dictionary-class_method" title="ins_cell_dictionary (class method)">.<strong>ins_cell_dictionary</strong>(columns:, cell:) ⇒ void </a>
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
</span>
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
|
156
|
+
<span class="private note title">private</span>
|
157
|
+
|
158
|
+
|
159
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
160
|
+
|
161
|
+
</li>
|
162
|
+
|
163
|
+
|
164
|
+
<li class="public ">
|
165
|
+
<span class="summary_signature">
|
166
|
+
|
167
|
+
<a href="#ins_dictionary-class_method" title="ins_dictionary (class method)">.<strong>ins_dictionary</strong>(columns:, row:) ⇒ void </a>
|
168
|
+
|
169
|
+
|
170
|
+
|
171
|
+
</span>
|
172
|
+
|
173
|
+
|
174
|
+
|
175
|
+
|
176
|
+
|
177
|
+
|
178
|
+
<span class="private note title">private</span>
|
179
|
+
|
180
|
+
|
181
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
182
|
+
|
183
|
+
</li>
|
184
|
+
|
185
|
+
|
186
|
+
<li class="public ">
|
187
|
+
<span class="summary_signature">
|
188
|
+
|
189
|
+
<a href="#outs_dictionary-class_method" title="outs_dictionary (class method)">.<strong>outs_dictionary</strong>(columns:, row:) ⇒ void </a>
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
</span>
|
194
|
+
|
195
|
+
|
196
|
+
|
197
|
+
|
198
|
+
|
199
|
+
|
200
|
+
<span class="private note title">private</span>
|
201
|
+
|
202
|
+
|
203
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
204
|
+
|
205
|
+
</li>
|
206
|
+
|
207
|
+
|
208
|
+
</ul>
|
209
|
+
|
210
|
+
<h2>
|
211
|
+
Instance Method Summary
|
212
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
213
|
+
</h2>
|
214
|
+
|
215
|
+
<ul class="summary">
|
216
|
+
|
217
|
+
<li class="public ">
|
218
|
+
<span class="summary_signature">
|
219
|
+
|
220
|
+
<a href="#defaults-instance_method" title="#defaults (instance method)">#<strong>defaults</strong> ⇒ Object </a>
|
221
|
+
|
222
|
+
|
223
|
+
|
224
|
+
</span>
|
225
|
+
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
|
230
|
+
|
231
|
+
<span class="private note title">private</span>
|
232
|
+
|
233
|
+
|
234
|
+
<span class="summary_desc"><div class='inline'>
|
235
|
+
<p>Input columns with defaults specified.</p>
|
236
|
+
</div></span>
|
237
|
+
|
238
|
+
</li>
|
239
|
+
|
240
|
+
|
241
|
+
<li class="public ">
|
242
|
+
<span class="summary_signature">
|
243
|
+
|
244
|
+
<a href="#defaults=-instance_method" title="#defaults= (instance method)">#<strong>defaults=</strong>(value) ⇒ Object </a>
|
245
|
+
|
246
|
+
|
247
|
+
|
248
|
+
</span>
|
249
|
+
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
|
254
|
+
|
255
|
+
<span class="private note title">private</span>
|
256
|
+
|
257
|
+
|
258
|
+
<span class="summary_desc"><div class='inline'>
|
259
|
+
<p>Set defaults for columns with defaults specified.</p>
|
260
|
+
</div></span>
|
261
|
+
|
262
|
+
</li>
|
263
|
+
|
264
|
+
|
265
|
+
<li class="public ">
|
266
|
+
<span class="summary_signature">
|
267
|
+
|
268
|
+
<a href="#dictionary-instance_method" title="#dictionary (instance method)">#<strong>dictionary</strong> ⇒ Hash{Symbol=>[false, Integer]} </a>
|
269
|
+
|
270
|
+
|
271
|
+
|
272
|
+
</span>
|
273
|
+
|
274
|
+
|
275
|
+
|
276
|
+
|
277
|
+
|
278
|
+
|
279
|
+
<span class="private note title">private</span>
|
280
|
+
|
281
|
+
|
282
|
+
<span class="summary_desc"><div class='inline'>
|
283
|
+
<p>Dictionary of all input and output column names.</p>
|
284
|
+
</div></span>
|
285
|
+
|
286
|
+
</li>
|
287
|
+
|
288
|
+
|
289
|
+
<li class="public ">
|
290
|
+
<span class="summary_signature">
|
291
|
+
|
292
|
+
<a href="#ifs-instance_method" title="#ifs (instance method)">#<strong>ifs</strong> ⇒ Hash{Index=>Entry} </a>
|
293
|
+
|
294
|
+
|
295
|
+
|
296
|
+
</span>
|
297
|
+
|
298
|
+
|
299
|
+
|
300
|
+
|
301
|
+
|
302
|
+
|
303
|
+
<span class="private note title">private</span>
|
304
|
+
|
305
|
+
|
306
|
+
<span class="summary_desc"><div class='inline'>
|
307
|
+
<p>if: columns hash keyed by column index.</p>
|
308
|
+
</div></span>
|
309
|
+
|
310
|
+
</li>
|
311
|
+
|
312
|
+
|
313
|
+
<li class="public ">
|
314
|
+
<span class="summary_signature">
|
315
|
+
|
316
|
+
<a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(table) ⇒ Columns </a>
|
317
|
+
|
318
|
+
|
319
|
+
|
320
|
+
</span>
|
321
|
+
|
322
|
+
|
323
|
+
<span class="note title constructor">constructor</span>
|
324
|
+
|
325
|
+
|
326
|
+
|
327
|
+
|
328
|
+
|
329
|
+
<span class="private note title">private</span>
|
330
|
+
|
331
|
+
|
332
|
+
<span class="summary_desc"><div class='inline'>
|
333
|
+
<p>A new instance of Columns.</p>
|
334
|
+
</div></span>
|
335
|
+
|
336
|
+
</li>
|
337
|
+
|
338
|
+
|
339
|
+
<li class="public ">
|
340
|
+
<span class="summary_signature">
|
341
|
+
|
342
|
+
<a href="#input_keys-instance_method" title="#input_keys (instance method)">#<strong>input_keys</strong> ⇒ Array<Symbol> </a>
|
343
|
+
|
344
|
+
|
345
|
+
|
346
|
+
</span>
|
347
|
+
|
348
|
+
|
349
|
+
|
350
|
+
|
351
|
+
|
352
|
+
|
353
|
+
<span class="private note title">private</span>
|
354
|
+
|
355
|
+
|
356
|
+
<span class="summary_desc"><div class='inline'>
|
357
|
+
<p>All input column symbols.</p>
|
358
|
+
</div></span>
|
359
|
+
|
360
|
+
</li>
|
361
|
+
|
362
|
+
|
363
|
+
<li class="public ">
|
364
|
+
<span class="summary_signature">
|
365
|
+
|
366
|
+
<a href="#ins-instance_method" title="#ins (instance method)">#<strong>ins</strong> ⇒ Hash{Index=>Entry} </a>
|
367
|
+
|
368
|
+
|
369
|
+
|
370
|
+
</span>
|
371
|
+
|
372
|
+
|
373
|
+
|
374
|
+
|
375
|
+
|
376
|
+
|
377
|
+
<span class="private note title">private</span>
|
378
|
+
|
379
|
+
|
380
|
+
<span class="summary_desc"><div class='inline'>
|
381
|
+
<p>Input columns hash keyed by column index.</p>
|
382
|
+
</div></span>
|
383
|
+
|
384
|
+
</li>
|
385
|
+
|
386
|
+
|
387
|
+
<li class="public ">
|
388
|
+
<span class="summary_signature">
|
389
|
+
|
390
|
+
<a href="#outs-instance_method" title="#outs (instance method)">#<strong>outs</strong> ⇒ Hash{Index=>Entry} </a>
|
391
|
+
|
392
|
+
|
393
|
+
|
394
|
+
</span>
|
395
|
+
|
396
|
+
|
397
|
+
|
398
|
+
|
399
|
+
|
400
|
+
|
401
|
+
<span class="private note title">private</span>
|
402
|
+
|
403
|
+
|
404
|
+
<span class="summary_desc"><div class='inline'>
|
405
|
+
<p>Output columns hash keyed by column index.</p>
|
406
|
+
</div></span>
|
407
|
+
|
408
|
+
</li>
|
409
|
+
|
410
|
+
|
411
|
+
<li class="public ">
|
412
|
+
<span class="summary_signature">
|
413
|
+
|
414
|
+
<a href="#paths-instance_method" title="#paths (instance method)">#<strong>paths</strong> ⇒ Hash{Index=>Entry} </a>
|
415
|
+
|
416
|
+
|
417
|
+
|
418
|
+
</span>
|
419
|
+
|
420
|
+
|
421
|
+
|
422
|
+
|
423
|
+
|
424
|
+
|
425
|
+
<span class="private note title">private</span>
|
426
|
+
|
427
|
+
|
428
|
+
<span class="summary_desc"><div class='inline'>
|
429
|
+
<p>path: columns hash keyed by column index.</p>
|
430
|
+
</div></span>
|
431
|
+
|
432
|
+
</li>
|
433
|
+
|
434
|
+
|
435
|
+
</ul>
|
436
|
+
|
437
|
+
|
438
|
+
<div id="constructor_details" class="method_details_list">
|
439
|
+
<h2>Constructor Details</h2>
|
440
|
+
|
441
|
+
<div class="method_details first">
|
442
|
+
<h3 class="signature first" id="initialize-instance_method">
|
443
|
+
|
444
|
+
#<strong>initialize</strong>(table) ⇒ <tt><span class='object_link'><a href="" title="CSVDecision::Columns (class)">Columns</a></span></tt>
|
445
|
+
|
446
|
+
|
447
|
+
|
448
|
+
|
449
|
+
|
450
|
+
</h3><div class="docstring">
|
451
|
+
<div class="discussion">
|
452
|
+
<p class="note private">
|
453
|
+
<strong>This method is part of a private API.</strong>
|
454
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
455
|
+
</p>
|
456
|
+
|
457
|
+
<p>Returns a new instance of Columns</p>
|
458
|
+
|
459
|
+
|
460
|
+
</div>
|
461
|
+
</div>
|
462
|
+
<div class="tags">
|
463
|
+
<p class="tag_title">Parameters:</p>
|
464
|
+
<ul class="param">
|
465
|
+
|
466
|
+
<li>
|
467
|
+
|
468
|
+
<span class='name'>table</span>
|
469
|
+
|
470
|
+
|
471
|
+
<span class='type'>(<tt><span class='object_link'><a href="Table.html" title="CSVDecision::Table (class)">Table</a></span></tt>)</span>
|
472
|
+
|
473
|
+
|
474
|
+
|
475
|
+
—
|
476
|
+
<div class='inline'>
|
477
|
+
<p>Decision table being constructed.</p>
|
478
|
+
</div>
|
479
|
+
|
480
|
+
</li>
|
481
|
+
|
482
|
+
</ul>
|
483
|
+
|
484
|
+
<p class="tag_title">Raises:</p>
|
485
|
+
<ul class="raise">
|
486
|
+
|
487
|
+
<li>
|
488
|
+
|
489
|
+
|
490
|
+
<span class='type'>(<tt><span class='object_link'><a href="TableValidationError.html" title="CSVDecision::TableValidationError (class)">TableValidationError</a></span></tt>)</span>
|
491
|
+
|
492
|
+
|
493
|
+
|
494
|
+
</li>
|
495
|
+
|
496
|
+
</ul>
|
497
|
+
|
498
|
+
</div><table class="source_code">
|
499
|
+
<tr>
|
500
|
+
<td>
|
501
|
+
<pre class="lines">
|
502
|
+
|
503
|
+
|
504
|
+
178
|
505
|
+
179
|
506
|
+
180
|
507
|
+
181
|
508
|
+
182
|
509
|
+
183
|
510
|
+
184
|
511
|
+
185
|
512
|
+
186
|
513
|
+
187
|
514
|
+
188
|
515
|
+
189
|
516
|
+
190</pre>
|
517
|
+
</td>
|
518
|
+
<td>
|
519
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 178</span>
|
520
|
+
|
521
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_table'>table</span><span class='rparen'>)</span>
|
522
|
+
<span class='comment'># If a column does not have a valid header cell, then it's empty of data.
|
523
|
+
</span> <span class='comment'># Return the stripped header row, and remove it from the data array.
|
524
|
+
</span> <span class='id identifier rubyid_row'>row</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="Header.html" title="CSVDecision::Header (module)">Header</a></span></span><span class='period'>.</span><span class='id identifier rubyid_strip_empty_columns'><span class='object_link'><a href="Header.html#strip_empty_columns-class_method" title="CSVDecision::Header.strip_empty_columns (method)">strip_empty_columns</a></span></span><span class='lparen'>(</span><span class='label'>rows:</span> <span class='id identifier rubyid_table'>table</span><span class='period'>.</span><span class='id identifier rubyid_rows'>rows</span><span class='rparen'>)</span>
|
525
|
+
|
526
|
+
<span class='comment'># No header row found?
|
527
|
+
</span> <span class='id identifier rubyid_raise'>raise</span> <span class='const'><span class='object_link'><a href="TableValidationError.html" title="CSVDecision::TableValidationError (class)">TableValidationError</a></span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>table has no header row</span><span class='tstring_end'>'</span></span> <span class='kw'>unless</span> <span class='id identifier rubyid_row'>row</span>
|
528
|
+
|
529
|
+
<span class='comment'># Build a dictionary of all valid data columns from the header row.
|
530
|
+
</span> <span class='ivar'>@dictionary</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="../CSVDecision.html" title="CSVDecision (module)">CSVDecision</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Dictionary.html" title="CSVDecision::Dictionary (module)">Dictionary</a></span></span><span class='period'>.</span><span class='id identifier rubyid_build'><span class='object_link'><a href="Dictionary.html#build-class_method" title="CSVDecision::Dictionary.build (method)">build</a></span></span><span class='lparen'>(</span><span class='label'>header:</span> <span class='id identifier rubyid_row'>row</span><span class='comma'>,</span> <span class='label'>dictionary:</span> <span class='const'><span class='object_link'><a href="Columns/Dictionary.html" title="CSVDecision::Columns::Dictionary (class)">Dictionary</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Columns/Dictionary.html#initialize-instance_method" title="CSVDecision::Columns::Dictionary#initialize (method)">new</a></span></span><span class='rparen'>)</span>
|
531
|
+
|
532
|
+
<span class='id identifier rubyid_freeze'>freeze</span>
|
533
|
+
<span class='kw'>end</span></pre>
|
534
|
+
</td>
|
535
|
+
</tr>
|
536
|
+
</table>
|
537
|
+
</div>
|
538
|
+
|
539
|
+
</div>
|
540
|
+
|
541
|
+
|
542
|
+
<div id="class_method_details" class="method_details_list">
|
543
|
+
<h2>Class Method Details</h2>
|
544
|
+
|
545
|
+
|
546
|
+
<div class="method_details first">
|
547
|
+
<h3 class="signature first" id="ins_cell_dictionary-class_method">
|
548
|
+
|
549
|
+
.<strong>ins_cell_dictionary</strong>(columns:, cell:) ⇒ <tt>void</tt>
|
550
|
+
|
551
|
+
|
552
|
+
|
553
|
+
|
554
|
+
|
555
|
+
</h3><div class="docstring">
|
556
|
+
<div class="discussion">
|
557
|
+
<p class="note private">
|
558
|
+
<strong>This method is part of a private API.</strong>
|
559
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
560
|
+
</p>
|
561
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
562
|
+
|
563
|
+
</div>
|
564
|
+
</div>
|
565
|
+
<div class="tags">
|
566
|
+
<p class="tag_title">Parameters:</p>
|
567
|
+
<ul class="param">
|
568
|
+
|
569
|
+
<li>
|
570
|
+
|
571
|
+
<span class='name'>columns</span>
|
572
|
+
|
573
|
+
|
574
|
+
<span class='type'>(<tt><span class='object_link'><a href="" title="CSVDecision::Columns (class)">CSVDecision::Columns</a></span></tt>)</span>
|
575
|
+
|
576
|
+
|
577
|
+
|
578
|
+
—
|
579
|
+
<div class='inline'>
|
580
|
+
<p>Table's columns dictionary.</p>
|
581
|
+
</div>
|
582
|
+
|
583
|
+
</li>
|
584
|
+
|
585
|
+
<li>
|
586
|
+
|
587
|
+
<span class='name'>cell</span>
|
588
|
+
|
589
|
+
|
590
|
+
<span class='type'>(<tt>Object</tt>)</span>
|
591
|
+
|
592
|
+
|
593
|
+
|
594
|
+
—
|
595
|
+
<div class='inline'>
|
596
|
+
<p>Data row cell.</p>
|
597
|
+
</div>
|
598
|
+
|
599
|
+
</li>
|
600
|
+
|
601
|
+
</ul>
|
602
|
+
|
603
|
+
|
604
|
+
</div><table class="source_code">
|
605
|
+
<tr>
|
606
|
+
<td>
|
607
|
+
<pre class="lines">
|
608
|
+
|
609
|
+
|
610
|
+
30
|
611
|
+
31
|
612
|
+
32
|
613
|
+
33
|
614
|
+
34
|
615
|
+
35</pre>
|
616
|
+
</td>
|
617
|
+
<td>
|
618
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 30</span>
|
619
|
+
|
620
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_ins_cell_dictionary'>ins_cell_dictionary</span><span class='lparen'>(</span><span class='label'>columns:</span><span class='comma'>,</span> <span class='label'>cell:</span><span class='rparen'>)</span>
|
621
|
+
<span class='kw'>return</span> <span class='kw'>unless</span> <span class='id identifier rubyid_cell'>cell</span><span class='period'>.</span><span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span><span class='const'><span class='object_link'><a href="Matchers.html" title="CSVDecision::Matchers (class)">Matchers</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Matchers/Proc.html" title="CSVDecision::Matchers::Proc (class)">Proc</a></span></span><span class='rparen'>)</span>
|
622
|
+
<span class='kw'>return</span> <span class='kw'>if</span> <span class='id identifier rubyid_cell'>cell</span><span class='period'>.</span><span class='id identifier rubyid_symbols'>symbols</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span>
|
623
|
+
|
624
|
+
<span class='id identifier rubyid_add_ins_symbols'>add_ins_symbols</span><span class='lparen'>(</span><span class='label'>columns:</span> <span class='id identifier rubyid_columns'>columns</span><span class='comma'>,</span> <span class='label'>cell:</span> <span class='id identifier rubyid_cell'>cell</span><span class='rparen'>)</span>
|
625
|
+
<span class='kw'>end</span></pre>
|
626
|
+
</td>
|
627
|
+
</tr>
|
628
|
+
</table>
|
629
|
+
</div>
|
630
|
+
|
631
|
+
<div class="method_details ">
|
632
|
+
<h3 class="signature " id="ins_dictionary-class_method">
|
633
|
+
|
634
|
+
.<strong>ins_dictionary</strong>(columns:, row:) ⇒ <tt>void</tt>
|
635
|
+
|
636
|
+
|
637
|
+
|
638
|
+
|
639
|
+
|
640
|
+
</h3><div class="docstring">
|
641
|
+
<div class="discussion">
|
642
|
+
<p class="note private">
|
643
|
+
<strong>This method is part of a private API.</strong>
|
644
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
645
|
+
</p>
|
646
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
647
|
+
|
648
|
+
</div>
|
649
|
+
</div>
|
650
|
+
<div class="tags">
|
651
|
+
<p class="tag_title">Parameters:</p>
|
652
|
+
<ul class="param">
|
653
|
+
|
654
|
+
<li>
|
655
|
+
|
656
|
+
<span class='name'>columns</span>
|
657
|
+
|
658
|
+
|
659
|
+
<span class='type'>(<tt><span class='object_link'><a href="" title="CSVDecision::Columns (class)">CSVDecision::Columns</a></span></tt>)</span>
|
660
|
+
|
661
|
+
|
662
|
+
|
663
|
+
—
|
664
|
+
<div class='inline'>
|
665
|
+
<p>Table's columns dictionary.</p>
|
666
|
+
</div>
|
667
|
+
|
668
|
+
</li>
|
669
|
+
|
670
|
+
<li>
|
671
|
+
|
672
|
+
<span class='name'>row</span>
|
673
|
+
|
674
|
+
|
675
|
+
<span class='type'>(<tt>Array</tt>)</span>
|
676
|
+
|
677
|
+
|
678
|
+
|
679
|
+
—
|
680
|
+
<div class='inline'>
|
681
|
+
<p>Data row.</p>
|
682
|
+
</div>
|
683
|
+
|
684
|
+
</li>
|
685
|
+
|
686
|
+
</ul>
|
687
|
+
|
688
|
+
|
689
|
+
</div><table class="source_code">
|
690
|
+
<tr>
|
691
|
+
<td>
|
692
|
+
<pre class="lines">
|
693
|
+
|
694
|
+
|
695
|
+
23
|
696
|
+
24
|
697
|
+
25</pre>
|
698
|
+
</td>
|
699
|
+
<td>
|
700
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 23</span>
|
701
|
+
|
702
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_ins_dictionary'>ins_dictionary</span><span class='lparen'>(</span><span class='label'>columns:</span><span class='comma'>,</span> <span class='label'>row:</span><span class='rparen'>)</span>
|
703
|
+
<span class='id identifier rubyid_row'>row</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_cell'>cell</span><span class='op'>|</span> <span class='id identifier rubyid_ins_cell_dictionary'>ins_cell_dictionary</span><span class='lparen'>(</span><span class='label'>columns:</span> <span class='id identifier rubyid_columns'>columns</span><span class='comma'>,</span> <span class='label'>cell:</span> <span class='id identifier rubyid_cell'>cell</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
|
704
|
+
<span class='kw'>end</span></pre>
|
705
|
+
</td>
|
706
|
+
</tr>
|
707
|
+
</table>
|
708
|
+
</div>
|
709
|
+
|
710
|
+
<div class="method_details ">
|
711
|
+
<h3 class="signature " id="outs_dictionary-class_method">
|
712
|
+
|
713
|
+
.<strong>outs_dictionary</strong>(columns:, row:) ⇒ <tt>void</tt>
|
714
|
+
|
715
|
+
|
716
|
+
|
717
|
+
|
718
|
+
|
719
|
+
</h3><div class="docstring">
|
720
|
+
<div class="discussion">
|
721
|
+
<p class="note private">
|
722
|
+
<strong>This method is part of a private API.</strong>
|
723
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
724
|
+
</p>
|
725
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
726
|
+
|
727
|
+
</div>
|
728
|
+
</div>
|
729
|
+
<div class="tags">
|
730
|
+
<p class="tag_title">Parameters:</p>
|
731
|
+
<ul class="param">
|
732
|
+
|
733
|
+
<li>
|
734
|
+
|
735
|
+
<span class='name'>columns</span>
|
736
|
+
|
737
|
+
|
738
|
+
<span class='type'>(<tt><span class='object_link'><a href="" title="CSVDecision::Columns (class)">CSVDecision::Columns</a></span></tt>)</span>
|
739
|
+
|
740
|
+
|
741
|
+
|
742
|
+
—
|
743
|
+
<div class='inline'>
|
744
|
+
<p>Table's columns dictionary.</p>
|
745
|
+
</div>
|
746
|
+
|
747
|
+
</li>
|
748
|
+
|
749
|
+
<li>
|
750
|
+
|
751
|
+
<span class='name'>row</span>
|
752
|
+
|
753
|
+
|
754
|
+
<span class='type'>(<tt>Array</tt>)</span>
|
755
|
+
|
756
|
+
|
757
|
+
|
758
|
+
—
|
759
|
+
<div class='inline'>
|
760
|
+
<p>Data row.</p>
|
761
|
+
</div>
|
762
|
+
|
763
|
+
</li>
|
764
|
+
|
765
|
+
</ul>
|
766
|
+
|
767
|
+
|
768
|
+
</div><table class="source_code">
|
769
|
+
<tr>
|
770
|
+
<td>
|
771
|
+
<pre class="lines">
|
772
|
+
|
773
|
+
|
774
|
+
14
|
775
|
+
15
|
776
|
+
16
|
777
|
+
17
|
778
|
+
18</pre>
|
779
|
+
</td>
|
780
|
+
<td>
|
781
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 14</span>
|
782
|
+
|
783
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_outs_dictionary'>outs_dictionary</span><span class='lparen'>(</span><span class='label'>columns:</span><span class='comma'>,</span> <span class='label'>row:</span><span class='rparen'>)</span>
|
784
|
+
<span class='id identifier rubyid_row'>row</span><span class='period'>.</span><span class='id identifier rubyid_each_with_index'>each_with_index</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_cell'>cell</span><span class='comma'>,</span> <span class='id identifier rubyid_index'>index</span><span class='op'>|</span>
|
785
|
+
<span class='id identifier rubyid_outs_check_cell'>outs_check_cell</span><span class='lparen'>(</span><span class='label'>columns:</span> <span class='id identifier rubyid_columns'>columns</span><span class='comma'>,</span> <span class='label'>cell:</span> <span class='id identifier rubyid_cell'>cell</span><span class='comma'>,</span> <span class='label'>index:</span> <span class='id identifier rubyid_index'>index</span><span class='rparen'>)</span>
|
786
|
+
<span class='kw'>end</span>
|
787
|
+
<span class='kw'>end</span></pre>
|
788
|
+
</td>
|
789
|
+
</tr>
|
790
|
+
</table>
|
791
|
+
</div>
|
792
|
+
|
793
|
+
</div>
|
794
|
+
|
795
|
+
<div id="instance_method_details" class="method_details_list">
|
796
|
+
<h2>Instance Method Details</h2>
|
797
|
+
|
798
|
+
|
799
|
+
<div class="method_details first">
|
800
|
+
<h3 class="signature first" id="defaults-instance_method">
|
801
|
+
|
802
|
+
#<strong>defaults</strong> ⇒ <tt>Object</tt>
|
803
|
+
|
804
|
+
|
805
|
+
|
806
|
+
|
807
|
+
|
808
|
+
</h3><div class="docstring">
|
809
|
+
<div class="discussion">
|
810
|
+
<p class="note private">
|
811
|
+
<strong>This method is part of a private API.</strong>
|
812
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
813
|
+
</p>
|
814
|
+
|
815
|
+
<p>Input columns with defaults specified</p>
|
816
|
+
|
817
|
+
|
818
|
+
</div>
|
819
|
+
</div>
|
820
|
+
<div class="tags">
|
821
|
+
|
822
|
+
|
823
|
+
</div><table class="source_code">
|
824
|
+
<tr>
|
825
|
+
<td>
|
826
|
+
<pre class="lines">
|
827
|
+
|
828
|
+
|
829
|
+
133
|
830
|
+
134
|
831
|
+
135</pre>
|
832
|
+
</td>
|
833
|
+
<td>
|
834
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 133</span>
|
835
|
+
|
836
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_defaults'>defaults</span>
|
837
|
+
<span class='ivar'>@dictionary</span><span class='op'>&.</span><span class='id identifier rubyid_defaults'>defaults</span>
|
838
|
+
<span class='kw'>end</span></pre>
|
839
|
+
</td>
|
840
|
+
</tr>
|
841
|
+
</table>
|
842
|
+
</div>
|
843
|
+
|
844
|
+
<div class="method_details ">
|
845
|
+
<h3 class="signature " id="defaults=-instance_method">
|
846
|
+
|
847
|
+
#<strong>defaults=</strong>(value) ⇒ <tt>Object</tt>
|
848
|
+
|
849
|
+
|
850
|
+
|
851
|
+
|
852
|
+
|
853
|
+
</h3><div class="docstring">
|
854
|
+
<div class="discussion">
|
855
|
+
<p class="note private">
|
856
|
+
<strong>This method is part of a private API.</strong>
|
857
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
858
|
+
</p>
|
859
|
+
|
860
|
+
<p>Set defaults for columns with defaults specified</p>
|
861
|
+
|
862
|
+
|
863
|
+
</div>
|
864
|
+
</div>
|
865
|
+
<div class="tags">
|
866
|
+
|
867
|
+
|
868
|
+
</div><table class="source_code">
|
869
|
+
<tr>
|
870
|
+
<td>
|
871
|
+
<pre class="lines">
|
872
|
+
|
873
|
+
|
874
|
+
138
|
875
|
+
139
|
876
|
+
140</pre>
|
877
|
+
</td>
|
878
|
+
<td>
|
879
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 138</span>
|
880
|
+
|
881
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_defaults='>defaults=</span><span class='lparen'>(</span><span class='id identifier rubyid_value'>value</span><span class='rparen'>)</span>
|
882
|
+
<span class='ivar'>@dictionary</span><span class='period'>.</span><span class='id identifier rubyid_defaults'>defaults</span> <span class='op'>=</span> <span class='id identifier rubyid_value'>value</span>
|
883
|
+
<span class='kw'>end</span></pre>
|
884
|
+
</td>
|
885
|
+
</tr>
|
886
|
+
</table>
|
887
|
+
</div>
|
888
|
+
|
889
|
+
<div class="method_details ">
|
890
|
+
<h3 class="signature " id="dictionary-instance_method">
|
891
|
+
|
892
|
+
#<strong>dictionary</strong> ⇒ <tt>Hash{Symbol=>[false, Integer]}</tt>
|
893
|
+
|
894
|
+
|
895
|
+
|
896
|
+
|
897
|
+
|
898
|
+
</h3><div class="docstring">
|
899
|
+
<div class="discussion">
|
900
|
+
<p class="note private">
|
901
|
+
<strong>This method is part of a private API.</strong>
|
902
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
903
|
+
</p>
|
904
|
+
|
905
|
+
<p>Returns Dictionary of all input and output column names.</p>
|
906
|
+
|
907
|
+
|
908
|
+
</div>
|
909
|
+
</div>
|
910
|
+
<div class="tags">
|
911
|
+
|
912
|
+
<p class="tag_title">Returns:</p>
|
913
|
+
<ul class="return">
|
914
|
+
|
915
|
+
<li>
|
916
|
+
|
917
|
+
|
918
|
+
<span class='type'>(<tt>Hash{Symbol=>[false, Integer]}</tt>)</span>
|
919
|
+
|
920
|
+
|
921
|
+
|
922
|
+
—
|
923
|
+
<div class='inline'>
|
924
|
+
<p>Dictionary of all input and output column names.</p>
|
925
|
+
</div>
|
926
|
+
|
927
|
+
</li>
|
928
|
+
|
929
|
+
</ul>
|
930
|
+
|
931
|
+
</div><table class="source_code">
|
932
|
+
<tr>
|
933
|
+
<td>
|
934
|
+
<pre class="lines">
|
935
|
+
|
936
|
+
|
937
|
+
144
|
938
|
+
145
|
939
|
+
146</pre>
|
940
|
+
</td>
|
941
|
+
<td>
|
942
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 144</span>
|
943
|
+
|
944
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_dictionary'>dictionary</span>
|
945
|
+
<span class='ivar'>@dictionary</span><span class='period'>.</span><span class='id identifier rubyid_columns'>columns</span>
|
946
|
+
<span class='kw'>end</span></pre>
|
947
|
+
</td>
|
948
|
+
</tr>
|
949
|
+
</table>
|
950
|
+
</div>
|
951
|
+
|
952
|
+
<div class="method_details ">
|
953
|
+
<h3 class="signature " id="ifs-instance_method">
|
954
|
+
|
955
|
+
#<strong>ifs</strong> ⇒ <tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>
|
956
|
+
|
957
|
+
|
958
|
+
|
959
|
+
|
960
|
+
|
961
|
+
</h3><div class="docstring">
|
962
|
+
<div class="discussion">
|
963
|
+
<p class="note private">
|
964
|
+
<strong>This method is part of a private API.</strong>
|
965
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
966
|
+
</p>
|
967
|
+
|
968
|
+
<p>if: columns hash keyed by column index.</p>
|
969
|
+
|
970
|
+
|
971
|
+
</div>
|
972
|
+
</div>
|
973
|
+
<div class="tags">
|
974
|
+
|
975
|
+
<p class="tag_title">Returns:</p>
|
976
|
+
<ul class="return">
|
977
|
+
|
978
|
+
<li>
|
979
|
+
|
980
|
+
|
981
|
+
<span class='type'>(<tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>)</span>
|
982
|
+
|
983
|
+
|
984
|
+
|
985
|
+
</li>
|
986
|
+
|
987
|
+
</ul>
|
988
|
+
|
989
|
+
</div><table class="source_code">
|
990
|
+
<tr>
|
991
|
+
<td>
|
992
|
+
<pre class="lines">
|
993
|
+
|
994
|
+
|
995
|
+
162
|
996
|
+
163
|
997
|
+
164</pre>
|
998
|
+
</td>
|
999
|
+
<td>
|
1000
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 162</span>
|
1001
|
+
|
1002
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_ifs'>ifs</span>
|
1003
|
+
<span class='ivar'>@dictionary</span><span class='period'>.</span><span class='id identifier rubyid_ifs'>ifs</span>
|
1004
|
+
<span class='kw'>end</span></pre>
|
1005
|
+
</td>
|
1006
|
+
</tr>
|
1007
|
+
</table>
|
1008
|
+
</div>
|
1009
|
+
|
1010
|
+
<div class="method_details ">
|
1011
|
+
<h3 class="signature " id="input_keys-instance_method">
|
1012
|
+
|
1013
|
+
#<strong>input_keys</strong> ⇒ <tt>Array<Symbol></tt>
|
1014
|
+
|
1015
|
+
|
1016
|
+
|
1017
|
+
|
1018
|
+
|
1019
|
+
</h3><div class="docstring">
|
1020
|
+
<div class="discussion">
|
1021
|
+
<p class="note private">
|
1022
|
+
<strong>This method is part of a private API.</strong>
|
1023
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
1024
|
+
</p>
|
1025
|
+
|
1026
|
+
<p>Returns All input column symbols.</p>
|
1027
|
+
|
1028
|
+
|
1029
|
+
</div>
|
1030
|
+
</div>
|
1031
|
+
<div class="tags">
|
1032
|
+
|
1033
|
+
<p class="tag_title">Returns:</p>
|
1034
|
+
<ul class="return">
|
1035
|
+
|
1036
|
+
<li>
|
1037
|
+
|
1038
|
+
|
1039
|
+
<span class='type'>(<tt>Array<Symbol></tt>)</span>
|
1040
|
+
|
1041
|
+
|
1042
|
+
|
1043
|
+
—
|
1044
|
+
<div class='inline'>
|
1045
|
+
<p>All input column symbols.</p>
|
1046
|
+
</div>
|
1047
|
+
|
1048
|
+
</li>
|
1049
|
+
|
1050
|
+
</ul>
|
1051
|
+
|
1052
|
+
</div><table class="source_code">
|
1053
|
+
<tr>
|
1054
|
+
<td>
|
1055
|
+
<pre class="lines">
|
1056
|
+
|
1057
|
+
|
1058
|
+
173
|
1059
|
+
174
|
1060
|
+
175</pre>
|
1061
|
+
</td>
|
1062
|
+
<td>
|
1063
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 173</span>
|
1064
|
+
|
1065
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_input_keys'>input_keys</span>
|
1066
|
+
<span class='ivar'>@dictionary</span><span class='period'>.</span><span class='id identifier rubyid_columns'>columns</span><span class='period'>.</span><span class='id identifier rubyid_select'>select</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid__k'>_k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='op'>|</span> <span class='id identifier rubyid_v'>v</span> <span class='op'>==</span> <span class='symbol'>:in</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_keys'>keys</span>
|
1067
|
+
<span class='kw'>end</span></pre>
|
1068
|
+
</td>
|
1069
|
+
</tr>
|
1070
|
+
</table>
|
1071
|
+
</div>
|
1072
|
+
|
1073
|
+
<div class="method_details ">
|
1074
|
+
<h3 class="signature " id="ins-instance_method">
|
1075
|
+
|
1076
|
+
#<strong>ins</strong> ⇒ <tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>
|
1077
|
+
|
1078
|
+
|
1079
|
+
|
1080
|
+
|
1081
|
+
|
1082
|
+
</h3><div class="docstring">
|
1083
|
+
<div class="discussion">
|
1084
|
+
<p class="note private">
|
1085
|
+
<strong>This method is part of a private API.</strong>
|
1086
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
1087
|
+
</p>
|
1088
|
+
|
1089
|
+
<p>Input columns hash keyed by column index.</p>
|
1090
|
+
|
1091
|
+
|
1092
|
+
</div>
|
1093
|
+
</div>
|
1094
|
+
<div class="tags">
|
1095
|
+
|
1096
|
+
<p class="tag_title">Returns:</p>
|
1097
|
+
<ul class="return">
|
1098
|
+
|
1099
|
+
<li>
|
1100
|
+
|
1101
|
+
|
1102
|
+
<span class='type'>(<tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>)</span>
|
1103
|
+
|
1104
|
+
|
1105
|
+
|
1106
|
+
</li>
|
1107
|
+
|
1108
|
+
</ul>
|
1109
|
+
|
1110
|
+
</div><table class="source_code">
|
1111
|
+
<tr>
|
1112
|
+
<td>
|
1113
|
+
<pre class="lines">
|
1114
|
+
|
1115
|
+
|
1116
|
+
150
|
1117
|
+
151
|
1118
|
+
152</pre>
|
1119
|
+
</td>
|
1120
|
+
<td>
|
1121
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 150</span>
|
1122
|
+
|
1123
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_ins'>ins</span>
|
1124
|
+
<span class='ivar'>@dictionary</span><span class='period'>.</span><span class='id identifier rubyid_ins'>ins</span>
|
1125
|
+
<span class='kw'>end</span></pre>
|
1126
|
+
</td>
|
1127
|
+
</tr>
|
1128
|
+
</table>
|
1129
|
+
</div>
|
1130
|
+
|
1131
|
+
<div class="method_details ">
|
1132
|
+
<h3 class="signature " id="outs-instance_method">
|
1133
|
+
|
1134
|
+
#<strong>outs</strong> ⇒ <tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>
|
1135
|
+
|
1136
|
+
|
1137
|
+
|
1138
|
+
|
1139
|
+
|
1140
|
+
</h3><div class="docstring">
|
1141
|
+
<div class="discussion">
|
1142
|
+
<p class="note private">
|
1143
|
+
<strong>This method is part of a private API.</strong>
|
1144
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
1145
|
+
</p>
|
1146
|
+
|
1147
|
+
<p>Output columns hash keyed by column index.</p>
|
1148
|
+
|
1149
|
+
|
1150
|
+
</div>
|
1151
|
+
</div>
|
1152
|
+
<div class="tags">
|
1153
|
+
|
1154
|
+
<p class="tag_title">Returns:</p>
|
1155
|
+
<ul class="return">
|
1156
|
+
|
1157
|
+
<li>
|
1158
|
+
|
1159
|
+
|
1160
|
+
<span class='type'>(<tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>)</span>
|
1161
|
+
|
1162
|
+
|
1163
|
+
|
1164
|
+
</li>
|
1165
|
+
|
1166
|
+
</ul>
|
1167
|
+
|
1168
|
+
</div><table class="source_code">
|
1169
|
+
<tr>
|
1170
|
+
<td>
|
1171
|
+
<pre class="lines">
|
1172
|
+
|
1173
|
+
|
1174
|
+
156
|
1175
|
+
157
|
1176
|
+
158</pre>
|
1177
|
+
</td>
|
1178
|
+
<td>
|
1179
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 156</span>
|
1180
|
+
|
1181
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_outs'>outs</span>
|
1182
|
+
<span class='ivar'>@dictionary</span><span class='op'>&.</span><span class='id identifier rubyid_outs'>outs</span>
|
1183
|
+
<span class='kw'>end</span></pre>
|
1184
|
+
</td>
|
1185
|
+
</tr>
|
1186
|
+
</table>
|
1187
|
+
</div>
|
1188
|
+
|
1189
|
+
<div class="method_details ">
|
1190
|
+
<h3 class="signature " id="paths-instance_method">
|
1191
|
+
|
1192
|
+
#<strong>paths</strong> ⇒ <tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>
|
1193
|
+
|
1194
|
+
|
1195
|
+
|
1196
|
+
|
1197
|
+
|
1198
|
+
</h3><div class="docstring">
|
1199
|
+
<div class="discussion">
|
1200
|
+
<p class="note private">
|
1201
|
+
<strong>This method is part of a private API.</strong>
|
1202
|
+
You should avoid using this method if possible, as it may be removed or be changed in the future.
|
1203
|
+
</p>
|
1204
|
+
|
1205
|
+
<p>path: columns hash keyed by column index.</p>
|
1206
|
+
|
1207
|
+
|
1208
|
+
</div>
|
1209
|
+
</div>
|
1210
|
+
<div class="tags">
|
1211
|
+
|
1212
|
+
<p class="tag_title">Returns:</p>
|
1213
|
+
<ul class="return">
|
1214
|
+
|
1215
|
+
<li>
|
1216
|
+
|
1217
|
+
|
1218
|
+
<span class='type'>(<tt>Hash{<span class='object_link'><a href="Index.html" title="CSVDecision::Index (class)">Index</a></span>=>Entry}</tt>)</span>
|
1219
|
+
|
1220
|
+
|
1221
|
+
|
1222
|
+
</li>
|
1223
|
+
|
1224
|
+
</ul>
|
1225
|
+
|
1226
|
+
</div><table class="source_code">
|
1227
|
+
<tr>
|
1228
|
+
<td>
|
1229
|
+
<pre class="lines">
|
1230
|
+
|
1231
|
+
|
1232
|
+
168
|
1233
|
+
169
|
1234
|
+
170</pre>
|
1235
|
+
</td>
|
1236
|
+
<td>
|
1237
|
+
<pre class="code"><span class="info file"># File 'lib/csv_decision/columns.rb', line 168</span>
|
1238
|
+
|
1239
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_paths'>paths</span>
|
1240
|
+
<span class='ivar'>@dictionary</span><span class='period'>.</span><span class='id identifier rubyid_paths'>paths</span>
|
1241
|
+
<span class='kw'>end</span></pre>
|
1242
|
+
</td>
|
1243
|
+
</tr>
|
1244
|
+
</table>
|
1245
|
+
</div>
|
1246
|
+
|
1247
|
+
</div>
|
1248
|
+
|
1249
|
+
</div>
|
1250
|
+
|
1251
|
+
<div id="footer">
|
1252
|
+
Generated on Sun Feb 11 10:26:08 2018 by
|
1253
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
1254
|
+
0.9.12 (ruby-2.4.0).
|
1255
|
+
</div>
|
1256
|
+
|
1257
|
+
</div>
|
1258
|
+
</body>
|
1259
|
+
</html>
|