print_primes_table 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +12 -0
  3. data/.travis.yml +3 -0
  4. data/.yardoc/checksums +10 -0
  5. data/.yardoc/object_types +0 -0
  6. data/.yardoc/objects/root.dat +0 -0
  7. data/.yardoc/proxy_types +0 -0
  8. data/Gemfile +14 -0
  9. data/LICENSE.txt +22 -0
  10. data/README.md +78 -0
  11. data/Rakefile +2 -0
  12. data/bin/print_primes_table +10 -0
  13. data/doc/PrintPrimesTable.html +146 -0
  14. data/doc/PrintPrimesTable/Client.html +368 -0
  15. data/doc/PrintPrimesTable/Options.html +142 -0
  16. data/doc/PrintPrimesTable/Options/DefaultOption.html +247 -0
  17. data/doc/PrintPrimesTable/Options/HelpOption.html +311 -0
  18. data/doc/PrintPrimesTable/Options/OnlyPrimesOption.html +289 -0
  19. data/doc/PrintPrimesTable/Primes.html +496 -0
  20. data/doc/PrintPrimesTable/Validators.html +142 -0
  21. data/doc/PrintPrimesTable/Validators/DefaultValidator.html +284 -0
  22. data/doc/PrintPrimesTable/Validators/ErrorMessage.html +405 -0
  23. data/doc/PrintPrimesTable/Validators/HelpValidator.html +285 -0
  24. data/doc/_index.html +228 -0
  25. data/doc/class_list.html +58 -0
  26. data/doc/css/common.css +1 -0
  27. data/doc/css/full_list.css +57 -0
  28. data/doc/css/style.css +339 -0
  29. data/doc/file.README.html +122 -0
  30. data/doc/file_list.html +60 -0
  31. data/doc/frames.html +26 -0
  32. data/doc/index.html +122 -0
  33. data/doc/js/app.js +219 -0
  34. data/doc/js/full_list.js +181 -0
  35. data/doc/js/jquery.js +4 -0
  36. data/doc/method_list.html +135 -0
  37. data/doc/top-level-namespace.html +131 -0
  38. data/features/command_print_primes_table.feature +57 -0
  39. data/features/help_option.feature +24 -0
  40. data/features/support/env.rb +2 -0
  41. data/features/validate_arguments.feature +14 -0
  42. data/lib/print_primes_table.rb +4 -0
  43. data/lib/print_primes_table/client.rb +40 -0
  44. data/lib/print_primes_table/options/default_option.rb +28 -0
  45. data/lib/print_primes_table/options/help_option.rb +47 -0
  46. data/lib/print_primes_table/options/only_primes_option.rb +29 -0
  47. data/lib/print_primes_table/primes.rb +52 -0
  48. data/lib/print_primes_table/validators/default_validator.rb +39 -0
  49. data/lib/print_primes_table/validators/error_message.rb +31 -0
  50. data/lib/print_primes_table/validators/help_validator.rb +28 -0
  51. data/lib/print_primes_table/version.rb +10 -0
  52. data/print_primes_table.gemspec +29 -0
  53. metadata +132 -0
