ruff 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +59 -0
- data/docs/Ruff.html +4 -4
- data/docs/Ruff/Effect.html +2 -2
- data/docs/Ruff/Handler.html +28 -20
- data/docs/Ruff/Standard.html +115 -0
- data/docs/Ruff/Standard/CurrentTime.html +236 -0
- data/docs/Ruff/Standard/CurrentTime/Instance.html +311 -0
- data/docs/Ruff/Standard/Defer.html +236 -0
- data/docs/Ruff/Standard/Defer/Instance.html +335 -0
- data/docs/Ruff/Standard/State.html +392 -0
- data/docs/Ruff/Standard/State/Instance.html +489 -0
- data/docs/Ruff/Throws.html +2 -2
- data/docs/Ruff/Throws/Eff.html +2 -2
- data/docs/Ruff/Throws/Resend.html +2 -2
- data/docs/_index.html +87 -3
- data/docs/class_list.html +1 -1
- data/docs/file.README.html +66 -4
- data/docs/frames.html +1 -1
- data/docs/index.html +66 -4
- data/docs/method_list.html +171 -3
- data/docs/top-level-namespace.html +2 -2
- data/lib/ruff/handler.rb +11 -9
- data/lib/ruff/standard.rb +6 -0
- data/lib/ruff/standard/current_time.rb +29 -0
- data/lib/ruff/standard/defer.rb +40 -0
- data/lib/ruff/standard/state.rb +64 -0
- data/lib/ruff/version.rb +1 -1
- data/version.h +1 -1
- metadata +12 -1
data/docs/Ruff/Throws.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Module: Ruff::Throws
|
8
8
|
|
9
|
-
— Ruff 0.0.
|
9
|
+
— Ruff 0.0.8 Documentation
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -110,7 +110,7 @@
|
|
110
110
|
</div>
|
111
111
|
|
112
112
|
<div id="footer">
|
113
|
-
Generated on Thu Oct 3
|
113
|
+
Generated on Thu Oct 3 03:25:53 2019 by
|
114
114
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
115
115
|
0.9.20 (ruby-2.6.4).
|
116
116
|
</div>
|
data/docs/Ruff/Throws/Eff.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Class: Ruff::Throws::Eff
|
8
8
|
|
9
|
-
— Ruff 0.0.
|
9
|
+
— Ruff 0.0.8 Documentation
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -353,7 +353,7 @@
|
|
353
353
|
</div>
|
354
354
|
|
355
355
|
<div id="footer">
|
356
|
-
Generated on Thu Oct 3
|
356
|
+
Generated on Thu Oct 3 03:25:53 2019 by
|
357
357
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
358
358
|
0.9.20 (ruby-2.6.4).
|
359
359
|
</div>
|
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
Class: Ruff::Throws::Resend
|
8
8
|
|
9
|
-
— Ruff 0.0.
|
9
|
+
— Ruff 0.0.8 Documentation
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -353,7 +353,7 @@
|
|
353
353
|
</div>
|
354
354
|
|
355
355
|
<div id="footer">
|
356
|
-
Generated on Thu Oct 3
|
356
|
+
Generated on Thu Oct 3 03:25:53 2019 by
|
357
357
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
358
358
|
0.9.20 (ruby-2.6.4).
|
359
359
|
</div>
|
data/docs/_index.html
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
<meta charset="utf-8">
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
6
|
<title>
|
7
|
-
Ruff 0.0.
|
7
|
+
Ruff 0.0.8 Documentation
|
8
8
|
|
9
9
|
</title>
|
10
10
|
|
@@ -52,7 +52,7 @@
|
|
52
52
|
<div class="clear"></div>
|
53
53
|
</div>
|
54
54
|
|
55
|
-
<div id="content"><h1 class="noborder title">Ruff 0.0.
|
55
|
+
<div id="content"><h1 class="noborder title">Ruff 0.0.8 Documentation</h1>
|
56
56
|
<div id="listing">
|
57
57
|
<h1 class="alphaindex">Alphabetic Index</h1>
|
58
58
|
|
@@ -76,6 +76,36 @@
|
|
76
76
|
<td valign='top' width="33%">
|
77
77
|
|
78
78
|
|
79
|
+
<ul id="alpha_C" class="alpha">
|
80
|
+
<li class="letter">C</li>
|
81
|
+
<ul>
|
82
|
+
|
83
|
+
<li>
|
84
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime.html" title="Ruff::Standard::CurrentTime (module)">CurrentTime</a></span>
|
85
|
+
|
86
|
+
<small>(Ruff::Standard)</small>
|
87
|
+
|
88
|
+
</li>
|
89
|
+
|
90
|
+
</ul>
|
91
|
+
</ul>
|
92
|
+
|
93
|
+
|
94
|
+
<ul id="alpha_D" class="alpha">
|
95
|
+
<li class="letter">D</li>
|
96
|
+
<ul>
|
97
|
+
|
98
|
+
<li>
|
99
|
+
<span class='object_link'><a href="Ruff/Standard/Defer.html" title="Ruff::Standard::Defer (module)">Defer</a></span>
|
100
|
+
|
101
|
+
<small>(Ruff::Standard)</small>
|
102
|
+
|
103
|
+
</li>
|
104
|
+
|
105
|
+
</ul>
|
106
|
+
</ul>
|
107
|
+
|
108
|
+
|
79
109
|
<ul id="alpha_E" class="alpha">
|
80
110
|
<li class="letter">E</li>
|
81
111
|
<ul>
|
@@ -113,6 +143,35 @@
|
|
113
143
|
</ul>
|
114
144
|
|
115
145
|
|
146
|
+
<ul id="alpha_I" class="alpha">
|
147
|
+
<li class="letter">I</li>
|
148
|
+
<ul>
|
149
|
+
|
150
|
+
<li>
|
151
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime/Instance.html" title="Ruff::Standard::CurrentTime::Instance (class)">Instance</a></span>
|
152
|
+
|
153
|
+
<small>(Ruff::Standard::CurrentTime)</small>
|
154
|
+
|
155
|
+
</li>
|
156
|
+
|
157
|
+
<li>
|
158
|
+
<span class='object_link'><a href="Ruff/Standard/Defer/Instance.html" title="Ruff::Standard::Defer::Instance (class)">Instance</a></span>
|
159
|
+
|
160
|
+
<small>(Ruff::Standard::Defer)</small>
|
161
|
+
|
162
|
+
</li>
|
163
|
+
|
164
|
+
<li>
|
165
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html" title="Ruff::Standard::State::Instance (class)">Instance</a></span>
|
166
|
+
|
167
|
+
<small>(Ruff::Standard::State)</small>
|
168
|
+
|
169
|
+
</li>
|
170
|
+
|
171
|
+
</ul>
|
172
|
+
</ul>
|
173
|
+
|
174
|
+
|
116
175
|
<ul id="alpha_R" class="alpha">
|
117
176
|
<li class="letter">R</li>
|
118
177
|
<ul>
|
@@ -133,6 +192,31 @@
|
|
133
192
|
</ul>
|
134
193
|
|
135
194
|
|
195
|
+
<ul id="alpha_S" class="alpha">
|
196
|
+
<li class="letter">S</li>
|
197
|
+
<ul>
|
198
|
+
|
199
|
+
<li>
|
200
|
+
<span class='object_link'><a href="Ruff/Standard.html" title="Ruff::Standard (module)">Standard</a></span>
|
201
|
+
|
202
|
+
<small>(Ruff)</small>
|
203
|
+
|
204
|
+
</li>
|
205
|
+
|
206
|
+
<li>
|
207
|
+
<span class='object_link'><a href="Ruff/Standard/State.html" title="Ruff::Standard::State (module)">State</a></span>
|
208
|
+
|
209
|
+
<small>(Ruff::Standard)</small>
|
210
|
+
|
211
|
+
</li>
|
212
|
+
|
213
|
+
</ul>
|
214
|
+
</ul>
|
215
|
+
|
216
|
+
|
217
|
+
</td><td valign='top' width="33%">
|
218
|
+
|
219
|
+
|
136
220
|
<ul id="alpha_T" class="alpha">
|
137
221
|
<li class="letter">T</li>
|
138
222
|
<ul>
|
@@ -156,7 +240,7 @@
|
|
156
240
|
</div>
|
157
241
|
|
158
242
|
<div id="footer">
|
159
|
-
Generated on Thu Oct 3
|
243
|
+
Generated on Thu Oct 3 03:25:52 2019 by
|
160
244
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
161
245
|
0.9.20 (ruby-2.6.4).
|
162
246
|
</div>
|
data/docs/class_list.html
CHANGED
@@ -43,7 +43,7 @@
|
|
43
43
|
|
44
44
|
<ul id="full_list" class="class">
|
45
45
|
<li id="object_" class="odd"><div class="item" style="padding-left:30px"><span class='object_link'><a href="top-level-namespace.html" title="Top Level Namespace (root)">Top Level Namespace</a></span></div></li>
|
46
|
-
<li id='object_Ruff' class='even'><div class='item' style='padding-left:30px'><a class='toggle'></a> <span class='object_link'><a href="Ruff.html" title="Ruff (module)">Ruff</a></span><small class='search_info'>Top Level Namespace</small></div><ul><li id='object_Ruff::Effect' class='collapsed odd'><div class='item' style='padding-left:45px'><span class='object_link'><a href="Ruff/Effect.html" title="Ruff::Effect (class)">Effect</a></span> < Object<small class='search_info'>Ruff</small></div></li><li id='object_Ruff::Handler' class='collapsed even'><div class='item' style='padding-left:45px'><span class='object_link'><a href="Ruff/Handler.html" title="Ruff::Handler (class)">Handler</a></span> < Object<small class='search_info'>Ruff</small></div></li><li id='object_Ruff::
|
46
|
+
<li id='object_Ruff' class='even'><div class='item' style='padding-left:30px'><a class='toggle'></a> <span class='object_link'><a href="Ruff.html" title="Ruff (module)">Ruff</a></span><small class='search_info'>Top Level Namespace</small></div><ul><li id='object_Ruff::Effect' class='collapsed odd'><div class='item' style='padding-left:45px'><span class='object_link'><a href="Ruff/Effect.html" title="Ruff::Effect (class)">Effect</a></span> < Object<small class='search_info'>Ruff</small></div></li><li id='object_Ruff::Handler' class='collapsed even'><div class='item' style='padding-left:45px'><span class='object_link'><a href="Ruff/Handler.html" title="Ruff::Handler (class)">Handler</a></span> < Object<small class='search_info'>Ruff</small></div></li><li id='object_Ruff::Standard' class='collapsed odd'><div class='item' style='padding-left:45px'><a class='toggle'></a> <span class='object_link'><a href="Ruff/Standard.html" title="Ruff::Standard (module)">Standard</a></span><small class='search_info'>Ruff</small></div><ul><li id='object_Ruff::Standard::CurrentTime' class='collapsed'><div class='item' style='padding-left:60px'><a class='toggle'></a> <span class='object_link'><a href="Ruff/Standard/CurrentTime.html" title="Ruff::Standard::CurrentTime (module)">CurrentTime</a></span><small class='search_info'>Ruff::Standard</small></div><ul><li id='object_Ruff::Standard::CurrentTime::Instance' class='collapsed'><div class='item' style='padding-left:75px'><span class='object_link'><a href="Ruff/Standard/CurrentTime/Instance.html" title="Ruff::Standard::CurrentTime::Instance (class)">Instance</a></span> < Object<small class='search_info'>Ruff::Standard::CurrentTime</small></div></li></ul></li><li id='object_Ruff::Standard::Defer' class='collapsed'><div class='item' style='padding-left:60px'><a class='toggle'></a> <span class='object_link'><a href="Ruff/Standard/Defer.html" title="Ruff::Standard::Defer (module)">Defer</a></span><small class='search_info'>Ruff::Standard</small></div><ul><li id='object_Ruff::Standard::Defer::Instance' class='collapsed'><div class='item' style='padding-left:75px'><span class='object_link'><a href="Ruff/Standard/Defer/Instance.html" title="Ruff::Standard::Defer::Instance (class)">Instance</a></span> < Object<small class='search_info'>Ruff::Standard::Defer</small></div></li></ul></li><li id='object_Ruff::Standard::State' class='collapsed'><div class='item' style='padding-left:60px'><a class='toggle'></a> <span class='object_link'><a href="Ruff/Standard/State.html" title="Ruff::Standard::State (module)">State</a></span><small class='search_info'>Ruff::Standard</small></div><ul><li id='object_Ruff::Standard::State::Instance' class='collapsed'><div class='item' style='padding-left:75px'><span class='object_link'><a href="Ruff/Standard/State/Instance.html" title="Ruff::Standard::State::Instance (class)">Instance</a></span> < Object<small class='search_info'>Ruff::Standard::State</small></div></li></ul></li></ul></li><li id='object_Ruff::Throws' class='collapsed even'><div class='item' style='padding-left:45px'><a class='toggle'></a> <span class='object_link'><a href="Ruff/Throws.html" title="Ruff::Throws (module)">Throws</a></span><small class='search_info'>Ruff</small></div><ul><li id='object_Ruff::Throws::Eff' class='collapsed'><div class='item' style='padding-left:60px'><span class='object_link'><a href="Ruff/Throws/Eff.html" title="Ruff::Throws::Eff (class)">Eff</a></span> < Object<small class='search_info'>Ruff::Throws</small></div></li><li id='object_Ruff::Throws::Resend' class='collapsed'><div class='item' style='padding-left:60px'><span class='object_link'><a href="Ruff/Throws/Resend.html" title="Ruff::Throws::Resend (class)">Resend</a></span> < Object<small class='search_info'>Ruff::Throws</small></div></li></ul></li></ul></li>
|
47
47
|
|
48
48
|
</ul>
|
49
49
|
</div>
|
data/docs/file.README.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
File: README
|
8
8
|
|
9
|
-
— Ruff 0.0.
|
9
|
+
— Ruff 0.0.8 Documentation
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -90,9 +90,71 @@
|
|
90
90
|
</span><span class='comment'># logger: 6
|
91
91
|
</span></code></pre>
|
92
92
|
|
93
|
-
<h1>
|
93
|
+
<h1>pre-defined effect and handlers</h1>
|
94
94
|
|
95
|
-
<p>
|
95
|
+
<p>They have <code>with</code> method to handle the effects, and <code>Instance</code> class to instanciate and handle the indivisual effect objects.</p>
|
96
|
+
|
97
|
+
<pre class="code ruby"><code class="ruby"><span class='id identifier rubyid_require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ruff</span><span class='tstring_end'>"</span></span>
|
98
|
+
<span class='id identifier rubyid_require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ruff/standard</span><span class='tstring_end'>"</span></span>
|
99
|
+
|
100
|
+
<span class='id identifier rubyid_include'>include</span> <span class='const'><span class='object_link'><a href="Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Ruff/Standard.html" title="Ruff::Standard (module)">Standard</a></span></span>
|
101
|
+
|
102
|
+
<span class='const'>Defer</span><span class='period'>.</span><span class='id identifier rubyid_with'>with</span> <span class='lbrace'>{</span>
|
103
|
+
<span class='id identifier rubyid_state1'>state1</span> <span class='op'>=</span> <span class='const'>State</span><span class='op'>::</span><span class='const'>Instance</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span>
|
104
|
+
<span class='id identifier rubyid_state2'>state2</span> <span class='op'>=</span> <span class='const'>State</span><span class='op'>::</span><span class='const'>Instance</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span>
|
105
|
+
|
106
|
+
<span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_with_init'>with_init</span><span class='lparen'>(</span><span class='int'>10</span><span class='rparen'>)</span> <span class='lbrace'>{</span>
|
107
|
+
<span class='const'>CurrentTime</span><span class='period'>.</span><span class='id identifier rubyid_with'>with</span> <span class='lbrace'>{</span>
|
108
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='const'>CurrentTime</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
109
|
+
<span class='rbrace'>}</span>
|
110
|
+
|
111
|
+
<span class='id identifier rubyid_state2'>state2</span><span class='period'>.</span><span class='id identifier rubyid_with_init'>with_init</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span>
|
112
|
+
<span class='int'>3</span><span class='period'>.</span><span class='id identifier rubyid_times'>times</span><span class='lbrace'>{</span>
|
113
|
+
<span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_modify'>modify</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_s'>s</span><span class='op'>|</span> <span class='id identifier rubyid_s'>s</span> <span class='op'>+</span> <span class='int'>1</span> <span class='rbrace'>}</span>
|
114
|
+
<span class='id identifier rubyid_state2'>state2</span><span class='period'>.</span><span class='id identifier rubyid_put'>put</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span><span class='embexpr_end'>}</span><span class='tstring_content'>!</span><span class='tstring_end'>"</span></span>
|
115
|
+
|
116
|
+
<span class='id identifier rubyid_s1'>s1</span> <span class='op'>=</span> <span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
117
|
+
<span class='id identifier rubyid_s2'>s2</span> <span class='op'>=</span> <span class='id identifier rubyid_state2'>state2</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
118
|
+
|
119
|
+
<span class='const'>Defer</span><span class='period'>.</span><span class='id identifier rubyid_register'>register</span> <span class='lbrace'>{</span>
|
120
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='id identifier rubyid_s1'>s1</span><span class='comma'>,</span> <span class='id identifier rubyid_s2'>s2</span>
|
121
|
+
<span class='rbrace'>}</span>
|
122
|
+
<span class='rbrace'>}</span>
|
123
|
+
<span class='rbrace'>}</span>
|
124
|
+
<span class='rbrace'>}</span>
|
125
|
+
<span class='rbrace'>}</span>
|
126
|
+
|
127
|
+
<span class='comment'># ==>
|
128
|
+
</span><span class='comment'># 2019-10-03 03:24:34 +0900
|
129
|
+
</span><span class='comment'># 13
|
130
|
+
</span><span class='comment'># 13!
|
131
|
+
</span><span class='comment'># 12
|
132
|
+
</span><span class='comment'># 12!
|
133
|
+
</span><span class='comment'># 11
|
134
|
+
</span><span class='comment'># 11!
|
135
|
+
</span></code></pre>
|
136
|
+
|
137
|
+
<h2><code>Ruff::Standard::State</code></h2>
|
138
|
+
|
139
|
+
<h3><code>with_init</code></h3>
|
140
|
+
|
141
|
+
<!-- This method handles state-like effects like `with` , but it requires initial state. -->
|
142
|
+
|
143
|
+
<!-- `with { task }` is short hand for `with_init(0) { task }` . -->
|
144
|
+
|
145
|
+
<h3><code>get</code></h3>
|
146
|
+
|
147
|
+
<h3><code>put</code></h3>
|
148
|
+
|
149
|
+
<h3><code>modify</code></h3>
|
150
|
+
|
151
|
+
<h2><code>Ruff::Standard::Defer</code></h2>
|
152
|
+
|
153
|
+
<h3><code>register</code></h3>
|
154
|
+
|
155
|
+
<h2><code>Ruff::Standard::CurrentTime</code></h2>
|
156
|
+
|
157
|
+
<h3><code>get</code></h3>
|
96
158
|
|
97
159
|
<h1>LICENSE</h1>
|
98
160
|
|
@@ -100,7 +162,7 @@
|
|
100
162
|
</div></div>
|
101
163
|
|
102
164
|
<div id="footer">
|
103
|
-
Generated on Thu Oct 3
|
165
|
+
Generated on Thu Oct 3 03:25:52 2019 by
|
104
166
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
105
167
|
0.9.20 (ruby-2.6.4).
|
106
168
|
</div>
|
data/docs/frames.html
CHANGED
data/docs/index.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<title>
|
7
7
|
File: README
|
8
8
|
|
9
|
-
— Ruff 0.0.
|
9
|
+
— Ruff 0.0.8 Documentation
|
10
10
|
|
11
11
|
</title>
|
12
12
|
|
@@ -90,9 +90,71 @@
|
|
90
90
|
</span><span class='comment'># logger: 6
|
91
91
|
</span></code></pre>
|
92
92
|
|
93
|
-
<h1>
|
93
|
+
<h1>pre-defined effect and handlers</h1>
|
94
94
|
|
95
|
-
<p>
|
95
|
+
<p>They have <code>with</code> method to handle the effects, and <code>Instance</code> class to instanciate and handle the indivisual effect objects.</p>
|
96
|
+
|
97
|
+
<pre class="code ruby"><code class="ruby"><span class='id identifier rubyid_require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ruff</span><span class='tstring_end'>"</span></span>
|
98
|
+
<span class='id identifier rubyid_require'>require</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ruff/standard</span><span class='tstring_end'>"</span></span>
|
99
|
+
|
100
|
+
<span class='id identifier rubyid_include'>include</span> <span class='const'><span class='object_link'><a href="Ruff.html" title="Ruff (module)">Ruff</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="Ruff/Standard.html" title="Ruff::Standard (module)">Standard</a></span></span>
|
101
|
+
|
102
|
+
<span class='const'>Defer</span><span class='period'>.</span><span class='id identifier rubyid_with'>with</span> <span class='lbrace'>{</span>
|
103
|
+
<span class='id identifier rubyid_state1'>state1</span> <span class='op'>=</span> <span class='const'>State</span><span class='op'>::</span><span class='const'>Instance</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span>
|
104
|
+
<span class='id identifier rubyid_state2'>state2</span> <span class='op'>=</span> <span class='const'>State</span><span class='op'>::</span><span class='const'>Instance</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span>
|
105
|
+
|
106
|
+
<span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_with_init'>with_init</span><span class='lparen'>(</span><span class='int'>10</span><span class='rparen'>)</span> <span class='lbrace'>{</span>
|
107
|
+
<span class='const'>CurrentTime</span><span class='period'>.</span><span class='id identifier rubyid_with'>with</span> <span class='lbrace'>{</span>
|
108
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='const'>CurrentTime</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
109
|
+
<span class='rbrace'>}</span>
|
110
|
+
|
111
|
+
<span class='id identifier rubyid_state2'>state2</span><span class='period'>.</span><span class='id identifier rubyid_with_init'>with_init</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span> <span class='lbrace'>{</span>
|
112
|
+
<span class='int'>3</span><span class='period'>.</span><span class='id identifier rubyid_times'>times</span><span class='lbrace'>{</span>
|
113
|
+
<span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_modify'>modify</span> <span class='lbrace'>{</span><span class='op'>|</span><span class='id identifier rubyid_s'>s</span><span class='op'>|</span> <span class='id identifier rubyid_s'>s</span> <span class='op'>+</span> <span class='int'>1</span> <span class='rbrace'>}</span>
|
114
|
+
<span class='id identifier rubyid_state2'>state2</span><span class='period'>.</span><span class='id identifier rubyid_put'>put</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span><span class='embexpr_end'>}</span><span class='tstring_content'>!</span><span class='tstring_end'>"</span></span>
|
115
|
+
|
116
|
+
<span class='id identifier rubyid_s1'>s1</span> <span class='op'>=</span> <span class='id identifier rubyid_state1'>state1</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
117
|
+
<span class='id identifier rubyid_s2'>s2</span> <span class='op'>=</span> <span class='id identifier rubyid_state2'>state2</span><span class='period'>.</span><span class='id identifier rubyid_get'>get</span>
|
118
|
+
|
119
|
+
<span class='const'>Defer</span><span class='period'>.</span><span class='id identifier rubyid_register'>register</span> <span class='lbrace'>{</span>
|
120
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='id identifier rubyid_s1'>s1</span><span class='comma'>,</span> <span class='id identifier rubyid_s2'>s2</span>
|
121
|
+
<span class='rbrace'>}</span>
|
122
|
+
<span class='rbrace'>}</span>
|
123
|
+
<span class='rbrace'>}</span>
|
124
|
+
<span class='rbrace'>}</span>
|
125
|
+
<span class='rbrace'>}</span>
|
126
|
+
|
127
|
+
<span class='comment'># ==>
|
128
|
+
</span><span class='comment'># 2019-10-03 03:24:34 +0900
|
129
|
+
</span><span class='comment'># 13
|
130
|
+
</span><span class='comment'># 13!
|
131
|
+
</span><span class='comment'># 12
|
132
|
+
</span><span class='comment'># 12!
|
133
|
+
</span><span class='comment'># 11
|
134
|
+
</span><span class='comment'># 11!
|
135
|
+
</span></code></pre>
|
136
|
+
|
137
|
+
<h2><code>Ruff::Standard::State</code></h2>
|
138
|
+
|
139
|
+
<h3><code>with_init</code></h3>
|
140
|
+
|
141
|
+
<!-- This method handles state-like effects like `with` , but it requires initial state. -->
|
142
|
+
|
143
|
+
<!-- `with { task }` is short hand for `with_init(0) { task }` . -->
|
144
|
+
|
145
|
+
<h3><code>get</code></h3>
|
146
|
+
|
147
|
+
<h3><code>put</code></h3>
|
148
|
+
|
149
|
+
<h3><code>modify</code></h3>
|
150
|
+
|
151
|
+
<h2><code>Ruff::Standard::Defer</code></h2>
|
152
|
+
|
153
|
+
<h3><code>register</code></h3>
|
154
|
+
|
155
|
+
<h2><code>Ruff::Standard::CurrentTime</code></h2>
|
156
|
+
|
157
|
+
<h3><code>get</code></h3>
|
96
158
|
|
97
159
|
<h1>LICENSE</h1>
|
98
160
|
|
@@ -100,7 +162,7 @@
|
|
100
162
|
</div></div>
|
101
163
|
|
102
164
|
<div id="footer">
|
103
|
-
Generated on Thu Oct 3
|
165
|
+
Generated on Thu Oct 3 03:25:52 2019 by
|
104
166
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
105
167
|
0.9.20 (ruby-2.6.4).
|
106
168
|
</div>
|
data/docs/method_list.html
CHANGED
@@ -60,6 +60,38 @@
|
|
60
60
|
</li>
|
61
61
|
|
62
62
|
|
63
|
+
<li class="odd ">
|
64
|
+
<div class="item">
|
65
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime/Instance.html#get-instance_method" title="Ruff::Standard::CurrentTime::Instance#get (method)">#get</a></span>
|
66
|
+
<small>Ruff::Standard::CurrentTime::Instance</small>
|
67
|
+
</div>
|
68
|
+
</li>
|
69
|
+
|
70
|
+
|
71
|
+
<li class="even ">
|
72
|
+
<div class="item">
|
73
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime.html#get-class_method" title="Ruff::Standard::CurrentTime.get (method)">get</a></span>
|
74
|
+
<small>Ruff::Standard::CurrentTime</small>
|
75
|
+
</div>
|
76
|
+
</li>
|
77
|
+
|
78
|
+
|
79
|
+
<li class="odd ">
|
80
|
+
<div class="item">
|
81
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html#get-instance_method" title="Ruff::Standard::State::Instance#get (method)">#get</a></span>
|
82
|
+
<small>Ruff::Standard::State::Instance</small>
|
83
|
+
</div>
|
84
|
+
</li>
|
85
|
+
|
86
|
+
|
87
|
+
<li class="even ">
|
88
|
+
<div class="item">
|
89
|
+
<span class='object_link'><a href="Ruff/Standard/State.html#get-class_method" title="Ruff::Standard::State.get (method)">get</a></span>
|
90
|
+
<small>Ruff::Standard::State</small>
|
91
|
+
</div>
|
92
|
+
</li>
|
93
|
+
|
94
|
+
|
63
95
|
<li class="odd ">
|
64
96
|
<div class="item">
|
65
97
|
<span class='object_link'><a href="Ruff.html#handler-class_method" title="Ruff.handler (method)">handler</a></span>
|
@@ -117,6 +149,30 @@
|
|
117
149
|
|
118
150
|
|
119
151
|
<li class="even ">
|
152
|
+
<div class="item">
|
153
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime/Instance.html#initialize-instance_method" title="Ruff::Standard::CurrentTime::Instance#initialize (method)">#initialize</a></span>
|
154
|
+
<small>Ruff::Standard::CurrentTime::Instance</small>
|
155
|
+
</div>
|
156
|
+
</li>
|
157
|
+
|
158
|
+
|
159
|
+
<li class="odd ">
|
160
|
+
<div class="item">
|
161
|
+
<span class='object_link'><a href="Ruff/Standard/Defer/Instance.html#initialize-instance_method" title="Ruff::Standard::Defer::Instance#initialize (method)">#initialize</a></span>
|
162
|
+
<small>Ruff::Standard::Defer::Instance</small>
|
163
|
+
</div>
|
164
|
+
</li>
|
165
|
+
|
166
|
+
|
167
|
+
<li class="even ">
|
168
|
+
<div class="item">
|
169
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html#initialize-instance_method" title="Ruff::Standard::State::Instance#initialize (method)">#initialize</a></span>
|
170
|
+
<small>Ruff::Standard::State::Instance</small>
|
171
|
+
</div>
|
172
|
+
</li>
|
173
|
+
|
174
|
+
|
175
|
+
<li class="odd ">
|
120
176
|
<div class="item">
|
121
177
|
<span class='object_link'><a href="Ruff.html#instance-class_method" title="Ruff.instance (method)">instance</a></span>
|
122
178
|
<small>Ruff</small>
|
@@ -124,7 +180,7 @@
|
|
124
180
|
</li>
|
125
181
|
|
126
182
|
|
127
|
-
<li class="
|
183
|
+
<li class="even ">
|
128
184
|
<div class="item">
|
129
185
|
<span class='object_link'><a href="Ruff/Throws/Resend.html#k-instance_method" title="Ruff::Throws::Resend#k (method)">#k</a></span>
|
130
186
|
<small>Ruff::Throws::Resend</small>
|
@@ -132,7 +188,23 @@
|
|
132
188
|
</li>
|
133
189
|
|
134
190
|
|
191
|
+
<li class="odd ">
|
192
|
+
<div class="item">
|
193
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html#modify-instance_method" title="Ruff::Standard::State::Instance#modify (method)">#modify</a></span>
|
194
|
+
<small>Ruff::Standard::State::Instance</small>
|
195
|
+
</div>
|
196
|
+
</li>
|
197
|
+
|
198
|
+
|
135
199
|
<li class="even ">
|
200
|
+
<div class="item">
|
201
|
+
<span class='object_link'><a href="Ruff/Standard/State.html#modify-class_method" title="Ruff::Standard::State.modify (method)">modify</a></span>
|
202
|
+
<small>Ruff::Standard::State</small>
|
203
|
+
</div>
|
204
|
+
</li>
|
205
|
+
|
206
|
+
|
207
|
+
<li class="odd ">
|
136
208
|
<div class="item">
|
137
209
|
<span class='object_link'><a href="Ruff/Handler.html#on-instance_method" title="Ruff::Handler#on (method)">#on</a></span>
|
138
210
|
<small>Ruff::Handler</small>
|
@@ -140,7 +212,7 @@
|
|
140
212
|
</li>
|
141
213
|
|
142
214
|
|
143
|
-
<li class="
|
215
|
+
<li class="even ">
|
144
216
|
<div class="item">
|
145
217
|
<span class='object_link'><a href="Ruff/Effect.html#perform-instance_method" title="Ruff::Effect#perform (method)">#perform</a></span>
|
146
218
|
<small>Ruff::Effect</small>
|
@@ -148,7 +220,39 @@
|
|
148
220
|
</li>
|
149
221
|
|
150
222
|
|
223
|
+
<li class="odd ">
|
224
|
+
<div class="item">
|
225
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html#put-instance_method" title="Ruff::Standard::State::Instance#put (method)">#put</a></span>
|
226
|
+
<small>Ruff::Standard::State::Instance</small>
|
227
|
+
</div>
|
228
|
+
</li>
|
229
|
+
|
230
|
+
|
231
|
+
<li class="even ">
|
232
|
+
<div class="item">
|
233
|
+
<span class='object_link'><a href="Ruff/Standard/State.html#put-class_method" title="Ruff::Standard::State.put (method)">put</a></span>
|
234
|
+
<small>Ruff::Standard::State</small>
|
235
|
+
</div>
|
236
|
+
</li>
|
237
|
+
|
238
|
+
|
239
|
+
<li class="odd ">
|
240
|
+
<div class="item">
|
241
|
+
<span class='object_link'><a href="Ruff/Standard/Defer/Instance.html#register-instance_method" title="Ruff::Standard::Defer::Instance#register (method)">#register</a></span>
|
242
|
+
<small>Ruff::Standard::Defer::Instance</small>
|
243
|
+
</div>
|
244
|
+
</li>
|
245
|
+
|
246
|
+
|
151
247
|
<li class="even ">
|
248
|
+
<div class="item">
|
249
|
+
<span class='object_link'><a href="Ruff/Standard/Defer.html#register-class_method" title="Ruff::Standard::Defer.register (method)">register</a></span>
|
250
|
+
<small>Ruff::Standard::Defer</small>
|
251
|
+
</div>
|
252
|
+
</li>
|
253
|
+
|
254
|
+
|
255
|
+
<li class="odd ">
|
152
256
|
<div class="item">
|
153
257
|
<span class='object_link'><a href="Ruff/Handler.html#run-instance_method" title="Ruff::Handler#run (method)">#run</a></span>
|
154
258
|
<small>Ruff::Handler</small>
|
@@ -156,7 +260,7 @@
|
|
156
260
|
</li>
|
157
261
|
|
158
262
|
|
159
|
-
<li class="
|
263
|
+
<li class="even ">
|
160
264
|
<div class="item">
|
161
265
|
<span class='object_link'><a href="Ruff/Handler.html#to-instance_method" title="Ruff::Handler#to (method)">#to</a></span>
|
162
266
|
<small>Ruff::Handler</small>
|
@@ -164,6 +268,70 @@
|
|
164
268
|
</li>
|
165
269
|
|
166
270
|
|
271
|
+
<li class="odd ">
|
272
|
+
<div class="item">
|
273
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime/Instance.html#with-instance_method" title="Ruff::Standard::CurrentTime::Instance#with (method)">#with</a></span>
|
274
|
+
<small>Ruff::Standard::CurrentTime::Instance</small>
|
275
|
+
</div>
|
276
|
+
</li>
|
277
|
+
|
278
|
+
|
279
|
+
<li class="even ">
|
280
|
+
<div class="item">
|
281
|
+
<span class='object_link'><a href="Ruff/Standard/CurrentTime.html#with-class_method" title="Ruff::Standard::CurrentTime.with (method)">with</a></span>
|
282
|
+
<small>Ruff::Standard::CurrentTime</small>
|
283
|
+
</div>
|
284
|
+
</li>
|
285
|
+
|
286
|
+
|
287
|
+
<li class="odd ">
|
288
|
+
<div class="item">
|
289
|
+
<span class='object_link'><a href="Ruff/Standard/Defer/Instance.html#with-instance_method" title="Ruff::Standard::Defer::Instance#with (method)">#with</a></span>
|
290
|
+
<small>Ruff::Standard::Defer::Instance</small>
|
291
|
+
</div>
|
292
|
+
</li>
|
293
|
+
|
294
|
+
|
295
|
+
<li class="even ">
|
296
|
+
<div class="item">
|
297
|
+
<span class='object_link'><a href="Ruff/Standard/Defer.html#with-class_method" title="Ruff::Standard::Defer.with (method)">with</a></span>
|
298
|
+
<small>Ruff::Standard::Defer</small>
|
299
|
+
</div>
|
300
|
+
</li>
|
301
|
+
|
302
|
+
|
303
|
+
<li class="odd ">
|
304
|
+
<div class="item">
|
305
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html#with-instance_method" title="Ruff::Standard::State::Instance#with (method)">#with</a></span>
|
306
|
+
<small>Ruff::Standard::State::Instance</small>
|
307
|
+
</div>
|
308
|
+
</li>
|
309
|
+
|
310
|
+
|
311
|
+
<li class="even ">
|
312
|
+
<div class="item">
|
313
|
+
<span class='object_link'><a href="Ruff/Standard/State.html#with-class_method" title="Ruff::Standard::State.with (method)">with</a></span>
|
314
|
+
<small>Ruff::Standard::State</small>
|
315
|
+
</div>
|
316
|
+
</li>
|
317
|
+
|
318
|
+
|
319
|
+
<li class="odd ">
|
320
|
+
<div class="item">
|
321
|
+
<span class='object_link'><a href="Ruff/Standard/State/Instance.html#with_init-instance_method" title="Ruff::Standard::State::Instance#with_init (method)">#with_init</a></span>
|
322
|
+
<small>Ruff::Standard::State::Instance</small>
|
323
|
+
</div>
|
324
|
+
</li>
|
325
|
+
|
326
|
+
|
327
|
+
<li class="even ">
|
328
|
+
<div class="item">
|
329
|
+
<span class='object_link'><a href="Ruff/Standard/State.html#with_init-class_method" title="Ruff::Standard::State.with_init (method)">with_init</a></span>
|
330
|
+
<small>Ruff::Standard::State</small>
|
331
|
+
</div>
|
332
|
+
</li>
|
333
|
+
|
334
|
+
|
167
335
|
|
168
336
|
</ul>
|
169
337
|
</div>
|