sprout 1.1.15.pre → 1.1.16.pre

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of sprout might be problematic. Click here for more details.

Files changed (101) hide show
  1. data/VERSION +1 -1
  2. data/lib/sprout/executable/base.rb +7 -7
  3. metadata +101 -252
  4. data/Gemfile.lock +0 -50
  5. data/doc/Dir.html +0 -288
  6. data/doc/Rake/Task.html +0 -184
  7. data/doc/Sprout.html +0 -740
  8. data/doc/Sprout/ArchiveUnpacker.html +0 -1246
  9. data/doc/Sprout/CommandLine.html +0 -520
  10. data/doc/Sprout/Concern.html +0 -351
  11. data/doc/Sprout/Errors.html +0 -101
  12. data/doc/Sprout/Errors/ArchiveUnpackerError.html +0 -125
  13. data/doc/Sprout/Errors/DestinationExistsError.html +0 -133
  14. data/doc/Sprout/Errors/DuplicateMemberError.html +0 -132
  15. data/doc/Sprout/Errors/ExecutableError.html +0 -125
  16. data/doc/Sprout/Errors/ExecutableRegistrationError.html +0 -132
  17. data/doc/Sprout/Errors/ExecutionError.html +0 -121
  18. data/doc/Sprout/Errors/GeneratorError.html +0 -125
  19. data/doc/Sprout/Errors/InvalidArgumentError.html +0 -132
  20. data/doc/Sprout/Errors/LoadError.html +0 -121
  21. data/doc/Sprout/Errors/MissingArgumentError.html +0 -132
  22. data/doc/Sprout/Errors/MissingExecutableError.html +0 -132
  23. data/doc/Sprout/Errors/MissingGeneratorError.html +0 -132
  24. data/doc/Sprout/Errors/MissingTemplateError.html +0 -132
  25. data/doc/Sprout/Errors/ProcessRunnerError.html +0 -121
  26. data/doc/Sprout/Errors/RemoteFileLoaderError.html +0 -110
  27. data/doc/Sprout/Errors/SproutError.html +0 -114
  28. data/doc/Sprout/Errors/UnknownArchiveType.html +0 -122
  29. data/doc/Sprout/Errors/UsageError.html +0 -121
  30. data/doc/Sprout/Errors/ValidationError.html +0 -121
  31. data/doc/Sprout/Errors/VersionRequirementNotMetError.html +0 -121
  32. data/doc/Sprout/Executable.html +0 -169
  33. data/doc/Sprout/Executable/Base.html +0 -2813
  34. data/doc/Sprout/Executable/Boolean.html +0 -534
  35. data/doc/Sprout/Executable/CollectionParam.html +0 -483
  36. data/doc/Sprout/Executable/FileParam.html +0 -484
  37. data/doc/Sprout/Executable/Files.html +0 -292
  38. data/doc/Sprout/Executable/Number.html +0 -141
  39. data/doc/Sprout/Executable/Param.html +0 -2874
  40. data/doc/Sprout/Executable/ParameterFactory.html +0 -232
  41. data/doc/Sprout/Executable/Path.html +0 -223
  42. data/doc/Sprout/Executable/Paths.html +0 -253
  43. data/doc/Sprout/Executable/Session.html +0 -1513
  44. data/doc/Sprout/Executable/StringParam.html +0 -213
  45. data/doc/Sprout/Executable/Strings.html +0 -167
  46. data/doc/Sprout/Executable/Url.html +0 -160
  47. data/doc/Sprout/Executable/Urls.html +0 -170
  48. data/doc/Sprout/FileTarget.html +0 -1109
  49. data/doc/Sprout/Generator.html +0 -750
  50. data/doc/Sprout/Generator/Base.html +0 -1902
  51. data/doc/Sprout/Generator/Command.html +0 -690
  52. data/doc/Sprout/Generator/DirectoryManifest.html +0 -476
  53. data/doc/Sprout/Generator/FileManifest.html +0 -643
  54. data/doc/Sprout/Generator/Manifest.html +0 -377
  55. data/doc/Sprout/Generator/TemplateManifest.html +0 -194
  56. data/doc/Sprout/GeneratorGenerator.html +0 -1115
  57. data/doc/Sprout/Library.html +0 -1146
  58. data/doc/Sprout/LibraryGenerator.html +0 -331
  59. data/doc/Sprout/OutputBuffer.html +0 -445
  60. data/doc/Sprout/Platform.html +0 -714
  61. data/doc/Sprout/ProcessRunner.html +0 -1707
  62. data/doc/Sprout/ProgressBar.html +0 -366
  63. data/doc/Sprout/ProgressBarImpl.html +0 -2109
  64. data/doc/Sprout/ProgressBarManager.html +0 -424
  65. data/doc/Sprout/ProgressBarOutputStream.html +0 -406
  66. data/doc/Sprout/RDocParser.html +0 -211
  67. data/doc/Sprout/RemoteFileLoader.html +0 -172
  68. data/doc/Sprout/RemoteFileTarget.html +0 -679
  69. data/doc/Sprout/ReversedProgressBar.html +0 -184
  70. data/doc/Sprout/RubyFeature.html +0 -155
  71. data/doc/Sprout/RubyFeature/ClassMethods.html +0 -1065
  72. data/doc/Sprout/RubyGenerator.html +0 -786
  73. data/doc/Sprout/Specification.html +0 -767
  74. data/doc/Sprout/System.html +0 -191
  75. data/doc/Sprout/System/BaseSystem.html +0 -1660
  76. data/doc/Sprout/System/JavaSystem.html +0 -122
  77. data/doc/Sprout/System/OSXSystem.html +0 -335
  78. data/doc/Sprout/System/ThreadMock.html +0 -183
  79. data/doc/Sprout/System/UnixSystem.html +0 -584
  80. data/doc/Sprout/System/VistaSystem.html +0 -251
  81. data/doc/Sprout/System/WinNixSystem.html +0 -325
  82. data/doc/Sprout/System/WinSystem.html +0 -571
  83. data/doc/Sprout/TestHelper.html +0 -2165
  84. data/doc/Sprout/ToolGenerator.html +0 -953
  85. data/doc/Sprout/VERSION.html +0 -118
  86. data/doc/String.html +0 -290
  87. data/doc/_index.html +0 -820
  88. data/doc/class_list.html +0 -36
  89. data/doc/css/common.css +0 -1
  90. data/doc/css/full_list.css +0 -53
  91. data/doc/css/style.css +0 -310
  92. data/doc/file.README.html +0 -96
  93. data/doc/file_list.html +0 -41
  94. data/doc/frames.html +0 -13
  95. data/doc/index.html +0 -96
  96. data/doc/js/app.js +0 -202
  97. data/doc/js/full_list.js +0 -149
  98. data/doc/js/jquery.js +0 -154
  99. data/doc/method_list.html +0 -3603
  100. data/doc/top-level-namespace.html +0 -192
  101. data/test/fixtures/library/archive/Archive.swc +0 -0