@@ -0,0 +1,285 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>
7
+ Class: PrintPrimesTable::Validators::HelpValidator
8
+
9
+ &mdash; Documentation by YARD 0.8.7.6
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../../css/style.css" type="text/css" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../../css/common.css" type="text/css" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ hasFrames = window.top.frames.main ? true : false;
19
+ relpath = '../../';
20
+ framesUrl = "../../frames.html#!PrintPrimesTable/Validators/HelpValidator.html";
21
+ </script>
22
+
23
+
24
+ <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
25
+
26
+ <script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
27
+
28
+
29
+ </head>
30
+ <body>
31
+ <div id="header">
32
+ <div id="menu">
33
+
34
+ <a href="../../_index.html">Index (H)</a> &raquo;
35
+ <span class='title'><span class='object_link'><a href="../../PrintPrimesTable.html" title="PrintPrimesTable (module)">PrintPrimesTable</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../Validators.html" title="PrintPrimesTable::Validators (module)">Validators</a></span></span>
36
+ &raquo;
37
+ <span class="title">HelpValidator</span>
38
+
39
+
40
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
41
+ </div>
42
+
43
+ <div id="search">
44
+
45
+ <a class="full_list_link" id="class_list_link"
46
+ href="../../class_list.html">
47
+ Class List
48
+ </a>
49
+
50
+ <a class="full_list_link" id="method_list_link"
51
+ href="../../method_list.html">
52
+ Method List
53
+ </a>
54
+
55
+ <a class="full_list_link" id="file_list_link"
56
+ href="../../file_list.html">
57
+ File List
58
+ </a>
59
+
60
+ </div>
61
+ <div class="clear"></div>
62
+ </div>
63
+
64
+ <iframe id="search_frame"></iframe>
65
+
66
+ <div id="content"><h1>Class: PrintPrimesTable::Validators::HelpValidator
67
+
68
+
69
+
70
+ </h1>
71
+
72
+ <dl class="box">
73
+
74
+ <dt class="r1">Inherits:</dt>
75
+ <dd class="r1">
76
+ <span class="inheritName">Object</span>
77
+
78
+ <ul class="fullTree">
79
+ <li>Object</li>
80
+
81
+ <li class="next">PrintPrimesTable::Validators::HelpValidator</li>
82
+
83
+ </ul>
84
+ <a href="#" class="inheritanceTree">show all</a>
85
+
86
+ </dd>
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+ <dt class="r2 last">Defined in:</dt>
97
+ <dd class="r2 last">lib/print_primes_table/validators/help_validator.rb</dd>
98
+
99
+ </dl>
100
+ <div class="clear"></div>
101
+
102
+ <h2>Overview</h2><div class="docstring">
103
+ <div class="discussion">
104
+
105
+ <p>to validate the –help option</p>
106
+
107
+
108
+ </div>
109
+ </div>
110
+ <div class="tags">
111
+
112
+ <p class="tag_title">Author:</p>
113
+ <ul class="author">
114
+
115
+ <li>
116
+
117
+
118
+
119
+
120
+
121
+ <div class='inline'>
122
+ <p>Diego Hernán Piccinini Lagos</p>
123
+ </div>
124
+
125
+ </li>
126
+
127
+ </ul>
128
+
129
+ </div>
130
+
131
+
132
+
133
+
134
+
135
+
136
+
137
+ <h2>
138
+ Class Method Summary
139
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
140
+ </h2>
141
+
142
+ <ul class="summary">
143
+
144
+ <li class="public ">
145
+ <span class="summary_signature">
146
+
147
+ <a href="#validate-class_method" title="validate (class method)">+ (Symbol | String) <strong>validate</strong>(args) </a>
148
+
149
+
150
+
151
+ </span>
152
+
153
+
154
+
155
+
156
+
157
+
158
+
159
+
160
+
161
+ <span class="summary_desc"><div class='inline'>
162
+ <p>validate the arguments of –help option.</p>
163
+ </div></span>
164
+
165
+ </li>
166
+
167
+
168
+ </ul>
169
+
170
+
171
+
172
+
173
+ <div id="class_method_details" class="method_details_list">
174
+ <h2>Class Method Details</h2>
175
+
176
+
177
+ <div class="method_details first">
178
+ <h3 class="signature first" id="validate-class_method">
179
+
180
+ + (<tt>Symbol | String</tt>) <strong>validate</strong>(args)
181
+
182
+
183
+
184
+
185
+
186
+ </h3><div class="docstring">
187
+ <div class="discussion">
188
+
189
+ <p>validate the arguments of –help option</p>
190
+
191
+
192
+ </div>
193
+ </div>
194
+ <div class="tags">
195
+ <p class="tag_title">Parameters:</p>
196
+ <ul class="param">
197
+
198
+ <li>
199
+
200
+ <span class='name'>args</span>
201
+
202
+
203
+ <span class='type'>(<tt>Array</tt>)</span>
204
+
205
+
206
+
207
+ &mdash;
208
+ <div class='inline'>
209
+ <p>the help option hasn&#39;t arguments</p>
210
+ </div>
211
+
212
+ </li>
213
+
214
+ </ul>
215
+
216
+ <p class="tag_title">Returns:</p>
217
+ <ul class="return">
218
+
219
+ <li>
220
+
221
+
222
+ <span class='type'>(<tt>Symbol | String</tt>)</span>
223
+
224
+
225
+
226
+ &mdash;
227
+ <div class='inline'>
228
+ <p>:valid or an Error Message</p>
229
+ </div>
230
+
231
+ </li>
232
+
233
+ </ul>
234
+
235
+ </div><table class="source_code">
236
+ <tr>
237
+ <td>
238
+ <pre class="lines">
239
+
240
+
241
+ 13
242
+ 14
243
+ 15
244
+ 16
245
+ 17
246
+ 18
247
+ 19
248
+ 20
249
+ 21
250
+ 22
251
+ 23
252
+ 24</pre>
253
+ </td>
254
+ <td>
255
+ <pre class="code"><span class="info file"># File 'lib/print_primes_table/validators/help_validator.rb', line 13</span>
256
+
257
+ <span class='kw'>def</span> <span class='id identifier rubyid_validate'>validate</span><span class='lparen'>(</span><span class='id identifier rubyid_args'>args</span><span class='rparen'>)</span>
258
+ <span class='kw'>begin</span>
259
+ <span class='id identifier rubyid_raise'>raise</span> <span class='const'>ArgumentError</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span>
260
+ <span class='const'>ErrorMessage</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='symbol'>:command_wrong_arguments</span><span class='comma'>,</span>
261
+ <span class='lbrace'>{</span><span class='symbol'>:max</span> <span class='op'>=&gt;</span> <span class='int'>1</span><span class='comma'>,</span> <span class='symbol'>:argument_num</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_count'>count</span> <span class='rbrace'>}</span>
262
+ <span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_show_content'>show_content</span><span class='rparen'>)</span> <span class='kw'>if</span> <span class='id identifier rubyid_args'>args</span><span class='period'>.</span><span class='id identifier rubyid_count'>count</span> <span class='op'>&gt;</span> <span class='int'>0</span>
263
+
264
+ <span class='symbol'>:valid</span>
265
+ <span class='kw'>rescue</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_err'>err</span>
266
+ <span class='id identifier rubyid_err'>err</span><span class='period'>.</span><span class='id identifier rubyid_message'>message</span>
267
+ <span class='kw'>end</span>
268
+ <span class='kw'>end</span></pre>
269
+ </td>
270
+ </tr>
271
+ </table>
272
+ </div>
273
+
274
+ </div>
275
+
276
+ </div>
277
+
278
+ <div id="footer">
279
+ Generated on Thu Apr 9 11:19:34 2015 by
280
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
281
+ 0.8.7.6 (ruby-2.0.0).
282
+ </div>
283
+
284
+ </body>
285
+ </html>
data/doc/_index.html ADDED
@@ -0,0 +1,228 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>
7
+ Documentation by YARD 0.8.7.6
8
+
9
+ </title>
10
+
11
+ <link rel="stylesheet" href="css/style.css" type="text/css" charset="utf-8" />
12
+
13
+ <link rel="stylesheet" href="css/common.css" type="text/css" charset="utf-8" />
14
+
15
+ <script type="text/javascript" charset="utf-8">
16
+ hasFrames = window.top.frames.main ? true : false;
17
+ relpath = '';
18
+ framesUrl = "frames.html#!_index.html";
19
+ </script>
20
+
21
+
22
+ <script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
23
+
24
+ <script type="text/javascript" charset="utf-8" src="js/app.js"></script>
25
+
26
+
27
+ </head>
28
+ <body>
29
+ <div id="header">
30
+ <div id="menu">
31
+
32
+
33
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
34
+ </div>
35
+
36
+ <div id="search">
37
+
38
+ <a class="full_list_link" id="class_list_link"
39
+ href="class_list.html">
40
+ Class List
41
+ </a>
42
+
43
+ <a class="full_list_link" id="method_list_link"
44
+ href="method_list.html">
45
+ Method List
46
+ </a>
47
+
48
+ <a class="full_list_link" id="file_list_link"
49
+ href="file_list.html">
50
+ File List
51
+ </a>
52
+
53
+ </div>
54
+ <div class="clear"></div>
55
+ </div>
56
+
57
+ <iframe id="search_frame"></iframe>
58
+
59
+ <div id="content"><h1 class="noborder title">Documentation by YARD 0.8.7.6</h1>
60
+ <div id="listing">
61
+ <h1 class="alphaindex">Alphabetic Index</h1>
62
+
63
+ <h2>File Listing</h2>
64
+ <ul id="files" class="index_inline_list">
65
+
66
+
67
+ <li class="r1"><a href="index.html" title="README">README</a></li>
68
+
69
+
70
+ </ul>
71
+
72
+ <div class="clear"></div>
73
+ <h2>Namespace Listing A-Z</h2>
74
+
75
+
76
+
77
+
78
+ <table>
79
+ <tr>
80
+ <td valign='top' width="33%">
81
+
82
+
83
+ <ul id="alpha_C" class="alpha">
84
+ <li class="letter">C</li>
85
+ <ul>
86
+
87
+ <li>
88
+ <span class='object_link'><a href="PrintPrimesTable/Client.html" title="PrintPrimesTable::Client (class)">Client</a></span>
89
+
90
+ <small>(PrintPrimesTable)</small>
91
+
92
+ </li>
93
+
94
+ </ul>
95
+ </ul>
96
+
97
+
98
+ <ul id="alpha_D" class="alpha">
99
+ <li class="letter">D</li>
100
+ <ul>
101
+
102
+ <li>
103
+ <span class='object_link'><a href="PrintPrimesTable/Options/DefaultOption.html" title="PrintPrimesTable::Options::DefaultOption (class)">DefaultOption</a></span>
104
+
105
+ <small>(PrintPrimesTable::Options)</small>
106
+
107
+ </li>
108
+
109
+ <li>
110
+ <span class='object_link'><a href="PrintPrimesTable/Validators/DefaultValidator.html" title="PrintPrimesTable::Validators::DefaultValidator (class)">DefaultValidator</a></span>
111
+
112
+ <small>(PrintPrimesTable::Validators)</small>
113
+
114
+ </li>
115
+
116
+ </ul>
117
+ </ul>
118
+
119
+
120
+ <ul id="alpha_E" class="alpha">
121
+ <li class="letter">E</li>
122
+ <ul>
123
+
124
+ <li>
125
+ <span class='object_link'><a href="PrintPrimesTable/Validators/ErrorMessage.html" title="PrintPrimesTable::Validators::ErrorMessage (class)">ErrorMessage</a></span>
126
+
127
+ <small>(PrintPrimesTable::Validators)</small>
128
+
129
+ </li>
130
+
131
+ </ul>
132
+ </ul>
133
+
134
+
135
+ <ul id="alpha_H" class="alpha">
136
+ <li class="letter">H</li>
137
+ <ul>
138
+
139
+ <li>
140
+ <span class='object_link'><a href="PrintPrimesTable/Options/HelpOption.html" title="PrintPrimesTable::Options::HelpOption (class)">HelpOption</a></span>
141
+
142
+ <small>(PrintPrimesTable::Options)</small>
143
+
144
+ </li>
145
+
146
+ <li>
147
+ <span class='object_link'><a href="PrintPrimesTable/Validators/HelpValidator.html" title="PrintPrimesTable::Validators::HelpValidator (class)">HelpValidator</a></span>
148
+
149
+ <small>(PrintPrimesTable::Validators)</small>
150
+
151
+ </li>
152
+
153
+ </ul>
154
+ </ul>
155
+
156
+
157
+ <ul id="alpha_O" class="alpha">
158
+ <li class="letter">O</li>
159
+ <ul>
160
+
161
+ <li>
162
+ <span class='object_link'><a href="PrintPrimesTable/Options/OnlyPrimesOption.html" title="PrintPrimesTable::Options::OnlyPrimesOption (class)">OnlyPrimesOption</a></span>
163
+
164
+ <small>(PrintPrimesTable::Options)</small>
165
+
166
+ </li>
167
+
168
+ <li>
169
+ <span class='object_link'><a href="PrintPrimesTable/Options.html" title="PrintPrimesTable::Options (module)">Options</a></span>
170
+
171
+ <small>(PrintPrimesTable)</small>
172
+
173
+ </li>
174
+
175
+ </ul>
176
+ </ul>
177
+
178
+
179
+ <ul id="alpha_P" class="alpha">
180
+ <li class="letter">P</li>
181
+ <ul>
182
+
183
+ <li>
184
+ <span class='object_link'><a href="PrintPrimesTable/Primes.html" title="PrintPrimesTable::Primes (class)">Primes</a></span>
185
+
186
+ <small>(PrintPrimesTable)</small>
187
+
188
+ </li>
189
+
190
+ <li>
191
+ <span class='object_link'><a href="PrintPrimesTable.html" title="PrintPrimesTable (module)">PrintPrimesTable</a></span>
192
+
193
+ </li>
194
+
195
+ </ul>
196
+ </ul>
197
+
198
+
199
+ <ul id="alpha_V" class="alpha">
200
+ <li class="letter">V</li>
201
+ <ul>
202
+
203
+ <li>
204
+ <span class='object_link'><a href="PrintPrimesTable/Validators.html" title="PrintPrimesTable::Validators (module)">Validators</a></span>
205
+
206
+ <small>(PrintPrimesTable)</small>
207
+
208
+ </li>
209
+
210
+ </ul>
211
+ </ul>
212
+
213
+ </td>
214
+ </tr>
215
+ </table>
216
+
217
+ </div>
218
+
219
+ </div>
220
+
221
+ <div id="footer">
222
+ Generated on Thu Apr 9 11:19:34 2015 by
223
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
224
+ 0.8.7.6 (ruby-2.0.0).
225
+ </div>
226
+
227
+ </body>
228
+ </html>