examLPP 0.1.1

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 (83) hide show
  1. checksums.yaml +7 -0
  2. data/.coveralls.yml +1 -0
  3. data/.gitignore +5 -0
  4. data/.rspec +2 -0
  5. data/.travis.yml +4 -0
  6. data/Gemfile +5 -0
  7. data/Guardfile +70 -0
  8. data/LICENSE.txt +22 -0
  9. data/README.md +19 -0
  10. data/Rakefile +6 -0
  11. data/coverage/.last_run.json +5 -0
  12. data/coverage/.resultset.json +714 -0
  13. data/doc/Exam.html +112 -0
  14. data/doc/Examen.html +319 -0
  15. data/doc/Gemfile.html +101 -0
  16. data/doc/Gemfile_lock.html +186 -0
  17. data/doc/Guardfile.html +169 -0
  18. data/doc/LICENSE_txt.html +116 -0
  19. data/doc/Lista.html +472 -0
  20. data/doc/Nodo.html +264 -0
  21. data/doc/Object.html +119 -0
  22. data/doc/Pregunta.html +346 -0
  23. data/doc/PreguntaS.html +338 -0
  24. data/doc/PreguntaVF.html +210 -0
  25. data/doc/README_md.html +120 -0
  26. data/doc/Rakefile.html +99 -0
  27. data/doc/created.rid +18 -0
  28. data/doc/exam_gemspec.html +127 -0
  29. data/doc/fonts.css +167 -0
  30. data/doc/fonts/Lato-Light.ttf +0 -0
  31. data/doc/fonts/Lato-LightItalic.ttf +0 -0
  32. data/doc/fonts/Lato-Regular.ttf +0 -0
  33. data/doc/fonts/Lato-RegularItalic.ttf +0 -0
  34. data/doc/fonts/SourceCodePro-Bold.ttf +0 -0
  35. data/doc/fonts/SourceCodePro-Regular.ttf +0 -0
  36. data/doc/images/add.png +0 -0
  37. data/doc/images/arrow_up.png +0 -0
  38. data/doc/images/brick.png +0 -0
  39. data/doc/images/brick_link.png +0 -0
  40. data/doc/images/bug.png +0 -0
  41. data/doc/images/bullet_black.png +0 -0
  42. data/doc/images/bullet_toggle_minus.png +0 -0
  43. data/doc/images/bullet_toggle_plus.png +0 -0
  44. data/doc/images/date.png +0 -0
  45. data/doc/images/delete.png +0 -0
  46. data/doc/images/find.png +0 -0
  47. data/doc/images/loadingAnimation.gif +0 -0
  48. data/doc/images/macFFBgHack.png +0 -0
  49. data/doc/images/package.png +0 -0
  50. data/doc/images/page_green.png +0 -0
  51. data/doc/images/page_white_text.png +0 -0
  52. data/doc/images/page_white_width.png +0 -0
  53. data/doc/images/plugin.png +0 -0
  54. data/doc/images/ruby.png +0 -0
  55. data/doc/images/tag_blue.png +0 -0
  56. data/doc/images/tag_green.png +0 -0
  57. data/doc/images/transparent.png +0 -0
  58. data/doc/images/wrench.png +0 -0
  59. data/doc/images/wrench_orange.png +0 -0
  60. data/doc/images/zoom.png +0 -0
  61. data/doc/index.html +118 -0
  62. data/doc/js/darkfish.js +140 -0
  63. data/doc/js/jquery.js +18 -0
  64. data/doc/js/navigation.js +142 -0
  65. data/doc/js/search.js +109 -0
  66. data/doc/js/search_index.js +1 -0
  67. data/doc/js/searcher.js +228 -0
  68. data/doc/rdoc.css +580 -0
  69. data/doc/table_of_contents.html +222 -0
  70. data/exam.gemspec +32 -0
  71. data/lib/exam.rb +12 -0
  72. data/lib/exam/examen.rb +69 -0
  73. data/lib/exam/lista.rb +109 -0
  74. data/lib/exam/nodo.rb +14 -0
  75. data/lib/exam/pregunta.rb +38 -0
  76. data/lib/exam/preguntaMadre.rb +47 -0
  77. data/lib/exam/preguntaVF.rb +19 -0
  78. data/lib/exam/quiz.rb +44 -0
  79. data/lib/exam/version.rb +3 -0
  80. data/pkg/exam-0.0.1.gem +0 -0
  81. data/spec/exam_spec.rb +353 -0
  82. data/spec/spec_helper.rb +22 -0
  83. metadata +226 -0
