simple-service 0.1.3 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (69) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +2 -2
  3. data/.rubocop.yml +10 -2
  4. data/Gemfile +3 -1
  5. data/Makefile +7 -11
  6. data/README.md +67 -2
  7. data/TODO.txt +3 -0
  8. data/VERSION +1 -1
  9. data/doc/Simple/Service/Action/Comment/Extractor.html +347 -0
  10. data/doc/Simple/Service/Action/Comment.html +451 -0
  11. data/doc/Simple/Service/Action/MethodReflection.html +285 -0
  12. data/doc/Simple/Service/Action/Parameter.html +816 -0
  13. data/doc/Simple/Service/Action.html +923 -0
  14. data/doc/Simple/Service/ArgumentError.html +128 -0
  15. data/doc/Simple/Service/ClassMethods.html +187 -0
  16. data/doc/Simple/Service/Context.html +379 -0
  17. data/doc/Simple/Service/ContextMissingError.html +124 -0
  18. data/doc/Simple/Service/ContextReadOnlyError.html +206 -0
  19. data/doc/Simple/Service/ExtraArguments.html +428 -0
  20. data/doc/Simple/Service/GemHelper.html +190 -0
  21. data/doc/Simple/Service/MissingArguments.html +426 -0
  22. data/doc/Simple/Service/NoSuchAction.html +433 -0
  23. data/doc/Simple/Service.html +865 -0
  24. data/doc/Simple.html +117 -0
  25. data/doc/_index.html +274 -0
  26. data/doc/class_list.html +51 -0
  27. data/doc/css/common.css +1 -0
  28. data/doc/css/full_list.css +58 -0
  29. data/doc/css/style.css +496 -0
  30. data/doc/file.README.html +146 -0
  31. data/doc/file.TODO.html +70 -0
  32. data/doc/file_list.html +61 -0
  33. data/doc/frames.html +17 -0
  34. data/doc/index.html +146 -0
  35. data/doc/js/app.js +303 -0
  36. data/doc/js/full_list.js +216 -0
  37. data/doc/js/jquery.js +4 -0
  38. data/doc/method_list.html +483 -0
  39. data/doc/top-level-namespace.html +110 -0
  40. data/lib/simple/service/action/comment.rb +2 -2
  41. data/lib/simple/service/action/method_reflection.rb +1 -1
  42. data/lib/simple/service/action/parameter.rb +1 -1
  43. data/lib/simple/service/action.rb +34 -46
  44. data/lib/simple/service/errors.rb +4 -3
  45. data/lib/simple/service/version.rb +2 -2
  46. data/lib/simple/service.rb +109 -34
  47. data/lib/simple/workflow/context.rb +105 -0
  48. data/lib/simple/workflow/current_context.rb +33 -0
  49. data/lib/simple/workflow/reloader.rb +84 -0
  50. data/lib/simple/workflow/rspec_helper.rb +15 -0
  51. data/lib/simple/workflow.rb +96 -0
  52. data/lib/simple-workflow.rb +3 -0
  53. data/scripts/test +2 -0
  54. data/simple-service.gemspec +1 -0
  55. data/spec/simple/service/action_invoke3_spec.rb +258 -0
  56. data/spec/simple/service/action_invoke_spec.rb +49 -87
  57. data/spec/simple/service/service_spec.rb +40 -32
  58. data/spec/simple/workflow/context_spec.rb +90 -0
  59. data/spec/simple/workflow/current_context_spec.rb +41 -0
  60. data/spec/simple/workflow/reloader_spec/example1.rb +10 -0
  61. data/spec/simple/workflow/reloader_spec/example2.rb +7 -0
  62. data/spec/simple/workflow/reloader_spec.rb +48 -0
  63. data/spec/spec_helper.rb +2 -1
  64. data/spec/support/spec_services.rb +8 -2
  65. metadata +74 -9
  66. data/lib/simple/service/action/indie_hash.rb +0 -37
  67. data/lib/simple/service/context.rb +0 -94
  68. data/spec/simple/service/action_invoke2_spec.rb +0 -166
  69. data/spec/simple/service/context_spec.rb +0 -69
