mucgly 0.0.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.
@@ -0,0 +1,545 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>
7
+ Class: Mucgly::MucglyFile
8
+
9
+ &mdash; Documentation by YARD 0.8.6.1
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
+ hasFrames = window.top.frames.main ? true : false;
19
+ relpath = '../';
20
+ framesUrl = "../frames.html#!" + escape(window.location.href);
21
+ </script>
22
+
23
+
24
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
25
+
26
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
27
+
28
+
29
+ </head>
30
+ <body>
31
+ <div id="header">
32
+ <div id="menu">
33
+
34
+ <a href="../_index.html">Index (M)</a> &raquo;
35
+ <span class='title'><span class='object_link'><a href="../Mucgly.html" title="Mucgly (module)">Mucgly</a></span></span>
36
+ &raquo;
37
+ <span class="title">MucglyFile</span>
38
+
39
+
40
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
41
+ </div>
42
+
43
+ <div id="search">
44
+
45
+ <a class="full_list_link" id="class_list_link"
46
+ href="../class_list.html">
47
+ Class List
48
+ </a>
49
+
50
+ <a class="full_list_link" id="method_list_link"
51
+ href="../method_list.html">
52
+ Method List
53
+ </a>
54
+
55
+ <a class="full_list_link" id="file_list_link"
56
+ href="../file_list.html">
57
+ File List
58
+ </a>
59
+
60
+ </div>
61
+ <div class="clear"></div>
62
+ </div>
63
+
64
+ <iframe id="search_frame"></iframe>
65
+
66
+ <div id="content"><h1>Class: Mucgly::MucglyFile
67
+
68
+
69
+
70
+ </h1>
71
+
72
+ <dl class="box">
73
+
74
+ <dt class="r1">Inherits:</dt>
75
+ <dd class="r1">
76
+ <span class="inheritName">Object</span>
77
+
78
+ <ul class="fullTree">
79
+ <li>Object</li>
80
+
81
+ <li class="next">Mucgly::MucglyFile</li>
82
+
83
+ </ul>
84
+ <a href="#" class="inheritanceTree">show all</a>
85
+
86
+ </dd>
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+ <dt class="r2 last">Defined in:</dt>
97
+ <dd class="r2 last">lib/mucgly.rb</dd>
98
+
99
+ </dl>
100
+ <div class="clear"></div>
101
+
102
+ <h2>Overview</h2><div class="docstring">
103
+ <div class="discussion">
104
+
105
+ <p>MucglyFile includes processing and status for a file that is treated as
106
+ Mucgly file. Separators are copied from the upper level context i.e. lower
107
+ level settings does NOT affect higher level settings. Status of parsing is
108
+ kept within the class.</p>
109
+
110
+
111
+ </div>
112
+ </div>
113
+ <div class="tags">
114
+
115
+
116
+ </div><h2>Defined Under Namespace</h2>
117
+ <p class="children">
118
+
119
+
120
+
121
+
122
+ <strong class="classes">Classes:</strong> <span class='object_link'><a href="MucglyFile/ParseState.html" title="Mucgly::MucglyFile::ParseState (class)">ParseState</a></span>, <span class='object_link'><a href="MucglyFile/Token.html" title="Mucgly::MucglyFile::Token (class)">Token</a></span>
123
+
124
+
125
+ </p>
126
+
127
+
128
+
129
+
130
+ <h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2>
131
+ <ul class="summary">
132
+
133
+ <li class="public ">
134
+ <span class="summary_signature">
135
+
136
+ <a href="#env-instance_method" title="#env (instance method)">- (Object) <strong>env</strong> </a>
137
+
138
+
139
+
140
+ </span>
141
+
142
+
143
+
144
+
145
+
146
+
147
+
148
+
149
+
150
+
151
+
152
+
153
+ <span class="summary_desc"><div class='inline'>
154
+ <p>Returns the value of attribute env.</p>
155
+ </div></span>
156
+
157
+ </li>
158
+
159
+
160
+ <li class="public ">
161
+ <span class="summary_signature">
162
+
163
+ <a href="#parseState-instance_method" title="#parseState (instance method)">- (Object) <strong>parseState</strong> </a>
164
+
165
+
166
+
167
+ </span>
168
+
169
+
170
+
171
+
172
+
173
+
174
+
175
+
176
+
177
+
178
+
179
+
180
+ <span class="summary_desc"><div class='inline'>
181
+ <p>Returns the value of attribute parseState.</p>
182
+ </div></span>
183
+
184
+ </li>
185
+
186
+
187
+ </ul>
188
+
189
+
190
+
191
+
192
+
193
+ <h2>
194
+ Instance Method Summary
195
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
196
+ </h2>
197
+
198
+ <ul class="summary">
199
+
200
+ <li class="public ">
201
+ <span class="summary_signature">
202
+
203
+ <a href="#initialize-instance_method" title="#initialize (instance method)">- (MucglyFile) <strong>initialize</strong>(env) </a>
204
+
205
+
206
+
207
+ </span>
208
+
209
+
210
+ <span class="note title constructor">constructor</span>
211
+
212
+
213
+
214
+
215
+
216
+
217
+
218
+
219
+ <span class="summary_desc"><div class='inline'>
220
+ <p>A new instance of MucglyFile.</p>
221
+ </div></span>
222
+
223
+ </li>
224
+
225
+
226
+ <li class="public ">
227
+ <span class="summary_signature">
228
+
229
+ <a href="#parse-instance_method" title="#parse (instance method)">- (Object) <strong>parse</strong> </a>
230
+
231
+
232
+
233
+ </span>
234
+
235
+
236
+
237
+
238
+
239
+
240
+
241
+
242
+
243
+ <span class="summary_desc"><div class='inline'>
244
+ <p>Process a Mucgly file.</p>
245
+ </div></span>
246
+
247
+ </li>
248
+
249
+
250
+ </ul>
251
+
252
+
253
+ <div id="constructor_details" class="method_details_list">
254
+ <h2>Constructor Details</h2>
255
+
256
+ <div class="method_details first">
257
+ <h3 class="signature first" id="initialize-instance_method">
258
+
259
+ - (<tt><span class='object_link'><a href="" title="Mucgly::MucglyFile (class)">MucglyFile</a></span></tt>) <strong>initialize</strong>(env)
260
+
261
+
262
+
263
+
264
+
265
+ </h3><div class="docstring">
266
+ <div class="discussion">
267
+
268
+ <p>A new instance of MucglyFile</p>
269
+
270
+
271
+ </div>
272
+ </div>
273
+ <div class="tags">
274
+
275
+
276
+ </div><table class="source_code">
277
+ <tr>
278
+ <td>
279
+ <pre class="lines">
280
+
281
+
282
+ 143
283
+ 144
284
+ 145
285
+ 146
286
+ 147
287
+ 148
288
+ 149
289
+ 150
290
+ 151
291
+ 152
292
+ 153
293
+ 154
294
+ 155</pre>
295
+ </td>
296
+ <td>
297
+ <pre class="code"><span class="info file"># File 'lib/mucgly.rb', line 143</span>
298
+
299
+ <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span> <span class='id identifier rubyid_env'>env</span> <span class='rparen'>)</span>
300
+
301
+ <span class='ivar'>@env</span> <span class='op'>=</span> <span class='id identifier rubyid_env'>env</span>
302
+
303
+ <span class='comment'># Process fileStartHook callback:
304
+ </span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid__eval'>_eval</span><span class='lparen'>(</span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid_fileStartHook'>fileStartHook</span> <span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid_fileStartHook'>fileStartHook</span>
305
+
306
+ <span class='comment'># Copy upper level separators.
307
+ </span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid__separators'>_separators</span> <span class='op'>=</span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid__separators'>_separators</span><span class='period'>.</span><span class='id identifier rubyid_copy'>copy</span>
308
+
309
+ <span class='comment'># Process the Mucgly file.
310
+ </span> <span class='id identifier rubyid_parse'>parse</span>
311
+ <span class='kw'>end</span></pre>
312
+ </td>
313
+ </tr>
314
+ </table>
315
+ </div>
316
+
317
+ </div>
318
+
319
+ <div id="instance_attr_details" class="attr_details">
320
+ <h2>Instance Attribute Details</h2>
321
+
322
+
323
+ <span id="env=-instance_method"></span>
324
+ <div class="method_details first">
325
+ <h3 class="signature first" id="env-instance_method">
326
+
327
+ - (<tt>Object</tt>) <strong>env</strong>
328
+
329
+
330
+
331
+
332
+
333
+ </h3><div class="docstring">
334
+ <div class="discussion">
335
+
336
+ <p>Returns the value of attribute env</p>
337
+
338
+
339
+ </div>
340
+ </div>
341
+ <div class="tags">
342
+
343
+
344
+ </div><table class="source_code">
345
+ <tr>
346
+ <td>
347
+ <pre class="lines">
348
+
349
+
350
+ 141
351
+ 142
352
+ 143</pre>
353
+ </td>
354
+ <td>
355
+ <pre class="code"><span class="info file"># File 'lib/mucgly.rb', line 141</span>
356
+
357
+ <span class='kw'>def</span> <span class='id identifier rubyid_env'>env</span>
358
+ <span class='ivar'>@env</span>
359
+ <span class='kw'>end</span></pre>
360
+ </td>
361
+ </tr>
362
+ </table>
363
+ </div>
364
+
365
+
366
+ <span id="parseState=-instance_method"></span>
367
+ <div class="method_details ">
368
+ <h3 class="signature " id="parseState-instance_method">
369
+
370
+ - (<tt>Object</tt>) <strong>parseState</strong>
371
+
372
+
373
+
374
+
375
+
376
+ </h3><div class="docstring">
377
+ <div class="discussion">
378
+
379
+ <p>Returns the value of attribute parseState</p>
380
+
381
+
382
+ </div>
383
+ </div>
384
+ <div class="tags">
385
+
386
+
387
+ </div><table class="source_code">
388
+ <tr>
389
+ <td>
390
+ <pre class="lines">
391
+
392
+
393
+ 141
394
+ 142
395
+ 143</pre>
396
+ </td>
397
+ <td>
398
+ <pre class="code"><span class="info file"># File 'lib/mucgly.rb', line 141</span>
399
+
400
+ <span class='kw'>def</span> <span class='id identifier rubyid_parseState'>parseState</span>
401
+ <span class='ivar'>@parseState</span>
402
+ <span class='kw'>end</span></pre>
403
+ </td>
404
+ </tr>
405
+ </table>
406
+ </div>
407
+
408
+ </div>
409
+
410
+
411
+ <div id="instance_method_details" class="method_details_list">
412
+ <h2>Instance Method Details</h2>
413
+
414
+
415
+ <div class="method_details first">
416
+ <h3 class="signature first" id="parse-instance_method">
417
+
418
+ - (<tt>Object</tt>) <strong>parse</strong>
419
+
420
+
421
+
422
+
423
+
424
+ </h3><div class="docstring">
425
+ <div class="discussion">
426
+
427
+ <p>Process a Mucgly file.</p>
428
+
429
+
430
+ </div>
431
+ </div>
432
+ <div class="tags">
433
+
434
+
435
+ </div><table class="source_code">
436
+ <tr>
437
+ <td>
438
+ <pre class="lines">
439
+
440
+
441
+ 537
442
+ 538
443
+ 539
444
+ 540
445
+ 541
446
+ 542
447
+ 543
448
+ 544
449
+ 545
450
+ 546
451
+ 547
452
+ 548
453
+ 549
454
+ 550
455
+ 551
456
+ 552
457
+ 553
458
+ 554
459
+ 555
460
+ 556
461
+ 557
462
+ 558
463
+ 559
464
+ 560
465
+ 561
466
+ 562
467
+ 563
468
+ 564
469
+ 565
470
+ 566
471
+ 567
472
+ 568
473
+ 569
474
+ 570
475
+ 571
476
+ 572
477
+ 573
478
+ 574
479
+ 575
480
+ 576
481
+ 577
482
+ 578</pre>
483
+ </td>
484
+ <td>
485
+ <pre class="code"><span class="info file"># File 'lib/mucgly.rb', line 537</span>
486
+
487
+ <span class='kw'>def</span> <span class='id identifier rubyid_parse'>parse</span>
488
+
489
+ <span class='id identifier rubyid_parseState'>parseState</span> <span class='op'>=</span> <span class='const'>ParseState</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span> <span class='kw'>self</span> <span class='rparen'>)</span>
490
+
491
+ <span class='kw'>while</span> <span class='kw'>true</span>
492
+
493
+ <span class='id identifier rubyid_t'>t</span> <span class='op'>=</span> <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_getToken'>getToken</span>
494
+
495
+ <span class='kw'>if</span> <span class='id identifier rubyid_t'>t</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span> <span class='op'>==</span> <span class='symbol'>:eof</span>
496
+
497
+ <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_flush'>flush</span>
498
+
499
+ <span class='comment'># Process fileEndHook callback:
500
+ </span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid__eval'>_eval</span><span class='lparen'>(</span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid_fileEndHook'>fileEndHook</span> <span class='rparen'>)</span> <span class='kw'>if</span> <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid_fileEndHook'>fileEndHook</span>
501
+
502
+ <span class='comment'># End of stream.
503
+ </span> <span class='comment'># @fp.close
504
+ </span>
505
+ <span class='ivar'>@env</span><span class='period'>.</span><span class='id identifier rubyid__inIO'>_inIO</span><span class='period'>.</span><span class='id identifier rubyid_close'>close</span>
506
+
507
+ <span class='kw'>return</span>
508
+
509
+ <span class='kw'>elsif</span> <span class='id identifier rubyid_t'>t</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span> <span class='op'>==</span> <span class='symbol'>:hookBeg</span>
510
+
511
+ <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_push'>push</span>
512
+ <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span><span class='lparen'>(</span> <span class='id identifier rubyid_t'>t</span> <span class='rparen'>)</span>
513
+
514
+ <span class='kw'>elsif</span> <span class='id identifier rubyid_t'>t</span><span class='period'>.</span><span class='id identifier rubyid_type'>type</span> <span class='op'>==</span> <span class='symbol'>:hookEnd</span>
515
+
516
+ <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span><span class='lparen'>(</span> <span class='id identifier rubyid_t'>t</span> <span class='rparen'>)</span>
517
+ <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_pop'>pop</span>
518
+
519
+ <span class='kw'>else</span>
520
+
521
+ <span class='id identifier rubyid_parseState'>parseState</span><span class='period'>.</span><span class='id identifier rubyid_shift'>shift</span><span class='lparen'>(</span> <span class='id identifier rubyid_t'>t</span> <span class='rparen'>)</span>
522
+
523
+ <span class='kw'>end</span>
524
+
525
+
526
+ <span class='kw'>end</span>
527
+
528
+ <span class='kw'>end</span></pre>
529
+ </td>
530
+ </tr>
531
+ </table>
532
+ </div>
533
+
534
+ </div>
535
+
536
+ </div>
537
+
538
+ <div id="footer">
539
+ Generated on Wed Jan 15 19:29:45 2014 by
540
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
541
+ 0.8.6.1 (ruby-1.9.3).
542
+ </div>
543
+
544
+ </body>
545
+ </html>