@@ -1,1707 +0,0 @@
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 name="Content-Type" content="text/html; charset=utf-8" />
6
- <title>Class: Sprout::ProcessRunner</title>
7
- <link rel="stylesheet" href="../css/style.css" type="text/css" media="screen" charset="utf-8" />
8
- <link rel="stylesheet" href="../css/common.css" type="text/css" media="screen" charset="utf-8" />
9
-
10
- <script type="text/javascript" charset="utf-8">
11
- relpath = '..';
12
- if (relpath != '') relpath += '/';
13
- </script>
14
- <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
15
- <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
16
-
17
- </head>
18
- <body>
19
- <script type="text/javascript" charset="utf-8">
20
- if (window.top.frames.main) document.body.className = 'frames';
21
- </script>
22
-
23
- <div id="header">
24
- <div id="menu">
25
-
26
- <a href="../_index.html">Index (P)</a> &raquo;
27
- <span class='title'><span class='object_link'><a href="../Sprout.html" title="Sprout (module)">Sprout</a></span></span>
28
- &raquo;
29
- <span class="title">ProcessRunner</span>
30
-
31
-
32
- <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
33
- </div>
34
-
35
- <div id="search">
36
- <a id="class_list_link" href="#">Class List</a>
37
- <a id="method_list_link" href="#">Method List</a>
38
- <a id ="file_list_link" href="#">File List</a>
39
- </div>
40
-
41
- <div class="clear"></div>
42
- </div>
43
-
44
- <iframe id="search_frame"></iframe>
45
-
46
- <div id="content"><h1>Class: Sprout::ProcessRunner
47
-
48
-
49
-
50
- </h1>
51
-
52
- <dl class="box">
53
-
54
- <dt class="r1">Inherits:</dt>
55
- <dd class="r1">
56
- <span class="inheritName">Object</span>
57
-
58
- <ul class="fullTree">
59
- <li>Object</li>
60
-
61
- <li class="next">Sprout::ProcessRunner</li>
62
-
63
- </ul>
64
- <a href="#" class="inheritanceTree">show all</a>
65
-
66
- </dd>
67
-
68
-
69
-
70
-
71
-
72
-
73
-
74
-
75
-
76
- <dt class="r2 last">Defined in:</dt>
77
- <dd class="r2 last">lib/sprout/process_runner.rb</dd>
78
-
79
- </dl>
80
- <div class="clear"></div>
81
-
82
- <h2>Overview</h2><div class="docstring">
83
- <div class="discussion">
84
-
85
- <p>The ProcessRunner is a cross-platform wrapper for executing external
86
- executable processes.</p>
87
-
88
- <p>This class is typically accesses via the concrete Sprout::System classes in
89
- order to avoid ugly branching logic in the application layer.</p>
90
-
91
- <p>An example of this kind of usage might be:</p>
92
-
93
- <pre class="code"><span class='const'>Sprout</span><span class='period'>.</span><span class='id current_system'>current_system</span><span class='period'>.</span><span class='id execute'>execute</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>./some.exe</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>--foo=bar --baz=buz</span><span class='tstring_end'>'</span></span></pre>
94
-
95
- <p>To use this class directly, you need to know if you're on a unix-like
96
- system or a dos platform as these two deal with processes very differently.</p>
97
-
98
- <p>Assuming you know you're on a unix-like system, you could execute the
99
- previous example with:</p>
100
-
101
- <pre class="code"><span class='id runner'>runner</span> <span class='op'>=</span> <span class='const'>Sprout</span><span class='op'>::</span><span class='const'>ProcessRunner</span><span class='period'>.</span><span class='id new'>new</span>
102
- <span class='id runner'>runner</span><span class='period'>.</span><span class='id execute_open4'>execute_open4</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>./some.exe --foo-bar --baz=buz</span><span class='tstring_end'>'</span></span>
103
- <span class='id puts'>puts</span> <span class='id runner'>runner</span><span class='period'>.</span><span class='id read'>read</span></pre>
104
-
105
-
106
- </div>
107
- </div>
108
- <div class="tags">
109
-
110
- </div>
111
-
112
- <h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2>
113
- <ul class="summary">
114
-
115
- <li class="public ">
116
- <span class="summary_signature">
117
-
118
- <a href="#e-instance_method" title="#e (instance method)">- (IO) <strong>e</strong> </a>
119
-
120
-
121
-
122
- </span>
123
-
124
-
125
- <span class="note title readonly">readonly</span>
126
-
127
-
128
-
129
-
130
-
131
-
132
-
133
-
134
- <span class="summary_desc"><div class='inline'>
135
- <p>Error output.</p>
136
- </div></span>
137
-
138
- </li>
139
-
140
-
141
- <li class="public ">
142
- <span class="summary_signature">
143
-
144
- <a href="#pid-instance_method" title="#pid (instance method)">- (Object) <strong>pid</strong> </a>
145
-
146
-
147
-
148
- </span>
149
-
150
-
151
- <span class="note title readonly">readonly</span>
152
-
153
-
154
-
155
-
156
-
157
-
158
-
159
-
160
- <span class="summary_desc"><div class='inline'>
161
- <p>Returns the value of attribute pid.</p>
162
- </div></span>
163
-
164
- </li>
165
-
166
-
167
- <li class="public ">
168
- <span class="summary_signature">
169
-
170
- <a href="#r-instance_method" title="#r (instance method)">- (IO) <strong>r</strong> </a>
171
-
172
-
173
-
174
- </span>
175
-
176
-
177
- <span class="note title readonly">readonly</span>
178
-
179
-
180
-
181
-
182
-
183
-
184
-
185
-
186
- <span class="summary_desc"><div class='inline'>
187
- <p>Read only.</p>
188
- </div></span>
189
-
190
- </li>
191
-
192
-
193
- <li class="public ">
194
- <span class="summary_signature">
195
-
196
- <a href="#ruby_version-instance_method" title="#ruby_version (instance method)">- (Object) <strong>ruby_version</strong> </a>
197
-
198
-
199
-
200
- </span>
201
-
202
-
203
- <span class="note title readonly">readonly</span>
204
-
205
-
206
-
207
-
208
-
209
-
210
-
211
-
212
- <span class="summary_desc"><div class='inline'>
213
- <p>Returns the value of attribute ruby_version.</p>
214
- </div></span>
215
-
216
- </li>
217
-
218
-
219
- <li class="public ">
220
- <span class="summary_signature">
221
-
222
- <a href="#w-instance_method" title="#w (instance method)">- (IO) <strong>w</strong> </a>
223
-
224
-
225
-
226
- </span>
227
-
228
-
229
- <span class="note title readonly">readonly</span>
230
-
231
-
232
-
233
-
234
-
235
-
236
-
237
-
238
- <span class="summary_desc"><div class='inline'>
239
- <p>Write only.</p>
240
- </div></span>
241
-
242
- </li>
243
-
244
-
245
- </ul>
246
-
247
-
248
-
249
- <h2>
250
- Instance Method Summary
251
- <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
252
- </h2>
253
-
254
- <ul class="summary">
255
-
256
- <li class="public ">
257
- <span class="summary_signature">
258
-
259
- <a href="#alive%3F-instance_method" title="#alive? (instance method)">- (Boolean) <strong>alive?</strong> </a>
260
-
261
-
262
-
263
- </span>
264
-
265
-
266
-
267
-
268
-
269
-
270
-
271
-
272
- <span class="summary_desc"><div class='inline'>
273
- <p>Whether the process is still running.</p>
274
- </div></span>
275
-
276
- </li>
277
-
278
-
279
- <li class="public ">
280
- <span class="summary_signature">
281
-
282
- <a href="#close-instance_method" title="#close (instance method)">- (Object) <strong>close</strong> </a>
283
-
284
-
285
-
286
- </span>
287
-
288
-
289
-
290
-
291
-
292
-
293
-
294
-
295
- <span class="summary_desc"><div class='inline'>
296
- <p>Close the process.</p>
297
- </div></span>
298
-
299
- </li>
300
-
301
-
302
- <li class="public ">
303
- <span class="summary_signature">
304
-
305
- <a href="#close_write-instance_method" title="#close_write (instance method)">- (Object) <strong>close_write</strong> </a>
306
-
307
-
308
-
309
- </span>
310
-
311
-
312
-
313
-
314
-
315
-
316
-
317
-
318
- <span class="summary_desc"><div class='inline'>
319
- <p>Close the write stream - usually terminates the process.</p>
320
- </div></span>
321
-
322
- </li>
323
-
324
-
325
- <li class="public ">
326
- <span class="summary_signature">
327
-
328
- <a href="#execute_open4-instance_method" title="#execute_open4 (instance method)">- (Object) <strong>execute_open4</strong>(*command) </a>
329
-
330
-
331
-
332
- </span>
333
-
334
-
335
-
336
-
337
-
338
-
339
-
340
-
341
- <span class="summary_desc"><div class='inline'>
342
- <p>Execute the provided command using the open4.popen4 library.</p>
343
- </div></span>
344
-
345
- </li>
346
-
347
-
348
- <li class="public ">
349
- <span class="summary_signature">
350
-
351
- <a href="#execute_win32-instance_method" title="#execute_win32 (instance method)">- (Object) <strong>execute_win32</strong>(*command) </a>
352
-
353
-
354
-
355
- </span>
356
-
357
-
358
-
359
-
360
-
361
-
362
-
363
-
364
- <span class="summary_desc"><div class='inline'>
365
- <p>Execute the provided command using the win32-open3 library.</p>
366
- </div></span>
367
-
368
- </li>
369
-
370
-
371
- <li class="public ">
372
- <span class="summary_signature">
373
-
374
- <a href="#flush-instance_method" title="#flush (instance method)">- (Object) <strong>flush</strong> </a>
375
-
376
-
377
-
378
- </span>
379
-
380
-
381
-
382
-
383
-
384
-
385
-
386
-
387
- <span class="summary_desc"><div class='inline'>
388
- <p>Flush the write IO to the process.</p>
389
- </div></span>
390
-
391
- </li>
392
-
393
-
394
- <li class="public ">
395
- <span class="summary_signature">
396
-
397
- <a href="#getc-instance_method" title="#getc (instance method)">- (Object) <strong>getc</strong> </a>
398
-
399
-
400
-
401
- </span>
402
-
403
-
404
-
405
-
406
-
407
-
408
-
409
-
410
- <span class="summary_desc"><div class='inline'>
411
- <p>Get user input on the read stream from the process.</p>
412
- </div></span>
413
-
414
- </li>
415
-
416
-
417
- <li class="public ">
418
- <span class="summary_signature">
419
-
420
- <a href="#initialize-instance_method" title="#initialize (instance method)">- (ProcessRunner) <strong>initialize</strong> </a>
421
-
422
-
423
-
424
- </span>
425
-
426
- <span class="note title constructor">constructor</span>
427
-
428
-
429
-
430
-
431
-
432
-
433
-
434
-
435
- <span class="summary_desc"><div class='inline'>
436
- <p>A new instance of ProcessRunner.</p>
437
- </div></span>
438
-
439
- </li>
440
-
441
-
442
- <li class="public ">
443
- <span class="summary_signature">
444
-
445
- <a href="#kill-instance_method" title="#kill (instance method)">- (Object) <strong>kill</strong> </a>
446
-
447
-
448
-
449
- </span>
450
-
451
-
452
-
453
-
454
-
455
-
456
-
457
-
458
- <span class="summary_desc"><div class='inline'>
459
- <p>Kill the process.</p>
460
- </div></span>
461
-
462
- </li>
463
-
464
-
465
- <li class="public ">
466
- <span class="summary_signature">
467
-
468
- <a href="#print-instance_method" title="#print (instance method)">- (Object) <strong>print</strong>(msg) </a>
469
-
470
-
471
-
472
- </span>
473
-
474
-
475
-
476
-
477
-
478
-
479
-
480
-
481
- <span class="summary_desc"><div class='inline'>
482
- <p>Print some characters to process without an end of line character.</p>
483
- </div></span>
484
-
485
- </li>
486
-
487
-
488
- <li class="public ">
489
- <span class="summary_signature">
490
-
491
- <a href="#puts-instance_method" title="#puts (instance method)">- (Object) <strong>puts</strong>(msg) </a>
492
-
493
-
494
-
495
- </span>
496
-
497
-
498
-
499
-
500
-
501
-
502
-
503
-
504
- <span class="summary_desc"><div class='inline'>
505
- <p>Print characters to the process followed by an end of line.</p>
506
- </div></span>
507
-
508
- </li>
509
-
510
-
511
- <li class="public ">
512
- <span class="summary_signature">
513
-
514
- <a href="#read-instance_method" title="#read (instance method)">- (Object) <strong>read</strong> </a>
515
-
516
-
517
-
518
- </span>
519
-
520
-
521
-
522
-
523
-
524
-
525
-
526
-
527
- <span class="summary_desc"><div class='inline'>
528
- <p>Wait for the process to end and return the entire standard output.</p>
529
- </div></span>
530
-
531
- </li>
532
-
533
-
534
- <li class="public ">
535
- <span class="summary_signature">
536
-
537
- <a href="#read_err-instance_method" title="#read_err (instance method)">- (Object) <strong>read_err</strong> </a>
538
-
539
-
540
-
541
- </span>
542
-
543
-
544
-
545
-
546
-
547
-
548
-
549
-
550
- <span class="summary_desc"><div class='inline'>
551
- <p>Wait for the process to end and return the entire standard error.</p>
552
- </div></span>
553
-
554
- </li>
555
-
556
-
557
- <li class="public ">
558
- <span class="summary_signature">
559
-
560
- <a href="#readlines-instance_method" title="#readlines (instance method)">- (String) <strong>readlines</strong>(count) </a>
561
-
562
-
563
-
564
- </span>
565
-
566
-
567
-
568
-
569
-
570
-
571
-
572
-
573
- <span class="summary_desc"><div class='inline'>
574
- <p>Read <tt>count</tt> lines from the process standard out.</p>
575
- </div></span>
576
-
577
- </li>
578
-
579
-
580
- <li class="public ">
581
- <span class="summary_signature">
582
-
583
- <a href="#readpartial-instance_method" title="#readpartial (instance method)">- (String) <strong>readpartial</strong>(count) </a>
584
-
585
-
586
-
587
- </span>
588
-
589
-
590
-
591
-
592
-
593
-
594
-
595
-
596
- <span class="summary_desc"><div class='inline'>
597
- <p>Read <tt>count</tt> characters from the process standard out.</p>
598
- </div></span>
599
-
600
- </li>
601
-
602
-
603
- <li class="public ">
604
- <span class="summary_signature">
605
-
606
- <a href="#readpartial_err-instance_method" title="#readpartial_err (instance method)">- (Object) <strong>readpartial_err</strong>(count) </a>
607
-
608
-
609
-
610
- </span>
611
-
612
-
613
-
614
-
615
-
616
-
617
-
618
-
619
- <span class="summary_desc"><div class='inline'></div></span>
620
-
621
- </li>
622
-
623
-
624
- <li class="public ">
625
- <span class="summary_signature">
626
-
627
- <a href="#update_status-instance_method" title="#update_status (instance method)">- (Object) <strong>update_status</strong>(sig = 0) </a>
628
-
629
-
630
-
631
- </span>
632
-
633
-
634
-
635
-
636
-
637
-
638
-
639
-
640
- <span class="summary_desc"><div class='inline'>
641
- <p>Send an update signal to the process.</p>
642
- </div></span>
643
-
644
- </li>
645
-
646
-
647
- </ul>
648
-
649
-
650
- <div id="constructor_details" class="method_details_list">
651
- <h2>Constructor Details</h2>
652
-
653
- <div class="method_details first">
654
- <p class="signature first" id="initialize-instance_method">
655
-
656
- - (<tt><span class='object_link'><a href="" title="Sprout::ProcessRunner (class)">ProcessRunner</a></span></tt>) <strong>initialize</strong>
657
-
658
-
659
-
660
- </p><div class="docstring">
661
- <div class="discussion">
662
-
663
- <p>A new instance of ProcessRunner</p>
664
-
665
-
666
- </div>
667
- </div>
668
- <div class="tags">
669
-
670
- </div><table class="source_code">
671
- <tr>
672
- <td>
673
- <pre class="lines">
674
-
675
-
676
- 43
677
- 44
678
- 45
679
- 46</pre>
680
- </td>
681
- <td>
682
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 43</span>
683
-
684
- <span class='kw'>def</span> <span class='id initialize'>initialize</span>
685
- <span class='kw'>super</span>
686
- <span class='ivar'>@ruby_version</span> <span class='op'>=</span> <span class='const'>RUBY_VERSION</span>
687
- <span class='kw'>end</span></pre>
688
- </td>
689
- </tr>
690
- </table>
691
- </div>
692
-
693
- </div>
694
-
695
- <div id="instance_attr_details" class="attr_details">
696
- <h2>Instance Attribute Details</h2>
697
-
698
-
699
- <span id=""></span>
700
- <span id="e-instance_method"></span>
701
- <div class="method_details first">
702
- <p class="signature first" id="e-instance_method">
703
-
704
- - (<tt>IO</tt>) <strong>e</strong> <span class="extras">(readonly)</span>
705
-
706
-
707
-
708
- </p><div class="docstring">
709
- <div class="discussion">
710
-
711
- <p>Error output</p>
712
-
713
-
714
- </div>
715
- </div>
716
- <div class="tags">
717
- <h3>Returns:</h3>
718
- <ul class="return">
719
-
720
- <li>
721
-
722
- <span class='type'>(<tt>IO</tt>)</span>
723
-
724
-
725
-
726
-
727
- &mdash;
728
- <div class='inline'>
729
- <p>Error output</p>
730
- </div>
731
-
732
- </li>
733
-
734
- </ul>
735
-
736
- </div><table class="source_code">
737
- <tr>
738
- <td>
739
- <pre class="lines">
740
-
741
-
742
- 41
743
- 42
744
- 43</pre>
745
- </td>
746
- <td>
747
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 41</span>
748
-
749
- <span class='kw'>def</span> <span class='id e'>e</span>
750
- <span class='ivar'>@e</span>
751
- <span class='kw'>end</span></pre>
752
- </td>
753
- </tr>
754
- </table>
755
- </div>
756
-
757
-
758
- <span id=""></span>
759
- <span id="pid-instance_method"></span>
760
- <div class="method_details ">
761
- <p class="signature " id="pid-instance_method">
762
-
763
- - (<tt>Object</tt>) <strong>pid</strong> <span class="extras">(readonly)</span>
764
-
765
-
766
-
767
- </p><div class="docstring">
768
- <div class="discussion">
769
-
770
- <p>Returns the value of attribute pid</p>
771
-
772
-
773
- </div>
774
- </div>
775
- <div class="tags">
776
-
777
- </div><table class="source_code">
778
- <tr>
779
- <td>
780
- <pre class="lines">
781
-
782
-
783
- 28
784
- 29
785
- 30</pre>
786
- </td>
787
- <td>
788
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 28</span>
789
-
790
- <span class='kw'>def</span> <span class='id pid'>pid</span>
791
- <span class='ivar'>@pid</span>
792
- <span class='kw'>end</span></pre>
793
- </td>
794
- </tr>
795
- </table>
796
- </div>
797
-
798
-
799
- <span id=""></span>
800
- <span id="r-instance_method"></span>
801
- <div class="method_details ">
802
- <p class="signature " id="r-instance_method">
803
-
804
- - (<tt>IO</tt>) <strong>r</strong> <span class="extras">(readonly)</span>
805
-
806
-
807
-
808
- </p><div class="docstring">
809
- <div class="discussion">
810
-
811
- <p>Read only</p>
812
-
813
-
814
- </div>
815
- </div>
816
- <div class="tags">
817
- <h3>Returns:</h3>
818
- <ul class="return">
819
-
820
- <li>
821
-
822
- <span class='type'>(<tt>IO</tt>)</span>
823
-
824
-
825
-
826
-
827
- &mdash;
828
- <div class='inline'>
829
- <p>Read only</p>
830
- </div>
831
-
832
- </li>
833
-
834
- </ul>
835
-
836
- </div><table class="source_code">
837
- <tr>
838
- <td>
839
- <pre class="lines">
840
-
841
-
842
- 33
843
- 34
844
- 35</pre>
845
- </td>
846
- <td>
847
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 33</span>
848
-
849
- <span class='kw'>def</span> <span class='id r'>r</span>
850
- <span class='ivar'>@r</span>
851
- <span class='kw'>end</span></pre>
852
- </td>
853
- </tr>
854
- </table>
855
- </div>
856
-
857
-
858
- <span id=""></span>
859
- <span id="ruby_version-instance_method"></span>
860
- <div class="method_details ">
861
- <p class="signature " id="ruby_version-instance_method">
862
-
863
- - (<tt>Object</tt>) <strong>ruby_version</strong> <span class="extras">(readonly)</span>
864
-
865
-
866
-
867
- </p><div class="docstring">
868
- <div class="discussion">
869
-
870
- <p>Returns the value of attribute ruby_version</p>
871
-
872
-
873
- </div>
874
- </div>
875
- <div class="tags">
876
-
877
- </div><table class="source_code">
878
- <tr>
879
- <td>
880
- <pre class="lines">
881
-
882
-
883
- 29
884
- 30
885
- 31</pre>
886
- </td>
887
- <td>
888
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 29</span>
889
-
890
- <span class='kw'>def</span> <span class='id ruby_version'>ruby_version</span>
891
- <span class='ivar'>@ruby_version</span>
892
- <span class='kw'>end</span></pre>
893
- </td>
894
- </tr>
895
- </table>
896
- </div>
897
-
898
-
899
- <span id=""></span>
900
- <span id="w-instance_method"></span>
901
- <div class="method_details ">
902
- <p class="signature " id="w-instance_method">
903
-
904
- - (<tt>IO</tt>) <strong>w</strong> <span class="extras">(readonly)</span>
905
-
906
-
907
-
908
- </p><div class="docstring">
909
- <div class="discussion">
910
-
911
- <p>Write only</p>
912
-
913
-
914
- </div>
915
- </div>
916
- <div class="tags">
917
- <h3>Returns:</h3>
918
- <ul class="return">
919
-
920
- <li>
921
-
922
- <span class='type'>(<tt>IO</tt>)</span>
923
-
924
-
925
-
926
-
927
- &mdash;
928
- <div class='inline'>
929
- <p>Write only</p>
930
- </div>
931
-
932
- </li>
933
-
934
- </ul>
935
-
936
- </div><table class="source_code">
937
- <tr>
938
- <td>
939
- <pre class="lines">
940
-
941
-
942
- 37
943
- 38
944
- 39</pre>
945
- </td>
946
- <td>
947
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 37</span>
948
-
949
- <span class='kw'>def</span> <span class='id w'>w</span>
950
- <span class='ivar'>@w</span>
951
- <span class='kw'>end</span></pre>
952
- </td>
953
- </tr>
954
- </table>
955
- </div>
956
-
957
- </div>
958
-
959
-
960
- <div id="instance_method_details" class="method_details_list">
961
- <h2>Instance Method Details</h2>
962
-
963
-
964
- <div class="method_details first">
965
- <p class="signature first" id="alive?-instance_method">
966
-
967
- - (<tt>Boolean</tt>) <strong>alive?</strong>
968
-
969
-
970
-
971
- </p><div class="docstring">
972
- <div class="discussion">
973
-
974
- <p>Whether the process is still running.</p>
975
-
976
-
977
- </div>
978
- </div>
979
- <div class="tags">
980
- <h3>Returns:</h3>
981
- <ul class="return">
982
-
983
- <li>
984
-
985
- <span class='type'>(<tt>Boolean</tt>)</span>
986
-
987
-
988
-
989
-
990
- &mdash;
991
- <div class='inline'>
992
- <p>whether the process is still running.</p>
993
- </div>
994
-
995
- </li>
996
-
997
- </ul>
998
-
999
- </div><table class="source_code">
1000
- <tr>
1001
- <td>
1002
- <pre class="lines">
1003
-
1004
-
1005
- 73
1006
- 74
1007
- 75</pre>
1008
- </td>
1009
- <td>
1010
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 73</span>
1011
-
1012
- <span class='kw'>def</span> <span class='id alive?'>alive?</span>
1013
- <span class='ivar'>@alive</span> <span class='op'>=</span> <span class='id update_status'>update_status</span>
1014
- <span class='kw'>end</span></pre>
1015
- </td>
1016
- </tr>
1017
- </table>
1018
- </div>
1019
-
1020
- <div class="method_details ">
1021
- <p class="signature " id="close-instance_method">
1022
-
1023
- - (<tt>Object</tt>) <strong>close</strong>
1024
-
1025
-
1026
-
1027
- </p><div class="docstring">
1028
- <div class="discussion">
1029
-
1030
- <p>Close the process</p>
1031
-
1032
-
1033
- </div>
1034
- </div>
1035
- <div class="tags">
1036
-
1037
- </div><table class="source_code">
1038
- <tr>
1039
- <td>
1040
- <pre class="lines">
1041
-
1042
-
1043
- 85
1044
- 86
1045
- 87</pre>
1046
- </td>
1047
- <td>
1048
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 85</span>
1049
-
1050
- <span class='kw'>def</span> <span class='id close'>close</span>
1051
- <span class='id w'>w</span><span class='period'>.</span><span class='id close_write'>close_write</span>
1052
- <span class='kw'>end</span></pre>
1053
- </td>
1054
- </tr>
1055
- </table>
1056
- </div>
1057
-
1058
- <div class="method_details ">
1059
- <p class="signature " id="close_write-instance_method">
1060
-
1061
- - (<tt>Object</tt>) <strong>close_write</strong>
1062
-
1063
-
1064
-
1065
- </p><div class="docstring">
1066
- <div class="discussion">
1067
-
1068
- <p>Close the write stream - usually terminates the process.</p>
1069
-
1070
-
1071
- </div>
1072
- </div>
1073
- <div class="tags">
1074
-
1075
- </div><table class="source_code">
1076
- <tr>
1077
- <td>
1078
- <pre class="lines">
1079
-
1080
-
1081
- 147
1082
- 148
1083
- 149</pre>
1084
- </td>
1085
- <td>
1086
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 147</span>
1087
-
1088
- <span class='kw'>def</span> <span class='id close_write'>close_write</span>
1089
- <span class='ivar'>@w</span><span class='period'>.</span><span class='id close_write'>close_write</span>
1090
- <span class='kw'>end</span></pre>
1091
- </td>
1092
- </tr>
1093
- </table>
1094
- </div>
1095
-
1096
- <div class="method_details ">
1097
- <p class="signature " id="execute_open4-instance_method">
1098
-
1099
- - (<tt>Object</tt>) <strong>execute_open4</strong>(*command)
1100
-
1101
-
1102
-
1103
- </p><div class="docstring">
1104
- <div class="discussion">
1105
-
1106
- <p>Execute the provided command using the open4.popen4 library. This is
1107
- generally only used by Cygwin and *nix variants (including OS X).</p>
1108
-
1109
-
1110
- </div>
1111
- </div>
1112
- <div class="tags">
1113
-
1114
- </div><table class="source_code">
1115
- <tr>
1116
- <td>
1117
- <pre class="lines">
1118
-
1119
-
1120
- 52
1121
- 53
1122
- 54
1123
- 55
1124
- 56
1125
- 57
1126
- 58
1127
- 59</pre>
1128
- </td>
1129
- <td>
1130
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 52</span>
1131
-
1132
- <span class='kw'>def</span> <span class='id execute_open4'>execute_open4</span> <span class='op'>*</span><span class='id command'>command</span>
1133
- <span class='id execute_with_block'>execute_with_block</span> <span class='op'>*</span><span class='id command'>command</span> <span class='kw'>do</span>
1134
- <span class='comment'># Not sure about the join - with the 1.0 push, we're
1135
- </span> <span class='comment'># sending in 2 args - the exe path, and options as a string.
1136
- </span> <span class='comment'># This was new and was causing problems...
1137
- </span> <span class='ivar'>@pid</span><span class='comma'>,</span> <span class='ivar'>@w</span><span class='comma'>,</span> <span class='ivar'>@r</span><span class='comma'>,</span> <span class='ivar'>@e</span> <span class='op'>=</span> <span class='id open4_popen4_block'>open4_popen4_block</span> <span class='op'>*</span><span class='id command'>command</span><span class='period'>.</span><span class='id join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'> </span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
1138
- <span class='kw'>end</span>
1139
- <span class='kw'>end</span></pre>
1140
- </td>
1141
- </tr>
1142
- </table>
1143
- </div>
1144
-
1145
- <div class="method_details ">
1146
- <p class="signature " id="execute_win32-instance_method">
1147
-
1148
- - (<tt>Object</tt>) <strong>execute_win32</strong>(*command)
1149
-
1150
-
1151
-
1152
- </p><div class="docstring">
1153
- <div class="discussion">
1154
-
1155
- <p>Execute the provided command using the win32-open3 library. This should
1156
- only be used on Windows systems (even 64 bit).</p>
1157
-
1158
-
1159
- </div>
1160
- </div>
1161
- <div class="tags">
1162
-
1163
- </div><table class="source_code">
1164
- <tr>
1165
- <td>
1166
- <pre class="lines">
1167
-
1168
-
1169
- 65
1170
- 66
1171
- 67
1172
- 68
1173
- 69</pre>
1174
- </td>
1175
- <td>
1176
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 65</span>
1177
-
1178
- <span class='kw'>def</span> <span class='id execute_win32'>execute_win32</span><span class='lparen'>(</span><span class='op'>*</span><span class='id command'>command</span><span class='rparen'>)</span>
1179
- <span class='id execute_with_block'>execute_with_block</span> <span class='op'>*</span><span class='id command'>command</span> <span class='kw'>do</span>
1180
- <span class='ivar'>@pid</span><span class='comma'>,</span> <span class='ivar'>@w</span><span class='comma'>,</span> <span class='ivar'>@r</span><span class='comma'>,</span> <span class='ivar'>@e</span> <span class='op'>=</span> <span class='id io_popen_block'>io_popen_block</span> <span class='op'>*</span><span class='id command'>command</span><span class='period'>.</span><span class='id join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'> </span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
1181
- <span class='kw'>end</span>
1182
- <span class='kw'>end</span></pre>
1183
- </td>
1184
- </tr>
1185
- </table>
1186
- </div>
1187
-
1188
- <div class="method_details ">
1189
- <p class="signature " id="flush-instance_method">
1190
-
1191
- - (<tt>Object</tt>) <strong>flush</strong>
1192
-
1193
-
1194
-
1195
- </p><div class="docstring">
1196
- <div class="discussion">
1197
-
1198
- <p>Flush the write IO to the process.</p>
1199
-
1200
-
1201
- </div>
1202
- </div>
1203
- <div class="tags">
1204
-
1205
- </div><table class="source_code">
1206
- <tr>
1207
- <td>
1208
- <pre class="lines">
1209
-
1210
-
1211
- 123
1212
- 124
1213
- 125</pre>
1214
- </td>
1215
- <td>
1216
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 123</span>
1217
-
1218
- <span class='kw'>def</span> <span class='id flush'>flush</span>
1219
- <span class='ivar'>@w</span><span class='period'>.</span><span class='id flush'>flush</span>
1220
- <span class='kw'>end</span></pre>
1221
- </td>
1222
- </tr>
1223
- </table>
1224
- </div>
1225
-
1226
- <div class="method_details ">
1227
- <p class="signature " id="getc-instance_method">
1228
-
1229
- - (<tt>Object</tt>) <strong>getc</strong>
1230
-
1231
-
1232
-
1233
- </p><div class="docstring">
1234
- <div class="discussion">
1235
-
1236
- <p>Get user input on the read stream from the process.</p>
1237
-
1238
-
1239
- </div>
1240
- </div>
1241
- <div class="tags">
1242
-
1243
- </div><table class="source_code">
1244
- <tr>
1245
- <td>
1246
- <pre class="lines">
1247
-
1248
-
1249
- 129
1250
- 130
1251
- 131</pre>
1252
- </td>
1253
- <td>
1254
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 129</span>
1255
-
1256
- <span class='kw'>def</span> <span class='id getc'>getc</span>
1257
- <span class='ivar'>@r</span><span class='period'>.</span><span class='id getc'>getc</span>
1258
- <span class='kw'>end</span></pre>
1259
- </td>
1260
- </tr>
1261
- </table>
1262
- </div>
1263
-
1264
- <div class="method_details ">
1265
- <p class="signature " id="kill-instance_method">
1266
-
1267
- - (<tt>Object</tt>) <strong>kill</strong>
1268
-
1269
-
1270
-
1271
- </p><div class="docstring">
1272
- <div class="discussion">
1273
-
1274
- <p>Kill the process.</p>
1275
-
1276
-
1277
- </div>
1278
- </div>
1279
- <div class="tags">
1280
-
1281
- </div><table class="source_code">
1282
- <tr>
1283
- <td>
1284
- <pre class="lines">
1285
-
1286
-
1287
- 79
1288
- 80
1289
- 81</pre>
1290
- </td>
1291
- <td>
1292
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 79</span>
1293
-
1294
- <span class='kw'>def</span> <span class='id kill'>kill</span>
1295
- <span class='id update_status'>update_status</span> <span class='int'>9</span>
1296
- <span class='kw'>end</span></pre>
1297
- </td>
1298
- </tr>
1299
- </table>
1300
- </div>
1301
-
1302
- <div class="method_details ">
1303
- <p class="signature " id="print-instance_method">
1304
-
1305
- - (<tt>Object</tt>) <strong>print</strong>(msg)
1306
-
1307
-
1308
-
1309
- </p><div class="docstring">
1310
- <div class="discussion">
1311
-
1312
- <p>Print some characters to process without an end of line character.</p>
1313
-
1314
-
1315
- </div>
1316
- </div>
1317
- <div class="tags">
1318
-
1319
- </div><table class="source_code">
1320
- <tr>
1321
- <td>
1322
- <pre class="lines">
1323
-
1324
-
1325
- 135
1326
- 136
1327
- 137</pre>
1328
- </td>
1329
- <td>
1330
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 135</span>
1331
-
1332
- <span class='kw'>def</span> <span class='id print'>print</span> <span class='id msg'>msg</span>
1333
- <span class='ivar'>@w</span><span class='period'>.</span><span class='id print'>print</span> <span class='id msg'>msg</span>
1334
- <span class='kw'>end</span></pre>
1335
- </td>
1336
- </tr>
1337
- </table>
1338
- </div>
1339
-
1340
- <div class="method_details ">
1341
- <p class="signature " id="puts-instance_method">
1342
-
1343
- - (<tt>Object</tt>) <strong>puts</strong>(msg)
1344
-
1345
-
1346
-
1347
- </p><div class="docstring">
1348
- <div class="discussion">
1349
-
1350
- <p>Print characters to the process followed by an end of line.</p>
1351
-
1352
-
1353
- </div>
1354
- </div>
1355
- <div class="tags">
1356
-
1357
- </div><table class="source_code">
1358
- <tr>
1359
- <td>
1360
- <pre class="lines">
1361
-
1362
-
1363
- 141
1364
- 142
1365
- 143</pre>
1366
- </td>
1367
- <td>
1368
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 141</span>
1369
-
1370
- <span class='kw'>def</span> <span class='id puts'>puts</span><span class='lparen'>(</span><span class='id msg'>msg</span><span class='rparen'>)</span>
1371
- <span class='ivar'>@w</span><span class='period'>.</span><span class='id puts'>puts</span><span class='lparen'>(</span><span class='id msg'>msg</span><span class='rparen'>)</span>
1372
- <span class='kw'>end</span></pre>
1373
- </td>
1374
- </tr>
1375
- </table>
1376
- </div>
1377
-
1378
- <div class="method_details ">
1379
- <p class="signature " id="read-instance_method">
1380
-
1381
- - (<tt>Object</tt>) <strong>read</strong>
1382
-
1383
-
1384
-
1385
- </p><div class="docstring">
1386
- <div class="discussion">
1387
-
1388
- <p>Wait for the process to end and return the entire standard output.</p>
1389
-
1390
-
1391
- </div>
1392
- </div>
1393
- <div class="tags">
1394
-
1395
- </div><table class="source_code">
1396
- <tr>
1397
- <td>
1398
- <pre class="lines">
1399
-
1400
-
1401
- 153
1402
- 154
1403
- 155</pre>
1404
- </td>
1405
- <td>
1406
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 153</span>
1407
-
1408
- <span class='kw'>def</span> <span class='id read'>read</span>
1409
- <span class='kw'>return</span> <span class='ivar'>@r</span><span class='period'>.</span><span class='id read'>read</span>
1410
- <span class='kw'>end</span></pre>
1411
- </td>
1412
- </tr>
1413
- </table>
1414
- </div>
1415
-
1416
- <div class="method_details ">
1417
- <p class="signature " id="read_err-instance_method">
1418
-
1419
- - (<tt>Object</tt>) <strong>read_err</strong>
1420
-
1421
-
1422
-
1423
- </p><div class="docstring">
1424
- <div class="discussion">
1425
-
1426
- <p>Wait for the process to end and return the entire standard error.</p>
1427
-
1428
-
1429
- </div>
1430
- </div>
1431
- <div class="tags">
1432
-
1433
- </div><table class="source_code">
1434
- <tr>
1435
- <td>
1436
- <pre class="lines">
1437
-
1438
-
1439
- 159
1440
- 160
1441
- 161</pre>
1442
- </td>
1443
- <td>
1444
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 159</span>
1445
-
1446
- <span class='kw'>def</span> <span class='id read_err'>read_err</span>
1447
- <span class='kw'>return</span> <span class='ivar'>@e</span><span class='period'>.</span><span class='id read'>read</span>
1448
- <span class='kw'>end</span></pre>
1449
- </td>
1450
- </tr>
1451
- </table>
1452
- </div>
1453
-
1454
- <div class="method_details ">
1455
- <p class="signature " id="readlines-instance_method">
1456
-
1457
- - (<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>) <strong>readlines</strong>(count)
1458
-
1459
-
1460
-
1461
- </p><div class="docstring">
1462
- <div class="discussion">
1463
-
1464
- <p>Read <tt>count</tt> lines from the process standard out.</p>
1465
-
1466
-
1467
- </div>
1468
- </div>
1469
- <div class="tags">
1470
- <h3>Parameters:</h3>
1471
- <ul class="param">
1472
-
1473
- <li>
1474
-
1475
- <span class='type'>(<tt>Integer</tt>)</span>
1476
-
1477
-
1478
- <span class='name'>count</span>
1479
-
1480
-
1481
-
1482
- &mdash;
1483
- <div class='inline'>
1484
- <p>Number of lines to read.</p>
1485
- </div>
1486
-
1487
- </li>
1488
-
1489
- </ul>
1490
- <h3>Returns:</h3>
1491
- <ul class="return">
1492
-
1493
- <li>
1494
-
1495
- <span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
1496
-
1497
-
1498
-
1499
-
1500
- </li>
1501
-
1502
- </ul>
1503
-
1504
- </div><table class="source_code">
1505
- <tr>
1506
- <td>
1507
- <pre class="lines">
1508
-
1509
-
1510
- 117
1511
- 118
1512
- 119</pre>
1513
- </td>
1514
- <td>
1515
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 117</span>
1516
-
1517
- <span class='kw'>def</span> <span class='id readlines'>readlines</span> <span class='id count'>count</span>
1518
- <span class='ivar'>@r</span><span class='period'>.</span><span class='id readlines'>readlines</span> <span class='id count'>count</span>
1519
- <span class='kw'>end</span></pre>
1520
- </td>
1521
- </tr>
1522
- </table>
1523
- </div>
1524
-
1525
- <div class="method_details ">
1526
- <p class="signature " id="readpartial-instance_method">
1527
-
1528
- - (<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>) <strong>readpartial</strong>(count)
1529
-
1530
-
1531
-
1532
- </p><div class="docstring">
1533
- <div class="discussion">
1534
-
1535
- <p>Read <tt>count</tt> characters from the process standard out.</p>
1536
-
1537
-
1538
- </div>
1539
- </div>
1540
- <div class="tags">
1541
- <h3>Parameters:</h3>
1542
- <ul class="param">
1543
-
1544
- <li>
1545
-
1546
- <span class='type'>(<tt>Integer</tt>)</span>
1547
-
1548
-
1549
- <span class='name'>count</span>
1550
-
1551
-
1552
-
1553
- &mdash;
1554
- <div class='inline'>
1555
- <p>Number of characters to read.</p>
1556
- </div>
1557
-
1558
- </li>
1559
-
1560
- </ul>
1561
- <h3>Returns:</h3>
1562
- <ul class="return">
1563
-
1564
- <li>
1565
-
1566
- <span class='type'>(<tt><span class='object_link'><a href="../String.html" title="String (class)">String</a></span></tt>)</span>
1567
-
1568
-
1569
-
1570
-
1571
- </li>
1572
-
1573
- </ul>
1574
-
1575
- </div><table class="source_code">
1576
- <tr>
1577
- <td>
1578
- <pre class="lines">
1579
-
1580
-
1581
- 108
1582
- 109
1583
- 110</pre>
1584
- </td>
1585
- <td>
1586
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 108</span>
1587
-
1588
- <span class='kw'>def</span> <span class='id readpartial'>readpartial</span> <span class='id count'>count</span>
1589
- <span class='ivar'>@r</span><span class='period'>.</span><span class='id readpartial'>readpartial</span> <span class='id count'>count</span>
1590
- <span class='kw'>end</span></pre>
1591
- </td>
1592
- </tr>
1593
- </table>
1594
- </div>
1595
-
1596
- <div class="method_details ">
1597
- <p class="signature " id="readpartial_err-instance_method">
1598
-
1599
- - (<tt>Object</tt>) <strong>readpartial_err</strong>(count)
1600
-
1601
-
1602
-
1603
- </p><table class="source_code">
1604
- <tr>
1605
- <td>
1606
- <pre class="lines">
1607
-
1608
-
1609
- 163
1610
- 164
1611
- 165</pre>
1612
- </td>
1613
- <td>
1614
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 163</span>
1615
-
1616
- <span class='kw'>def</span> <span class='id readpartial_err'>readpartial_err</span> <span class='id count'>count</span>
1617
- <span class='kw'>return</span> <span class='ivar'>@e</span><span class='period'>.</span><span class='id readpartial'>readpartial</span> <span class='id count'>count</span>
1618
- <span class='kw'>end</span></pre>
1619
- </td>
1620
- </tr>
1621
- </table>
1622
- </div>
1623
-
1624
- <div class="method_details ">
1625
- <p class="signature " id="update_status-instance_method">
1626
-
1627
- - (<tt>Object</tt>) <strong>update_status</strong>(sig = 0)
1628
-
1629
-
1630
-
1631
- </p><div class="docstring">
1632
- <div class="discussion">
1633
-
1634
- <p>Send an update signal to the process.</p>
1635
-
1636
-
1637
- </div>
1638
- </div>
1639
- <div class="tags">
1640
- <h3>Parameters:</h3>
1641
- <ul class="param">
1642
-
1643
- <li>
1644
-
1645
- <span class='type'>(<tt>Integer</tt>)</span>
1646
-
1647
-
1648
- <span class='name'>sig</span>
1649
-
1650
-
1651
- <em class="default">(defaults to: <tt>0</tt>)</em>
1652
-
1653
-
1654
- &mdash;
1655
- <div class='inline'>
1656
- <p>The signal to send, default 0 (or no action requested)</p>
1657
- </div>
1658
-
1659
- </li>
1660
-
1661
- </ul>
1662
-
1663
- </div><table class="source_code">
1664
- <tr>
1665
- <td>
1666
- <pre class="lines">
1667
-
1668
-
1669
- 93
1670
- 94
1671
- 95
1672
- 96
1673
- 97
1674
- 98
1675
- 99
1676
- 100
1677
- 101</pre>
1678
- </td>
1679
- <td>
1680
- <pre class="code"><span class="info file"># File 'lib/sprout/process_runner.rb', line 93</span>
1681
-
1682
- <span class='kw'>def</span> <span class='id update_status'>update_status</span> <span class='id sig'>sig</span><span class='op'>=</span><span class='int'>0</span>
1683
- <span class='id pid_int'>pid_int</span> <span class='op'>=</span> <span class='const'>Integer</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='embexpr_beg'>#{</span> <span class='ivar'>@pid</span> <span class='rbrace'>}</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
1684
- <span class='kw'>begin</span>
1685
- <span class='const'>Process</span><span class='op'>::</span><span class='id kill'>kill</span> <span class='id sig'>sig</span><span class='comma'>,</span> <span class='id pid_int'>pid_int</span>
1686
- <span class='kw'>true</span>
1687
- <span class='kw'>rescue</span> <span class='const'>Errno</span><span class='op'>::</span><span class='const'>ESRCH</span>
1688
- <span class='kw'>false</span>
1689
- <span class='kw'>end</span>
1690
- <span class='kw'>end</span></pre>
1691
- </td>
1692
- </tr>
1693
- </table>
1694
- </div>
1695
-
1696
- </div>
1697
-
1698
- </div>
1699
-
1700
- <div id="footer">
1701
- Generated on Fri Apr 29 18:33:07 2011 by
1702
- <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
1703
- 0.6.3 (ruby-1.9.2).
1704
- </div>
1705
-
1706
- </body>
1707
- </html>