@@ -0,0 +1,338 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta charset="UTF-8">
6
+
7
+ <title>class PreguntaS - RDoc Documentation</title>
8
+
9
+ <link href="./fonts.css" rel="stylesheet">
10
+ <link href="./rdoc.css" rel="stylesheet">
11
+
12
+ <script type="text/javascript">
13
+ var rdoc_rel_prefix = "./";
14
+ </script>
15
+
16
+ <script src="./js/jquery.js"></script>
17
+ <script src="./js/navigation.js"></script>
18
+ <script src="./js/search_index.js"></script>
19
+ <script src="./js/search.js"></script>
20
+ <script src="./js/searcher.js"></script>
21
+ <script src="./js/darkfish.js"></script>
22
+
23
+
24
+ <body id="top" role="document" class="class">
25
+ <nav role="navigation">
26
+ <div id="project-navigation">
27
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
28
+ <h2>
29
+ <a href="./index.html" rel="home">Home</a>
30
+ </h2>
31
+
32
+ <div id="table-of-contents-navigation">
33
+ <a href="./table_of_contents.html#pages">Pages</a>
34
+ <a href="./table_of_contents.html#classes">Classes</a>
35
+ <a href="./table_of_contents.html#methods">Methods</a>
36
+ </div>
37
+ </div>
38
+
39
+ <div id="search-section" role="search" class="project-section initially-hidden">
40
+ <form action="#" method="get" accept-charset="utf-8">
41
+ <div id="search-field-wrapper">
42
+ <input id="search-field" role="combobox" aria-label="Search"
43
+ aria-autocomplete="list" aria-controls="search-results"
44
+ type="text" name="search" placeholder="Search" spellcheck="false"
45
+ title="Type to search, Up and Down to navigate, Enter to load">
46
+ </div>
47
+
48
+ <ul id="search-results" aria-label="Search Results"
49
+ aria-busy="false" aria-expanded="false"
50
+ aria-atomic="false" class="initially-hidden"></ul>
51
+ </form>
52
+ </div>
53
+
54
+ </div>
55
+
56
+
57
+
58
+ <div id="class-metadata">
59
+
60
+ <div id="parent-class-section" class="nav-section">
61
+ <h3>Parent</h3>
62
+
63
+
64
+ <p class="link"><a href="Pregunta.html">Pregunta</a>
65
+
66
+ </div>
67
+
68
+
69
+
70
+ <!-- Method Quickref -->
71
+ <div id="method-list-section" class="nav-section">
72
+ <h3>Methods</h3>
73
+
74
+ <ul class="link-list" role="directory">
75
+
76
+ <li class="calls-super" ><a href="#method-c-new">::new</a>
77
+
78
+ <li ><a href="#method-i-addr">#addr</a>
79
+
80
+ <li ><a href="#method-i-preg">#preg</a>
81
+
82
+ <li ><a href="#method-i-resp">#resp</a>
83
+
84
+ <li ><a href="#method-i-to_s">#to_s</a>
85
+
86
+ </ul>
87
+ </div>
88
+
89
+ </div>
90
+ </nav>
91
+
92
+ <main role="main" aria-labelledby="class-PreguntaS">
93
+ <h1 id="class-PreguntaS" class="class">
94
+ class PreguntaS
95
+ </h1>
96
+
97
+ <section class="description">
98
+
99
+ <p><a href="Pregunta.html">Pregunta</a> de respuesta múltiple</p>
100
+
101
+ </section>
102
+
103
+
104
+
105
+
106
+ <section id="5Buntitled-5D" class="documentation-section">
107
+
108
+
109
+
110
+
111
+
112
+
113
+
114
+ <section class="attribute-method-details" class="method-section">
115
+ <header>
116
+ <h3>Attributes</h3>
117
+ </header>
118
+
119
+
120
+ <div id="attribute-i-re" class="method-detail">
121
+ <div class="method-heading attribute-method-heading">
122
+ <span class="method-name">re</span><span
123
+ class="attribute-access-type">[R]</span>
124
+ </div>
125
+
126
+ <div class="method-description">
127
+
128
+
129
+
130
+ </div>
131
+ </div>
132
+
133
+ </section>
134
+
135
+
136
+
137
+ <section id="public-class-5Buntitled-5D-method-details" class="method-section">
138
+ <header>
139
+ <h3>Public Class Methods</h3>
140
+ </header>
141
+
142
+
143
+ <div id="method-c-new" class="method-detail ">
144
+
145
+ <div class="method-heading">
146
+ <span class="method-name">new</span><span
147
+ class="method-args">(pregunta, dificultad)</span>
148
+
149
+ <span class="method-click-advice">click to toggle source</span>
150
+
151
+ </div>
152
+
153
+
154
+ <div class="method-description">
155
+
156
+ <p>Constructor</p>
157
+
158
+
159
+ <div class="method-calls-super">
160
+ Calls superclass method
161
+ <a href="Pregunta.html#method-c-new">Pregunta.new</a>
162
+ </div>
163
+
164
+
165
+
166
+ <div class="method-source-code" id="new-source">
167
+ <pre><span class="ruby-comment"># File lib/exam/pregunta.rb, line 7</span>
168
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span> (<span class="ruby-identifier">pregunta</span>, <span class="ruby-identifier">dificultad</span>)
169
+ <span class="ruby-keyword">super</span>
170
+ <span class="ruby-ivar">@re</span> = <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">0</span>)
171
+ <span class="ruby-comment">#inicializamos un array con 0 elementos para las respuestas</span>
172
+ <span class="ruby-keyword">end</span></pre>
173
+ </div>
174
+
175
+ </div>
176
+
177
+
178
+
179
+
180
+ </div>
181
+
182
+
183
+ </section>
184
+
185
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
186
+ <header>
187
+ <h3>Public Instance Methods</h3>
188
+ </header>
189
+
190
+
191
+ <div id="method-i-addr" class="method-detail ">
192
+
193
+ <div class="method-heading">
194
+ <span class="method-name">addr</span><span
195
+ class="method-args">(respuesta)</span>
196
+
197
+ <span class="method-click-advice">click to toggle source</span>
198
+
199
+ </div>
200
+
201
+
202
+ <div class="method-description">
203
+
204
+ <p>Agrega una respuesta adicional a la pregunta</p>
205
+
206
+
207
+
208
+
209
+ <div class="method-source-code" id="addr-source">
210
+ <pre><span class="ruby-comment"># File lib/exam/pregunta.rb, line 19</span>
211
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">addr</span> (<span class="ruby-identifier">respuesta</span>)
212
+ <span class="ruby-ivar">@re</span>.<span class="ruby-identifier">push</span>(<span class="ruby-identifier">respuesta</span>)
213
+ <span class="ruby-keyword">end</span></pre>
214
+ </div>
215
+
216
+ </div>
217
+
218
+
219
+
220
+
221
+ </div>
222
+
223
+
224
+ <div id="method-i-preg" class="method-detail ">
225
+
226
+ <div class="method-heading">
227
+ <span class="method-name">preg</span><span
228
+ class="method-args">()</span>
229
+
230
+ <span class="method-click-advice">click to toggle source</span>
231
+
232
+ </div>
233
+
234
+
235
+ <div class="method-description">
236
+
237
+ <p>Método que devuelve la pregunta como String</p>
238
+
239
+
240
+
241
+
242
+ <div class="method-source-code" id="preg-source">
243
+ <pre><span class="ruby-comment"># File lib/exam/pregunta.rb, line 14</span>
244
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">preg</span>
245
+ <span class="ruby-node">&quot;Pregunta: #{@pr}&quot;</span>
246
+ <span class="ruby-keyword">end</span></pre>
247
+ </div>
248
+
249
+ </div>
250
+
251
+
252
+
253
+
254
+ </div>
255
+
256
+
257
+ <div id="method-i-resp" class="method-detail ">
258
+
259
+ <div class="method-heading">
260
+ <span class="method-name">resp</span><span
261
+ class="method-args">()</span>
262
+
263
+ <span class="method-click-advice">click to toggle source</span>
264
+
265
+ </div>
266
+
267
+
268
+ <div class="method-description">
269
+
270
+ <p>Devuelve las respuestas como String</p>
271
+
272
+
273
+
274
+
275
+ <div class="method-source-code" id="resp-source">
276
+ <pre><span class="ruby-comment"># File lib/exam/pregunta.rb, line 24</span>
277
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">resp</span>
278
+ <span class="ruby-identifier">respuestas</span> = <span class="ruby-string">&quot;&quot;</span>
279
+ <span class="ruby-keyword">for</span> <span class="ruby-identifier">i</span> <span class="ruby-keyword">in</span> (<span class="ruby-value">0</span><span class="ruby-operator">..</span>(<span class="ruby-ivar">@re</span>.<span class="ruby-identifier">length</span> <span class="ruby-operator">-</span> <span class="ruby-value">1</span>))
280
+ <span class="ruby-identifier">respuestas</span> <span class="ruby-operator">+=</span> <span class="ruby-node">&quot;#{i+1}) #{@re[i]}\n&quot;</span>
281
+ <span class="ruby-keyword">end</span>
282
+ <span class="ruby-identifier">respuestas</span>
283
+ <span class="ruby-keyword">end</span></pre>
284
+ </div>
285
+
286
+ </div>
287
+
288
+
289
+
290
+
291
+ </div>
292
+
293
+
294
+ <div id="method-i-to_s" class="method-detail ">
295
+
296
+ <div class="method-heading">
297
+ <span class="method-name">to_s</span><span
298
+ class="method-args">()</span>
299
+
300
+ <span class="method-click-advice">click to toggle source</span>
301
+
302
+ </div>
303
+
304
+
305
+ <div class="method-description">
306
+
307
+ <p>Muestra la pregunta y sus posibles respuestas como una String</p>
308
+
309
+
310
+
311
+
312
+ <div class="method-source-code" id="to_s-source">
313
+ <pre><span class="ruby-comment"># File lib/exam/pregunta.rb, line 33</span>
314
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">to_s</span>
315
+ <span class="ruby-identifier">preg</span> <span class="ruby-operator">+</span> <span class="ruby-string">&quot;\n\n&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">resp</span>
316
+ <span class="ruby-keyword">end</span></pre>
317
+ </div>
318
+
319
+ </div>
320
+
321
+
322
+
323
+
324
+ </div>
325
+
326
+
327
+ </section>
328
+
329
+ </section>
330
+ </main>
331
+
332
+
333
+ <footer id="validator-badges" role="contentinfo">
334
+ <p><a href="http://validator.w3.org/check/referer">Validate</a>
335
+ <p>Generated by <a href="http://rdoc.rubyforge.org">RDoc</a> 4.1.0.
336
+ <p>Based on <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
337
+ </footer>
338
+
@@ -0,0 +1,210 @@
1
+ <!DOCTYPE html>
2
+
3
+ <html>
4
+ <head>
5
+ <meta charset="UTF-8">
6
+
7
+ <title>class PreguntaVF - RDoc Documentation</title>
8
+
9
+ <link href="./fonts.css" rel="stylesheet">
10
+ <link href="./rdoc.css" rel="stylesheet">
11
+
12
+ <script type="text/javascript">
13
+ var rdoc_rel_prefix = "./";
14
+ </script>
15
+
16
+ <script src="./js/jquery.js"></script>
17
+ <script src="./js/navigation.js"></script>
18
+ <script src="./js/search_index.js"></script>
19
+ <script src="./js/search.js"></script>
20
+ <script src="./js/searcher.js"></script>
21
+ <script src="./js/darkfish.js"></script>
22
+
23
+
24
+ <body id="top" role="document" class="class">
25
+ <nav role="navigation">
26
+ <div id="project-navigation">
27
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
28
+ <h2>
29
+ <a href="./index.html" rel="home">Home</a>
30
+ </h2>
31
+
32
+ <div id="table-of-contents-navigation">
33
+ <a href="./table_of_contents.html#pages">Pages</a>
34
+ <a href="./table_of_contents.html#classes">Classes</a>
35
+ <a href="./table_of_contents.html#methods">Methods</a>
36
+ </div>
37
+ </div>
38
+
39
+ <div id="search-section" role="search" class="project-section initially-hidden">
40
+ <form action="#" method="get" accept-charset="utf-8">
41
+ <div id="search-field-wrapper">
42
+ <input id="search-field" role="combobox" aria-label="Search"
43
+ aria-autocomplete="list" aria-controls="search-results"
44
+ type="text" name="search" placeholder="Search" spellcheck="false"
45
+ title="Type to search, Up and Down to navigate, Enter to load">
46
+ </div>
47
+
48
+ <ul id="search-results" aria-label="Search Results"
49
+ aria-busy="false" aria-expanded="false"
50
+ aria-atomic="false" class="initially-hidden"></ul>
51
+ </form>
52
+ </div>
53
+
54
+ </div>
55
+
56
+
57
+
58
+ <div id="class-metadata">
59
+
60
+ <div id="parent-class-section" class="nav-section">
61
+ <h3>Parent</h3>
62
+
63
+
64
+ <p class="link"><a href="Pregunta.html">Pregunta</a>
65
+
66
+ </div>
67
+
68
+
69
+
70
+ <!-- Method Quickref -->
71
+ <div id="method-list-section" class="nav-section">
72
+ <h3>Methods</h3>
73
+
74
+ <ul class="link-list" role="directory">
75
+
76
+ <li class="calls-super" ><a href="#method-c-new">::new</a>
77
+
78
+ <li ><a href="#method-i-to_s">#to_s</a>
79
+
80
+ </ul>
81
+ </div>
82
+
83
+ </div>
84
+ </nav>
85
+
86
+ <main role="main" aria-labelledby="class-PreguntaVF">
87
+ <h1 id="class-PreguntaVF" class="class">
88
+ class PreguntaVF
89
+ </h1>
90
+
91
+ <section class="description">
92
+
93
+ <p><a href="Pregunta.html">Pregunta</a> de verdadero o falso</p>
94
+
95
+ </section>
96
+
97
+
98
+
99
+
100
+ <section id="5Buntitled-5D" class="documentation-section">
101
+
102
+
103
+
104
+
105
+
106
+
107
+
108
+
109
+
110
+ <section id="public-class-5Buntitled-5D-method-details" class="method-section">
111
+ <header>
112
+ <h3>Public Class Methods</h3>
113
+ </header>
114
+
115
+
116
+ <div id="method-c-new" class="method-detail ">
117
+
118
+ <div class="method-heading">
119
+ <span class="method-name">new</span><span
120
+ class="method-args">(pregunta, dificultad, correcta = "v")</span>
121
+
122
+ <span class="method-click-advice">click to toggle source</span>
123
+
124
+ </div>
125
+
126
+
127
+ <div class="method-description">
128
+
129
+ <p>Método de inicialización</p>
130
+
131
+
132
+ <div class="method-calls-super">
133
+ Calls superclass method
134
+ <a href="Pregunta.html#method-c-new">Pregunta.new</a>
135
+ </div>
136
+
137
+
138
+
139
+ <div class="method-source-code" id="new-source">
140
+ <pre><span class="ruby-comment"># File lib/exam/preguntaVF.rb, line 5</span>
141
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">pregunta</span>, <span class="ruby-identifier">dificultad</span>, <span class="ruby-identifier">correcta</span> = <span class="ruby-string">&quot;v&quot;</span>)
142
+ <span class="ruby-keyword">super</span>(<span class="ruby-identifier">pregunta</span>, <span class="ruby-identifier">dificultad</span>)
143
+ <span class="ruby-ivar">@correcta</span> = <span class="ruby-identifier">correcta</span>
144
+ <span class="ruby-keyword">end</span></pre>
145
+ </div>
146
+
147
+ </div>
148
+
149
+
150
+
151
+
152
+ </div>
153
+
154
+
155
+ </section>
156
+
157
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
158
+ <header>
159
+ <h3>Public Instance Methods</h3>
160
+ </header>
161
+
162
+
163
+ <div id="method-i-to_s" class="method-detail ">
164
+
165
+ <div class="method-heading">
166
+ <span class="method-name">to_s</span><span
167
+ class="method-args">()</span>
168
+
169
+ <span class="method-click-advice">click to toggle source</span>
170
+
171
+ </div>
172
+
173
+
174
+ <div class="method-description">
175
+
176
+ <p>Método para mostrar la pregunta con sus respuestas en formato String</p>
177
+
178
+
179
+
180
+
181
+ <div class="method-source-code" id="to_s-source">
182
+ <pre><span class="ruby-comment"># File lib/exam/preguntaVF.rb, line 12</span>
183
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">to_s</span>
184
+ <span class="ruby-identifier">string</span> = <span class="ruby-string">&#39;&#39;</span>
185
+ <span class="ruby-identifier">string</span> <span class="ruby-operator">+=</span> <span class="ruby-ivar">@pr</span>
186
+ <span class="ruby-identifier">string</span> <span class="ruby-operator">+=</span> <span class="ruby-string">&quot;\nVerdadero&quot;</span>
187
+ <span class="ruby-identifier">string</span> <span class="ruby-operator">+=</span> <span class="ruby-string">&quot;\nFalso&quot;</span>
188
+ <span class="ruby-keyword">end</span></pre>
189
+ </div>
190
+
191
+ </div>
192
+
193
+
194
+
195
+
196
+ </div>
197
+
198
+
199
+ </section>
200
+
201
+ </section>
202
+ </main>
203
+
204
+
205
+ <footer id="validator-badges" role="contentinfo">
206
+ <p><a href="http://validator.w3.org/check/referer">Validate</a>
207
+ <p>Generated by <a href="http://rdoc.rubyforge.org">RDoc</a> 4.1.0.
208
+ <p>Based on <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
209
+ </footer>
210
+