@@ -0,0 +1,433 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>
7
+ Exception: Simple::Service::NoSuchAction
8
+
9
+ &mdash; Documentation by YARD 0.9.20
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../../css/style.css" type="text/css" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../../css/common.css" type="text/css" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ pathId = "Simple::Service::NoSuchAction";
19
+ relpath = '../../';
20
+ </script>
21
+
22
+
23
+ <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
24
+
25
+ <script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
26
+
27
+
28
+ </head>
29
+ <body>
30
+ <div class="nav_wrap">
31
+ <iframe id="nav" src="../../class_list.html?1"></iframe>
32
+ <div id="resizer"></div>
33
+ </div>
34
+
35
+ <div id="main" tabindex="-1">
36
+ <div id="header">
37
+ <div id="menu">
38
+
39
+ <a href="../../_index.html">Index (N)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../../Simple.html" title="Simple (module)">Simple</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../Service.html" title="Simple::Service (module)">Service</a></span></span>
41
+ &raquo;
42
+ <span class="title">NoSuchAction</span>
43
+
44
+ </div>
45
+
46
+ <div id="search">
47
+
48
+ <a class="full_list_link" id="class_list_link"
49
+ href="../../class_list.html">
50
+
51
+ <svg width="24" height="24">
52
+ <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
+ <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
+ <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
+ </svg>
56
+ </a>
57
+
58
+ </div>
59
+ <div class="clear"></div>
60
+ </div>
61
+
62
+ <div id="content"><h1>Exception: Simple::Service::NoSuchAction
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName">ArgumentError</span>
73
+
74
+ <ul class="fullTree">
75
+ <li>Object</li>
76
+
77
+ <li class="next">ArgumentError</li>
78
+
79
+ <li class="next">Simple::Service::NoSuchAction</li>
80
+
81
+ </ul>
82
+ <a href="#" class="inheritanceTree">show all</a>
83
+
84
+ </dd>
85
+ </dl>
86
+
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+
97
+ <dl>
98
+ <dt>Defined in:</dt>
99
+ <dd>lib/simple/service/errors.rb</dd>
100
+ </dl>
101
+
102
+ </div>
103
+
104
+ <h2>Overview</h2><div class="docstring">
105
+ <div class="discussion">
106
+
107
+ <p>Will be raised by ::Simple::Service.action.</p>
108
+
109
+
110
+ </div>
111
+ </div>
112
+ <div class="tags">
113
+
114
+
115
+ </div>
116
+
117
+
118
+
119
+ <h2>Instance Attribute Summary <small><a href="#" class="summary_toggle">collapse</a></small></h2>
120
+ <ul class="summary">
121
+
122
+ <li class="public ">
123
+ <span class="summary_signature">
124
+
125
+ <a href="#name-instance_method" title="#name (instance method)">#<strong>name</strong> &#x21d2; Object </a>
126
+
127
+
128
+
129
+ </span>
130
+
131
+
132
+
133
+
134
+ <span class="note title readonly">readonly</span>
135
+
136
+
137
+
138
+
139
+
140
+
141
+
142
+
143
+
144
+ <span class="summary_desc"><div class='inline'>
145
+ <p>Returns the value of attribute name.</p>
146
+ </div></span>
147
+
148
+ </li>
149
+
150
+
151
+ <li class="public ">
152
+ <span class="summary_signature">
153
+
154
+ <a href="#service-instance_method" title="#service (instance method)">#<strong>service</strong> &#x21d2; Object </a>
155
+
156
+
157
+
158
+ </span>
159
+
160
+
161
+
162
+
163
+ <span class="note title readonly">readonly</span>
164
+
165
+
166
+
167
+
168
+
169
+
170
+
171
+
172
+
173
+ <span class="summary_desc"><div class='inline'>
174
+ <p>Returns the value of attribute service.</p>
175
+ </div></span>
176
+
177
+ </li>
178
+
179
+
180
+ </ul>
181
+
182
+
183
+
184
+
185
+
186
+ <h2>
187
+ Instance Method Summary
188
+ <small><a href="#" class="summary_toggle">collapse</a></small>
189
+ </h2>
190
+
191
+ <ul class="summary">
192
+
193
+ <li class="public ">
194
+ <span class="summary_signature">
195
+
196
+ <a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong>(service, name) &#x21d2; NoSuchAction </a>
197
+
198
+
199
+
200
+ </span>
201
+
202
+
203
+ <span class="note title constructor">constructor</span>
204
+
205
+
206
+
207
+
208
+
209
+
210
+
211
+
212
+ <span class="summary_desc"><div class='inline'>
213
+ <p>A new instance of NoSuchAction.</p>
214
+ </div></span>
215
+
216
+ </li>
217
+
218
+
219
+ <li class="public ">
220
+ <span class="summary_signature">
221
+
222
+ <a href="#to_s-instance_method" title="#to_s (instance method)">#<strong>to_s</strong> &#x21d2; Object </a>
223
+
224
+
225
+
226
+ </span>
227
+
228
+
229
+
230
+
231
+
232
+
233
+
234
+
235
+
236
+ <span class="summary_desc"><div class='inline'></div></span>
237
+
238
+ </li>
239
+
240
+
241
+ </ul>
242
+
243
+
244
+
245
+ <div id="constructor_details" class="method_details_list">
246
+ <h2>Constructor Details</h2>
247
+
248
+ <div class="method_details first">
249
+ <h3 class="signature first" id="initialize-instance_method">
250
+
251
+ #<strong>initialize</strong>(service, name) &#x21d2; <tt><span class='object_link'><a href="" title="Simple::Service::NoSuchAction (class)">NoSuchAction</a></span></tt>
252
+
253
+
254
+
255
+
256
+
257
+ </h3><div class="docstring">
258
+ <div class="discussion">
259
+
260
+ <p>Returns a new instance of NoSuchAction</p>
261
+
262
+
263
+ </div>
264
+ </div>
265
+ <div class="tags">
266
+
267
+
268
+ </div><table class="source_code">
269
+ <tr>
270
+ <td>
271
+ <pre class="lines">
272
+
273
+
274
+ 5
275
+ 6
276
+ 7</pre>
277
+ </td>
278
+ <td>
279
+ <pre class="code"><span class="info file"># File 'lib/simple/service/errors.rb', line 5</span>
280
+
281
+ <span class='kw'>def</span> <span class='id identifier rubyid_initialize'>initialize</span><span class='lparen'>(</span><span class='id identifier rubyid_service'>service</span><span class='comma'>,</span> <span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
282
+ <span class='ivar'>@service</span><span class='comma'>,</span> <span class='ivar'>@name</span> <span class='op'>=</span> <span class='id identifier rubyid_service'>service</span><span class='comma'>,</span> <span class='id identifier rubyid_name'>name</span>
283
+ <span class='kw'>end</span></pre>
284
+ </td>
285
+ </tr>
286
+ </table>
287
+ </div>
288
+
289
+ </div>
290
+
291
+ <div id="instance_attr_details" class="attr_details">
292
+ <h2>Instance Attribute Details</h2>
293
+
294
+
295
+ <span id=""></span>
296
+ <div class="method_details first">
297
+ <h3 class="signature first" id="name-instance_method">
298
+
299
+ #<strong>name</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
300
+
301
+
302
+
303
+
304
+
305
+ </h3><div class="docstring">
306
+ <div class="discussion">
307
+
308
+ <p>Returns the value of attribute name</p>
309
+
310
+
311
+ </div>
312
+ </div>
313
+ <div class="tags">
314
+
315
+
316
+ </div><table class="source_code">
317
+ <tr>
318
+ <td>
319
+ <pre class="lines">
320
+
321
+
322
+ 4
323
+ 5
324
+ 6</pre>
325
+ </td>
326
+ <td>
327
+ <pre class="code"><span class="info file"># File 'lib/simple/service/errors.rb', line 4</span>
328
+
329
+ <span class='kw'>def</span> <span class='id identifier rubyid_name'>name</span>
330
+ <span class='ivar'>@name</span>
331
+ <span class='kw'>end</span></pre>
332
+ </td>
333
+ </tr>
334
+ </table>
335
+ </div>
336
+
337
+
338
+ <span id=""></span>
339
+ <div class="method_details ">
340
+ <h3 class="signature " id="service-instance_method">
341
+
342
+ #<strong>service</strong> &#x21d2; <tt>Object</tt> <span class="extras">(readonly)</span>
343
+
344
+
345
+
346
+
347
+
348
+ </h3><div class="docstring">
349
+ <div class="discussion">
350
+
351
+ <p>Returns the value of attribute service</p>
352
+
353
+
354
+ </div>
355
+ </div>
356
+ <div class="tags">
357
+
358
+
359
+ </div><table class="source_code">
360
+ <tr>
361
+ <td>
362
+ <pre class="lines">
363
+
364
+
365
+ 4
366
+ 5
367
+ 6</pre>
368
+ </td>
369
+ <td>
370
+ <pre class="code"><span class="info file"># File 'lib/simple/service/errors.rb', line 4</span>
371
+
372
+ <span class='kw'>def</span> <span class='id identifier rubyid_service'>service</span>
373
+ <span class='ivar'>@service</span>
374
+ <span class='kw'>end</span></pre>
375
+ </td>
376
+ </tr>
377
+ </table>
378
+ </div>
379
+
380
+ </div>
381
+
382
+
383
+ <div id="instance_method_details" class="method_details_list">
384
+ <h2>Instance Method Details</h2>
385
+
386
+
387
+ <div class="method_details first">
388
+ <h3 class="signature first" id="to_s-instance_method">
389
+
390
+ #<strong>to_s</strong> &#x21d2; <tt>Object</tt>
391
+
392
+
393
+
394
+
395
+
396
+ </h3><table class="source_code">
397
+ <tr>
398
+ <td>
399
+ <pre class="lines">
400
+
401
+
402
+ 9
403
+ 10
404
+ 11
405
+ 12
406
+ 13</pre>
407
+ </td>
408
+ <td>
409
+ <pre class="code"><span class="info file"># File 'lib/simple/service/errors.rb', line 9</span>
410
+
411
+ <span class='kw'>def</span> <span class='id identifier rubyid_to_s'>to_s</span>
412
+ <span class='id identifier rubyid_action_names'>action_names</span> <span class='op'>=</span> <span class='op'>::</span><span class='const'><span class='object_link'><a href="../../Simple.html" title="Simple (module)">Simple</a></span></span><span class='op'>::</span><span class='const'><span class='object_link'><a href="../Service.html" title="Simple::Service (module)">Service</a></span></span><span class='period'>.</span><span class='id identifier rubyid_actions'><span class='object_link'><a href="../Service.html#actions-class_method" title="Simple::Service.actions (method)">actions</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_service'>service</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_keys'>keys</span><span class='period'>.</span><span class='id identifier rubyid_sort'>sort</span>
413
+ <span class='id identifier rubyid_informal'>informal</span> <span class='op'>=</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>service </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_service'>service</span><span class='embexpr_end'>}</span><span class='tstring_content'> has these actions: </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_action_names'>action_names</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&amp;</span><span class='symbol'>:inspect</span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_join'>join</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>, </span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span><span class='embexpr_end'>}</span><span class='tstring_end'>&quot;</span></span>
414
+ <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>No such action </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_name'>name</span><span class='period'>.</span><span class='id identifier rubyid_inspect'>inspect</span><span class='embexpr_end'>}</span><span class='tstring_content'>; </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_informal'>informal</span><span class='embexpr_end'>}</span><span class='tstring_end'>&quot;</span></span>
415
+ <span class='kw'>end</span></pre>
416
+ </td>
417
+ </tr>
418
+ </table>
419
+ </div>
420
+
421
+ </div>
422
+
423
+ </div>
424
+
425
+ <div id="footer">
426
+ Generated on Wed Dec 4 22:57:13 2019 by
427
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
428
+ 0.9.20 (ruby-2.5.1).
429
+ </div>
430
+
431
+ </div>
432
+ </body>
433
+ </html>