rumai 3.2.0 → 3.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/CREDITS +4 -3
- data/HISTORY +327 -0
- data/INSTALL +31 -0
- data/README +92 -0
- data/USAGE +297 -0
- data/bin/rumai +9 -22
- data/doc/api/IO.html +119 -0
- data/doc/api/Integer.html +171 -0
- data/doc/api/Rumai.html +1270 -0
- data/doc/api/Rumai/Area.html +1485 -0
- data/doc/api/Rumai/Chain.html +301 -0
- data/doc/api/Rumai/Client.html +2451 -0
- data/doc/api/Rumai/ClientContainer.html +301 -0
- data/doc/api/Rumai/ExportInstanceMethods.html +103 -0
- data/doc/api/Rumai/IXP.html +94 -0
- data/doc/api/Rumai/IXP/Agent.html +1625 -0
- data/doc/api/Rumai/IXP/Agent/FidStream.html +959 -0
- data/doc/api/Rumai/IXP/Agent/RangedPool.html +381 -0
- data/doc/api/Rumai/IXP/Error.html +110 -0
- data/doc/api/Rumai/IXP/Fcall.html +503 -0
- data/doc/api/Rumai/IXP/Qid.html +207 -0
- data/doc/api/Rumai/IXP/Rattach.html +148 -0
- data/doc/api/Rumai/IXP/Rauth.html +148 -0
- data/doc/api/Rumai/IXP/Rclunk.html +148 -0
- data/doc/api/Rumai/IXP/Rcreate.html +148 -0
- data/doc/api/Rumai/IXP/Rerror.html +148 -0
- data/doc/api/Rumai/IXP/Rflush.html +148 -0
- data/doc/api/Rumai/IXP/Ropen.html +148 -0
- data/doc/api/Rumai/IXP/Rread.html +148 -0
- data/doc/api/Rumai/IXP/Rremove.html +148 -0
- data/doc/api/Rumai/IXP/Rstat.html +148 -0
- data/doc/api/Rumai/IXP/Rversion.html +148 -0
- data/doc/api/Rumai/IXP/Rwalk.html +148 -0
- data/doc/api/Rumai/IXP/Rwrite.html +148 -0
- data/doc/api/Rumai/IXP/Rwstat.html +148 -0
- data/doc/api/Rumai/IXP/Stat.html +335 -0
- data/doc/api/Rumai/IXP/Stream.html +194 -0
- data/doc/api/Rumai/IXP/Struct.html +586 -0
- data/doc/api/Rumai/IXP/Struct/ClassField.html +242 -0
- data/doc/api/Rumai/IXP/Struct/Field.html +782 -0
- data/doc/api/Rumai/IXP/Struct/Field/CounteeField.html +227 -0
- data/doc/api/Rumai/IXP/Struct/Field/CounterField.html +153 -0
- data/doc/api/Rumai/IXP/Struct/Integer8Field.html +242 -0
- data/doc/api/Rumai/IXP/Struct/StringField.html +206 -0
- data/doc/api/Rumai/IXP/Tattach.html +148 -0
- data/doc/api/Rumai/IXP/Tauth.html +148 -0
- data/doc/api/Rumai/IXP/Tclunk.html +148 -0
- data/doc/api/Rumai/IXP/Tcreate.html +148 -0
- data/doc/api/Rumai/IXP/Terror.html +231 -0
- data/doc/api/Rumai/IXP/Tflush.html +148 -0
- data/doc/api/Rumai/IXP/Topen.html +240 -0
- data/doc/api/Rumai/IXP/Tread.html +148 -0
- data/doc/api/Rumai/IXP/Tremove.html +148 -0
- data/doc/api/Rumai/IXP/Tstat.html +148 -0
- data/doc/api/Rumai/IXP/Tversion.html +162 -0
- data/doc/api/Rumai/IXP/Twalk.html +148 -0
- data/doc/api/Rumai/IXP/Twrite.html +148 -0
- data/doc/api/Rumai/IXP/Twstat.html +148 -0
- data/doc/api/Rumai/Node.html +1406 -0
- data/doc/api/Rumai/View.html +1587 -0
- data/doc/api/Rumai/WidgetImpl.html +333 -0
- data/doc/api/Rumai/WidgetNode.html +246 -0
- data/doc/api/String.html +258 -0
- data/doc/api/StringIO.html +119 -0
- data/doc/api/Time.html +247 -0
- data/doc/api/_index.html +581 -0
- data/doc/api/class_list.html +36 -0
- data/doc/api/css/common.css +1 -0
- data/doc/api/css/full_list.css +50 -0
- data/doc/api/css/style.css +273 -0
- data/doc/api/file.LICENSE.html +73 -0
- data/doc/api/file_list.html +38 -0
- data/doc/api/frames.html +13 -0
- data/doc/api/index.html +72 -13
- data/doc/api/js/app.js +111 -0
- data/doc/api/js/full_list.js +117 -0
- data/doc/api/js/{jquery-1.3.2.min.js → jquery.js} +0 -0
- data/doc/api/method_list.html +1483 -0
- data/doc/api/top-level-namespace.html +89 -0
- data/doc/index.erb +18 -13
- data/doc/index.html +331 -386
- data/lib/rumai.rb +1 -18
- data/lib/rumai/fs.rb +11 -11
- data/lib/rumai/inochi.rb +48 -0
- data/lib/rumai/inochi.yaml +94 -0
- data/lib/rumai/ixp.rb +0 -4
- data/lib/rumai/ixp/message.rb +6 -17
- data/lib/rumai/ixp/transport.rb +39 -30
- data/lib/rumai/wm.rb +35 -37
- data/test/rumai/inochi_test.rb +17 -0
- data/test/rumai/ixp/message_test.rb +245 -0
- data/test/runner +25 -0
- data/test/test_helper.rb +1 -0
- metadata +107 -125
- data/doc/api/apple-touch-icon.png +0 -0
- data/doc/api/classes/IO.html +0 -72
- data/doc/api/classes/Integer.html +0 -110
- data/doc/api/classes/Object.html +0 -60
- data/doc/api/classes/Rumai.html +0 -837
- data/doc/api/classes/Rumai/Area.html +0 -909
- data/doc/api/classes/Rumai/Chain.html +0 -197
- data/doc/api/classes/Rumai/Client.html +0 -1526
- data/doc/api/classes/Rumai/ClientContainer.html +0 -191
- data/doc/api/classes/Rumai/ExportInstanceMethods.html +0 -69
- data/doc/api/classes/Rumai/IXP.html +0 -131
- data/doc/api/classes/Rumai/IXP/Agent.html +0 -941
- data/doc/api/classes/Rumai/IXP/Agent/FidStream.html +0 -456
- data/doc/api/classes/Rumai/IXP/Agent/MODES.html +0 -108
- data/doc/api/classes/Rumai/IXP/Agent/RangedPool.html +0 -241
- data/doc/api/classes/Rumai/IXP/Error.html +0 -67
- data/doc/api/classes/Rumai/IXP/Fcall.html +0 -323
- data/doc/api/classes/Rumai/IXP/Qid.html +0 -153
- data/doc/api/classes/Rumai/IXP/Rattach.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rauth.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rclunk.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rcreate.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rerror.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rflush.html +0 -67
- data/doc/api/classes/Rumai/IXP/Ropen.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rread.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rremove.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rstat.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rversion.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rwalk.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rwrite.html +0 -67
- data/doc/api/classes/Rumai/IXP/Rwstat.html +0 -67
- data/doc/api/classes/Rumai/IXP/Stat.html +0 -252
- data/doc/api/classes/Rumai/IXP/Stream.html +0 -131
- data/doc/api/classes/Rumai/IXP/Struct.html +0 -311
- data/doc/api/classes/Rumai/IXP/Struct/Field.html +0 -415
- data/doc/api/classes/Rumai/IXP/Struct/Field/CounteeField.html +0 -153
- data/doc/api/classes/Rumai/IXP/Struct/Field/CounterField.html +0 -104
- data/doc/api/classes/Rumai/IXP/Tattach.html +0 -68
- data/doc/api/classes/Rumai/IXP/Tauth.html +0 -67
- data/doc/api/classes/Rumai/IXP/Tclunk.html +0 -67
- data/doc/api/classes/Rumai/IXP/Tcreate.html +0 -68
- data/doc/api/classes/Rumai/IXP/Terror.html +0 -110
- data/doc/api/classes/Rumai/IXP/Tflush.html +0 -67
- data/doc/api/classes/Rumai/IXP/Topen.html +0 -165
- data/doc/api/classes/Rumai/IXP/Tread.html +0 -67
- data/doc/api/classes/Rumai/IXP/Tremove.html +0 -67
- data/doc/api/classes/Rumai/IXP/Tstat.html +0 -67
- data/doc/api/classes/Rumai/IXP/Tversion.html +0 -86
- data/doc/api/classes/Rumai/IXP/Twalk.html +0 -68
- data/doc/api/classes/Rumai/IXP/Twrite.html +0 -68
- data/doc/api/classes/Rumai/IXP/Twstat.html +0 -67
- data/doc/api/classes/Rumai/Node.html +0 -821
- data/doc/api/classes/Rumai/View.html +0 -967
- data/doc/api/classes/Rumai/WidgetImpl.html +0 -65
- data/doc/api/classes/Rumai/WidgetNode.html +0 -68
- data/doc/api/classes/String.html +0 -163
- data/doc/api/classes/StringIO.html +0 -72
- data/doc/api/classes/Time.html +0 -156
- data/doc/api/created.rid +0 -1
- data/doc/api/css/main.css +0 -263
- data/doc/api/css/panel.css +0 -383
- data/doc/api/css/reset.css +0 -53
- data/doc/api/favicon.ico +0 -0
- data/doc/api/files/CREDITS.html +0 -67
- data/doc/api/files/LICENSE.html +0 -76
- data/doc/api/files/lib/rumai/fs_rb.html +0 -75
- data/doc/api/files/lib/rumai/ixp/message_rb.html +0 -91
- data/doc/api/files/lib/rumai/ixp/transport_rb.html +0 -75
- data/doc/api/files/lib/rumai/ixp_rb.html +0 -69
- data/doc/api/files/lib/rumai/wm_rb.html +0 -77
- data/doc/api/files/lib/rumai_rb.html +0 -65
- data/doc/api/i/arrows.png +0 -0
- data/doc/api/i/results_bg.png +0 -0
- data/doc/api/i/tree_bg.png +0 -0
- data/doc/api/js/jquery-effect.js +0 -593
- data/doc/api/js/main.js +0 -22
- data/doc/api/js/searchdoc.js +0 -628
- data/doc/api/panel/index.html +0 -71
- data/doc/api/panel/search_index.js +0 -1
- data/doc/api/panel/tree.js +0 -1
- data/doc/history.erb +0 -233
- data/doc/intro.erb +0 -70
- data/doc/setup.erb +0 -144
- data/doc/usage.erb +0 -308
- data/rakefile +0 -14
- data/test/rumai/ixp/message.rb +0 -237
data/USAGE
ADDED
@@ -0,0 +1,297 @@
|
|
1
|
+
%# #%
|
2
|
+
%# You can read this document in its full glory by #%
|
3
|
+
%# opening ./doc/index.html in your favorite Web browser. #%
|
4
|
+
%# #%
|
5
|
+
|
6
|
+
%#----------------------------------------------------------------------------
|
7
|
+
%| section "Interactive shell", "shell"
|
8
|
+
%#----------------------------------------------------------------------------
|
9
|
+
|
10
|
+
%|command! "rumai"
|
11
|
+
|
12
|
+
This command starts an IRB (Interactive Ruby Shell) session, which places
|
13
|
+
you a command prompt like this:
|
14
|
+
|
15
|
+
irb(Rumai):001:0>
|
16
|
+
|
17
|
+
The <tt>irb(Rumai)</tt> token in the command prompt indicates that
|
18
|
+
commands will be evaluated _inside_ the `Rumai` module. As a result, you
|
19
|
+
can omit the "Rumai" prefix from your commands if you wish.
|
20
|
+
|
21
|
+
For example, to get the current client object, you can type `curr_client`
|
22
|
+
instead of having to type `Rumai.curr_client` at the prompt. Both
|
23
|
+
commands achieve the same effect.
|
24
|
+
|
25
|
+
The next thing to note is that **TAB completion** is enabled by default.
|
26
|
+
So you can type part of a command and press the TAB key to see a list of
|
27
|
+
possible completions.
|
28
|
+
|
29
|
+
%#----------------------------------------------------------------------------
|
30
|
+
%| section "Live demonstration", "Tutorial"
|
31
|
+
%#----------------------------------------------------------------------------
|
32
|
+
|
33
|
+
Now that you know <%= xref "shell", "how to start the interactive shell" %>,
|
34
|
+
let us walk through a (hopefully) quick demonstration that highlights the
|
35
|
+
main features of Rumai. You can follow along by copying & pasting the
|
36
|
+
presented commands into the interactive shell.
|
37
|
+
|
38
|
+
%|open_terms = lambda do
|
39
|
+
Launch a few terminals so that we have something to work with:
|
40
|
+
|
41
|
+
%|code :ruby
|
42
|
+
colors = %w[ red green blue black orange brown gray navy gold ]
|
43
|
+
colors.each {|c| system "xterm -bg #{c} -title #{c} -e sh -c read &" }
|
44
|
+
|
45
|
+
%|close_terms = lambda do
|
46
|
+
Close the terminals we launched earlier:
|
47
|
+
|
48
|
+
%|code :ruby
|
49
|
+
terms = curr_view.clients.select {|c| colors.include? c.label.read }
|
50
|
+
terms.each {|c| c.kill }
|
51
|
+
|
52
|
+
%#--------------------------------------------------------------------------
|
53
|
+
%| section "Automated client arrangement"
|
54
|
+
%#--------------------------------------------------------------------------
|
55
|
+
|
56
|
+
% open_terms.call
|
57
|
+
|
58
|
+
Arrange all clients in a grid:
|
59
|
+
|
60
|
+
%|code :ruby
|
61
|
+
curr_view.arrange_in_grid
|
62
|
+
|
63
|
+
Arrange all clients in a diamond shape:
|
64
|
+
|
65
|
+
%|code :ruby
|
66
|
+
curr_view.arrange_in_diamond
|
67
|
+
|
68
|
+
Arrange all clients like LarsWM does:
|
69
|
+
|
70
|
+
%|code :ruby
|
71
|
+
curr_view.arrange_as_larswm
|
72
|
+
|
73
|
+
% close_terms.call
|
74
|
+
|
75
|
+
%#--------------------------------------------------------------------------
|
76
|
+
%| section "Multiple client grouping"
|
77
|
+
%#--------------------------------------------------------------------------
|
78
|
+
|
79
|
+
% open_terms.call
|
80
|
+
|
81
|
+
Add the red, green, and blue terminals into the "grouping":
|
82
|
+
|
83
|
+
%|code :ruby
|
84
|
+
terms = curr_view.clients.select do |c|
|
85
|
+
%%w[red green blue].include? c.label.read
|
86
|
+
end
|
87
|
+
terms.each {|c| c.group }
|
88
|
+
|
89
|
+
You should now see a new button labelled as "@" on the left-hand side of
|
90
|
+
wmii's bar, indicating that there is now a new view labelled "@" in wmii.
|
91
|
+
Let us inspect what clients this mysterious view contains:
|
92
|
+
|
93
|
+
%|code :ruby
|
94
|
+
v = View.new "@"
|
95
|
+
puts v.clients.map {|c| c.label.read }
|
96
|
+
|
97
|
+
Aha! The mysterious view contains the red, green, and blue clients we
|
98
|
+
recently "grouped". Thus, by adding a client to the "grouping", we are
|
99
|
+
simply tagging the client with the "@" token.
|
100
|
+
|
101
|
+
Now that we have put some clients into the "grouping", let us move all
|
102
|
+
clients in the grouping to the floating area in the current view:
|
103
|
+
|
104
|
+
%|code :ruby
|
105
|
+
grouping.each {|c| c.send "toggle" }
|
106
|
+
|
107
|
+
Neat! Let us bring them back into the managed area:
|
108
|
+
|
109
|
+
%|code :ruby
|
110
|
+
grouping.each {|c| c.send "toggle" }
|
111
|
+
|
112
|
+
% close_terms.call
|
113
|
+
|
114
|
+
In summary, you can select multiple clients (by adding them to the
|
115
|
+
"grouping") and perform operations on them. This is useful when you want
|
116
|
+
to do something with a group of clients but do not want to manually focus
|
117
|
+
one, perform the action, focus the next one, and so on.
|
118
|
+
|
119
|
+
Another important aspect is that selected clients stay selected until they
|
120
|
+
are unselected. This allows you to continue performing tasks on the
|
121
|
+
selection without having to reselect the same clients after every
|
122
|
+
operation.
|
123
|
+
|
124
|
+
%#--------------------------------------------------------------------------
|
125
|
+
%| section "Easy column manipulation"
|
126
|
+
%#--------------------------------------------------------------------------
|
127
|
+
|
128
|
+
% open_terms.call
|
129
|
+
|
130
|
+
You can insert a group of clients to the top, bottom, or after the
|
131
|
+
currently focused client of _any_ column using Array-like methods.
|
132
|
+
|
133
|
+
Give each client its own column (one client per column):
|
134
|
+
|
135
|
+
%|code :ruby
|
136
|
+
curr_view.each_column {|c| c.length = 1 }
|
137
|
+
|
138
|
+
Put (at most) three clients in every column:
|
139
|
+
|
140
|
+
%|code :ruby
|
141
|
+
curr_view.each_column {|c| c.length = 3 }
|
142
|
+
|
143
|
+
Move the red, green, and blue clients into the floating area:
|
144
|
+
|
145
|
+
%|code :ruby
|
146
|
+
rgb = %w[red green blue]
|
147
|
+
terms = curr_view.clients.select {|c| rgb.include? c.label.read }
|
148
|
+
curr_view.areas[0].push terms
|
149
|
+
|
150
|
+
Slurp all floating clients into the last column:
|
151
|
+
|
152
|
+
%|code :ruby
|
153
|
+
list = curr_view.areas
|
154
|
+
a, b = list.first, list.last
|
155
|
+
b.concat a
|
156
|
+
|
157
|
+
Set the last column's layout to stacking mode:
|
158
|
+
|
159
|
+
%|code :ruby
|
160
|
+
b.layout = 'stack'
|
161
|
+
|
162
|
+
Move the red, green, and blue clients to the top of the second column:
|
163
|
+
|
164
|
+
%|code :ruby
|
165
|
+
curr_view.areas[2].unshift terms
|
166
|
+
|
167
|
+
Move the red, green, and blue clients to the bottom of the third column:
|
168
|
+
|
169
|
+
%|code :ruby
|
170
|
+
curr_view.areas[3].push terms
|
171
|
+
|
172
|
+
% close_terms.call
|
173
|
+
|
174
|
+
%#--------------------------------------------------------------------------
|
175
|
+
%| section "Easy client manipulation"
|
176
|
+
%#--------------------------------------------------------------------------
|
177
|
+
|
178
|
+
% open_terms.call
|
179
|
+
|
180
|
+
Obtain a reference to the red client:
|
181
|
+
|
182
|
+
%|code :ruby
|
183
|
+
red = curr_view.clients.find {|c| c.label.read == "red" }
|
184
|
+
|
185
|
+
Show the red client's current tags:
|
186
|
+
|
187
|
+
%|code :ruby
|
188
|
+
red.tags
|
189
|
+
|
190
|
+
Add the "foo" and "bar" tags to the red client:
|
191
|
+
|
192
|
+
%|code :ruby
|
193
|
+
red.tag "foo", "bar"
|
194
|
+
|
195
|
+
Remove the "bar" tag from the red client:
|
196
|
+
|
197
|
+
%|code :ruby
|
198
|
+
red.untag "bar"
|
199
|
+
|
200
|
+
Do complex operations on the red client's tags:
|
201
|
+
|
202
|
+
%|code :ruby
|
203
|
+
red.with_tags { concat %w[a b c]; push 'z'; delete 'c' }
|
204
|
+
|
205
|
+
Focus the next client after the red client:
|
206
|
+
|
207
|
+
%|code :ruby
|
208
|
+
red.next.focus
|
209
|
+
curr_client == red.next #=> true
|
210
|
+
|
211
|
+
Notice that by focusing a client, we make it the current client.
|
212
|
+
|
213
|
+
Focus the red client on a different view:
|
214
|
+
|
215
|
+
%|code :ruby
|
216
|
+
orig = curr_view
|
217
|
+
v = red.views.last
|
218
|
+
red.focus v
|
219
|
+
|
220
|
+
Return to the original view:
|
221
|
+
|
222
|
+
%|code :ruby
|
223
|
+
orig.focus
|
224
|
+
|
225
|
+
Send the red client to the last column:
|
226
|
+
|
227
|
+
%|code :ruby
|
228
|
+
red.send curr_view.areas.last
|
229
|
+
|
230
|
+
% close_terms.call
|
231
|
+
|
232
|
+
%#--------------------------------------------------------------------------
|
233
|
+
%| section "Traversing the file system"
|
234
|
+
%#--------------------------------------------------------------------------
|
235
|
+
|
236
|
+
Show the root node of wmii's IXP file system:
|
237
|
+
|
238
|
+
%|code :ruby
|
239
|
+
fs
|
240
|
+
|
241
|
+
Show the names of all files at the root level:
|
242
|
+
|
243
|
+
%|code :ruby
|
244
|
+
fs.entries
|
245
|
+
|
246
|
+
Show the parent of the root node:
|
247
|
+
|
248
|
+
%|code :ruby
|
249
|
+
fs.parent
|
250
|
+
|
251
|
+
Show the children of the root node:
|
252
|
+
|
253
|
+
%|code :ruby
|
254
|
+
fs.children
|
255
|
+
|
256
|
+
Navigate into to the <tt>/lbar/</tt> directory:
|
257
|
+
|
258
|
+
%|code :ruby
|
259
|
+
n1 = fs.lbar
|
260
|
+
n2 = fs['lbar']
|
261
|
+
n1 == n2 #=> true
|
262
|
+
left_bar = n1
|
263
|
+
|
264
|
+
Notice that you can traverse the file system hierarchy by simply calling
|
265
|
+
methods on node objects. Alternatively, you can traverse by specifying an
|
266
|
+
arbitrary sub-path (relative path) using the `[]` operator on a node.
|
267
|
+
|
268
|
+
Create a new temporary button:
|
269
|
+
|
270
|
+
%|code :ruby
|
271
|
+
b = left_bar.rumai_example # path of new button
|
272
|
+
b.exist? #=> false
|
273
|
+
b.create
|
274
|
+
b.exist? #=> true
|
275
|
+
|
276
|
+
You should now see an empty button on the left-hand side of the wmii bar.
|
277
|
+
|
278
|
+
Color the button black-on-white and label it as "hello world":
|
279
|
+
|
280
|
+
%|code :ruby
|
281
|
+
content = "#000000 #ffffff #000000 hello world"
|
282
|
+
b.write content
|
283
|
+
b.read == content #=> true
|
284
|
+
|
285
|
+
Remove the temporary button:
|
286
|
+
|
287
|
+
%|code :ruby
|
288
|
+
b.remove
|
289
|
+
b.exist? #=> false
|
290
|
+
|
291
|
+
%#--------------------------------------------------------------------------
|
292
|
+
%| section "More commands"
|
293
|
+
%#--------------------------------------------------------------------------
|
294
|
+
|
295
|
+
See the `Rumai` module in the [API documentation](api/index.html) for a
|
296
|
+
complete list of commands (method calls really) and their documentation.
|
297
|
+
|
data/bin/rumai
CHANGED
@@ -2,34 +2,17 @@
|
|
2
2
|
#
|
3
3
|
# This program is an interactive shell for Rumai.
|
4
4
|
#
|
5
|
-
#
|
5
|
+
# Command-line options and arguments given to this program are passed
|
6
|
+
# directly to the underlying IRB (the interactive Ruby shell) session.
|
6
7
|
#
|
7
|
-
# rumai [Options]
|
8
|
-
# rumai [Options] -- Arguments
|
9
|
-
#
|
10
|
-
# Arguments: Command-line options and arguments that should
|
11
|
-
# be passed to `irb`, the interactive Ruby shell.
|
12
|
-
#
|
13
|
-
# Options:
|
14
|
-
#
|
15
|
-
|
16
|
-
#--
|
17
|
-
# Copyright protects this work.
|
18
|
-
# See LICENSE file for details.
|
19
|
-
#++
|
20
|
-
|
21
|
-
require 'rubygems'
|
22
|
-
gem 'inochi', '~> 1'
|
23
|
-
require 'inochi'
|
24
|
-
|
25
|
-
Inochi.main :Rumai
|
26
8
|
|
27
9
|
require 'irb'
|
28
|
-
require 'irb/completion'
|
10
|
+
require 'irb/completion' # enable TAB-completion
|
11
|
+
|
29
12
|
module IRB
|
30
13
|
##
|
31
14
|
# Starts an IRB session *inside* the given object.
|
32
|
-
|
15
|
+
#
|
33
16
|
# This code was adapted from a snippet on Massimiliano Mirra's website:
|
34
17
|
# http://www.therubymine.com/articles/2007/01/29/programmare-dallinterno
|
35
18
|
#
|
@@ -46,4 +29,8 @@ module IRB
|
|
46
29
|
end
|
47
30
|
end
|
48
31
|
|
32
|
+
# start IRB session
|
33
|
+
$LOAD_PATH << File.expand_path('../../lib', __FILE__)
|
34
|
+
require 'rumai'
|
35
|
+
|
49
36
|
IRB.start_session Rumai
|
data/doc/api/IO.html
ADDED
@@ -0,0 +1,119 @@
|
|
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: IO</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 (I)</a> »
|
27
|
+
|
28
|
+
|
29
|
+
<span class="title">IO</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: IO
|
47
|
+
|
48
|
+
|
49
|
+
</h1>
|
50
|
+
|
51
|
+
<dl class="box">
|
52
|
+
|
53
|
+
<dt class="r1">Inherits:</dt>
|
54
|
+
<dd class="r1">
|
55
|
+
<span class="inheritName"><a href="Object.html" title="Object (class)">Object</a></span>
|
56
|
+
|
57
|
+
<ul class="fullTree">
|
58
|
+
<li><a href="Object.html" title="Object (class)">Object</a></li>
|
59
|
+
|
60
|
+
<li class="next">IO</li>
|
61
|
+
|
62
|
+
</ul>
|
63
|
+
<a href="#" class="inheritanceTree">show all</a>
|
64
|
+
|
65
|
+
</dd>
|
66
|
+
|
67
|
+
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
<dt class="r2">Includes:</dt>
|
73
|
+
<dd class="r2"><a href="Rumai/IXP/Stream.html" title="Rumai::IXP::Stream (module)">Rumai::IXP::Stream</a></dd>
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<dt class="r1 last">Defined in:</dt>
|
80
|
+
<dd class="r1 last">lib/rumai/ixp/message.rb</dd>
|
81
|
+
|
82
|
+
</dl>
|
83
|
+
<div class="clear"></div>
|
84
|
+
|
85
|
+
|
86
|
+
<h2>Constant Summary</h2>
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
<h3 class="inherited">Constants included from <a href="Rumai/IXP/Stream.html" title="Rumai::IXP::Stream (module)">Rumai::IXP::Stream</a></h3>
|
95
|
+
<p class="inherited"><a href="Rumai/IXP/Stream.html#PACKING_FLAGS-constant" title="Rumai::IXP::Stream::PACKING_FLAGS (constant)">PACKING_FLAGS</a></p>
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
<h2>Method Summary</h2>
|
105
|
+
|
106
|
+
<h3 class="inherited">Methods included from <a href="Rumai/IXP/Stream.html" title="Rumai::IXP::Stream (module)">Rumai::IXP::Stream</a></h3>
|
107
|
+
<p class="inherited"><a href="Rumai/IXP/Stream.html#read_9p-instance_method" title="Rumai::IXP::Stream#read_9p (method)">#read_9p</a></p>
|
108
|
+
|
109
|
+
|
110
|
+
</div>
|
111
|
+
|
112
|
+
<div id="footer">
|
113
|
+
Generated on Mon Mar 22 22:23:58 2010 by
|
114
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool">yard</a>
|
115
|
+
0.5.4 (ruby-1.9.1).
|
116
|
+
</div>
|
117
|
+
|
118
|
+
</body>
|
119
|
+
</html>
|