wee 0.4.0 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (146) hide show
  1. data/ChangeLog +75 -0
  2. data/README +17 -9
  3. data/Rakefile +2 -2
  4. data/TODO +20 -0
  5. data/benchmark/Makefile +14 -9
  6. data/benchmark/counter.rb +11 -30
  7. data/benchmark/report_req.rb +12 -0
  8. data/doc/rdoc/classes/Array.html +12 -12
  9. data/doc/rdoc/classes/Cache/StorageCache.html +38 -38
  10. data/doc/rdoc/classes/Cache/Strategy/CapacityBounded.html +30 -30
  11. data/doc/rdoc/classes/Cache/Strategy/LFU.html +24 -24
  12. data/doc/rdoc/classes/Cache/Strategy/LRU.html +24 -24
  13. data/doc/rdoc/classes/Cache/Strategy/Unbounded.html +24 -24
  14. data/doc/rdoc/classes/Enumerable.html +6 -6
  15. data/doc/rdoc/classes/Object.html +12 -12
  16. data/doc/rdoc/classes/OgApplication.html +126 -0
  17. data/doc/rdoc/classes/OgScaffolder.html +401 -0
  18. data/doc/rdoc/classes/OgSession.html +172 -0
  19. data/doc/rdoc/classes/String.html +12 -12
  20. data/doc/rdoc/classes/Struct.html +12 -12
  21. data/doc/rdoc/classes/Wee.html +5 -62
  22. data/doc/rdoc/classes/Wee/AnswerDecoration.html +9 -9
  23. data/doc/rdoc/classes/Wee/Application.html +107 -39
  24. data/doc/rdoc/classes/Wee/Brush.html +22 -18
  25. data/doc/rdoc/classes/Wee/Brush/ActionCallbackMixin.html +17 -11
  26. data/doc/rdoc/classes/Wee/Brush/ActionURLCallbackMixin.html +18 -10
  27. data/doc/rdoc/classes/Wee/Brush/AnchorTag.html +30 -64
  28. data/doc/rdoc/classes/Wee/Brush/FileUploadTag.html +8 -10
  29. data/doc/rdoc/classes/Wee/Brush/FormTag.html +27 -79
  30. data/doc/rdoc/classes/Wee/Brush/GenericEncodedTextBrush.html +12 -12
  31. data/doc/rdoc/classes/Wee/Brush/GenericSingleTagBrush.html +146 -0
  32. data/doc/rdoc/classes/Wee/Brush/GenericTagBrush.html +179 -65
  33. data/doc/rdoc/classes/Wee/Brush/GenericTextBrush.html +12 -12
  34. data/doc/rdoc/classes/Wee/Brush/ImageButtonTag.html +16 -18
  35. data/doc/rdoc/classes/Wee/Brush/ImageTag.html +203 -0
  36. data/doc/rdoc/classes/Wee/Brush/InputCallbackMixin.html +17 -11
  37. data/doc/rdoc/classes/Wee/Brush/InputTag.html +15 -15
  38. data/doc/rdoc/classes/Wee/Brush/JavascriptTag.html +147 -0
  39. data/doc/rdoc/classes/Wee/Brush/Page.html +17 -17
  40. data/doc/rdoc/classes/Wee/Brush/SelectListTag.html +25 -50
  41. data/doc/rdoc/classes/Wee/Brush/SelectOptionTag.html +7 -38
  42. data/doc/rdoc/classes/Wee/Brush/SubmitButtonTag.html +7 -7
  43. data/doc/rdoc/classes/Wee/Brush/TableDataTag.html +15 -16
  44. data/doc/rdoc/classes/Wee/Brush/TableHeaderTag.html +7 -7
  45. data/doc/rdoc/classes/Wee/Brush/TableRowTag.html +65 -50
  46. data/doc/rdoc/classes/Wee/Brush/TableTag.html +7 -7
  47. data/doc/rdoc/classes/Wee/Brush/TextAreaTag.html +14 -64
  48. data/doc/rdoc/classes/Wee/Brush/TextInputTag.html +7 -7
  49. data/doc/rdoc/classes/Wee/Brush/ToCallback.html +146 -0
  50. data/doc/rdoc/classes/Wee/CallbackRegistry.html +40 -40
  51. data/doc/rdoc/classes/Wee/CallbackStream.html +18 -18
  52. data/doc/rdoc/classes/Wee/Canvas.html +24 -24
  53. data/doc/rdoc/classes/Wee/Component.html +232 -149
  54. data/doc/rdoc/classes/Wee/Component/OnAnswer.html +153 -0
  55. data/doc/rdoc/classes/Wee/Decoration.html +42 -42
  56. data/doc/rdoc/classes/Wee/Delegate.html +27 -27
  57. data/doc/rdoc/classes/Wee/ErrorResponse.html +12 -12
  58. data/doc/rdoc/classes/Wee/FormDecoration.html +148 -0
  59. data/doc/rdoc/classes/Wee/GenericResponse.html +6 -6
  60. data/doc/rdoc/classes/Wee/HtmlCanvas.html +296 -215
  61. data/doc/rdoc/classes/Wee/HtmlWriter.html +83 -81
  62. data/doc/rdoc/classes/Wee/LiteralMethodCallback.html +21 -16
  63. data/doc/rdoc/classes/Wee/MessageBox.html +180 -0
  64. data/doc/rdoc/classes/Wee/PageDecoration.html +30 -30
  65. data/doc/rdoc/classes/Wee/Presenter.html +237 -69
  66. data/doc/rdoc/classes/Wee/RedirectResponse.html +6 -6
  67. data/doc/rdoc/classes/Wee/RefreshResponse.html +6 -6
  68. data/doc/rdoc/classes/Wee/Request.html +18 -18
  69. data/doc/rdoc/classes/Wee/RequestHandler.html +43 -39
  70. data/doc/rdoc/classes/Wee/Response.html +24 -24
  71. data/doc/rdoc/classes/Wee/Session.html +746 -72
  72. data/doc/rdoc/classes/Wee/SimpleIdGenerator.html +18 -18
  73. data/doc/rdoc/classes/Wee/Snapshot.html +19 -19
  74. data/doc/rdoc/classes/Wee/Utils.html +138 -2
  75. data/doc/rdoc/classes/Wee/Utils/LRUCache.html +7 -7
  76. data/doc/rdoc/classes/Wee/ValueHolder.html +18 -18
  77. data/doc/rdoc/classes/Wee/WEBrickAdaptor.html +43 -68
  78. data/doc/rdoc/classes/Wee/WrapperDecoration.html +150 -0
  79. data/doc/rdoc/created.rid +1 -1
  80. data/doc/rdoc/files/README.html +29 -15
  81. data/doc/rdoc/files/lib/wee/adaptors/webrick_rb.html +1 -1
  82. data/doc/rdoc/files/lib/wee/application_rb.html +1 -1
  83. data/doc/rdoc/files/lib/wee/components/form_decoration_rb.html +101 -0
  84. data/doc/rdoc/files/lib/wee/components/messagebox_rb.html +101 -0
  85. data/doc/rdoc/files/lib/wee/components/page_decoration_rb.html +1 -1
  86. data/doc/rdoc/files/lib/wee/components/wrapper_decoration_rb.html +101 -0
  87. data/doc/rdoc/files/lib/wee/components_rb.html +4 -1
  88. data/doc/rdoc/files/lib/wee/continuation/core/component_rb.html +101 -0
  89. data/doc/rdoc/files/lib/wee/continuation/session_rb.html +110 -0
  90. data/doc/rdoc/files/lib/wee/continuation_rb.html +116 -0
  91. data/doc/rdoc/files/lib/wee/core/callback_rb.html +1 -1
  92. data/doc/rdoc/files/lib/wee/core/component_rb.html +1 -1
  93. data/doc/rdoc/files/lib/wee/core/presenter_rb.html +1 -1
  94. data/doc/rdoc/files/lib/wee/core_rb.html +3 -3
  95. data/doc/rdoc/files/lib/wee/databases/og_rb.html +108 -0
  96. data/doc/rdoc/files/lib/wee/renderer/html/brushes_rb.html +1 -1
  97. data/doc/rdoc/files/lib/wee/renderer/html/canvas_rb.html +1 -1
  98. data/doc/rdoc/files/lib/wee/renderer/html/writer_rb.html +1 -1
  99. data/doc/rdoc/files/lib/wee/requesthandler_rb.html +1 -1
  100. data/doc/rdoc/files/lib/wee/session_rb.html +1 -2
  101. data/doc/rdoc/files/lib/wee/utils/autoreload_rb.html +1 -1
  102. data/doc/rdoc/files/lib/wee/utils/cache_rb.html +1 -1
  103. data/doc/rdoc/files/lib/wee/utils/helper_rb.html +1 -8
  104. data/doc/rdoc/files/lib/wee/utils_rb.html +110 -0
  105. data/doc/rdoc/files/lib/wee_rb.html +1 -1
  106. data/doc/rdoc/fr_class_index.html +11 -1
  107. data/doc/rdoc/fr_file_index.html +8 -0
  108. data/doc/rdoc/fr_method_index.html +269 -228
  109. data/examples/calculator.rb +69 -0
  110. data/examples/calendar.rb +5 -17
  111. data/examples/example.rb +2 -2
  112. data/examples/hw.rb +17 -0
  113. data/examples/live-update.rb +45 -0
  114. data/examples/og-test.rb +51 -0
  115. data/lib/wee.rb +1 -1
  116. data/lib/wee/adaptors/webrick.rb +2 -0
  117. data/lib/wee/application.rb +16 -0
  118. data/lib/wee/components.rb +3 -0
  119. data/lib/wee/components/form_decoration.rb +7 -0
  120. data/{test → lib/wee}/components/messagebox.rb +1 -1
  121. data/lib/wee/components/page_decoration.rb +5 -5
  122. data/lib/wee/components/wrapper_decoration.rb +7 -0
  123. data/lib/wee/continuation.rb +5 -0
  124. data/lib/wee/continuation/core/component.rb +55 -0
  125. data/lib/wee/continuation/session.rb +217 -0
  126. data/lib/wee/core/callback.rb +11 -6
  127. data/lib/wee/core/component.rb +45 -33
  128. data/lib/wee/core/presenter.rb +68 -0
  129. data/lib/wee/databases/og.rb +114 -0
  130. data/lib/wee/renderer/html/brushes.rb +179 -98
  131. data/lib/wee/renderer/html/canvas.rb +37 -13
  132. data/lib/wee/renderer/html/writer.rb +34 -32
  133. data/lib/wee/requesthandler.rb +6 -3
  134. data/lib/wee/session.rb +73 -54
  135. data/lib/wee/utils.rb +5 -0
  136. data/lib/wee/utils/autoreload.rb +1 -1
  137. data/lib/wee/utils/cache.rb +0 -2
  138. data/lib/wee/utils/helper.rb +40 -8
  139. data/test/components/calltest-cont.rb +16 -0
  140. data/test/components/calltest.rb +15 -10
  141. data/test/stress.rb +31 -28
  142. data/test/stress_and_measure.rb +53 -0
  143. data/test/stressed_application.rb +15 -0
  144. data/test/test_html_writer.rb +9 -4
  145. metadata +236 -195
  146. data/benchmark/bench.sh +0 -24
@@ -0,0 +1,153 @@
1
+ <?xml version="1.0" encoding="iso-8859-1"?>
2
+ <!DOCTYPE html
3
+ PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
+
6
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
+ <head>
8
+ <title>Class: Wee::Component::OnAnswer</title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
+ <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
+ <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
12
+ <script type="text/javascript">
13
+ // <![CDATA[
14
+
15
+ function popupCode( url ) {
16
+ window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
+ }
18
+
19
+ function toggleCode( id ) {
20
+ if ( document.getElementById )
21
+ elem = document.getElementById( id );
22
+ else if ( document.all )
23
+ elem = eval( "document.all." + id );
24
+ else
25
+ return false;
26
+
27
+ elemStyle = elem.style;
28
+
29
+ if ( elemStyle.display != "block" ) {
30
+ elemStyle.display = "block"
31
+ } else {
32
+ elemStyle.display = "none"
33
+ }
34
+
35
+ return true;
36
+ }
37
+
38
+ // Make codeblocks hidden by default
39
+ document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
+
41
+ // ]]>
42
+ </script>
43
+
44
+ </head>
45
+ <body>
46
+
47
+
48
+
49
+ <div id="classHeader">
50
+ <table class="header-table">
51
+ <tr class="top-aligned-row">
52
+ <td><strong>Class</strong></td>
53
+ <td class="class-name-in-header">Wee::Component::OnAnswer</td>
54
+ </tr>
55
+ <tr class="top-aligned-row">
56
+ <td><strong>In:</strong></td>
57
+ <td>
58
+ <a href="../../../files/lib/wee/core/component_rb.html">
59
+ lib/wee/core/component.rb
60
+ </a>
61
+ <br />
62
+ </td>
63
+ </tr>
64
+
65
+ <tr class="top-aligned-row">
66
+ <td><strong>Parent:</strong></td>
67
+ <td>
68
+ Struct.new(:calling_component, :called_component, :delegate, :answer, :return_callback, :additional_args)
69
+ </td>
70
+ </tr>
71
+ </table>
72
+ </div>
73
+ <!-- banner header -->
74
+
75
+ <div id="bodyContent">
76
+
77
+
78
+
79
+ <div id="contextContent">
80
+
81
+
82
+
83
+ </div>
84
+
85
+ <div id="method-list">
86
+ <h3 class="section-bar">Methods</h3>
87
+
88
+ <div class="name-list">
89
+ <a href="#M000226">call</a>&nbsp;&nbsp;
90
+ </div>
91
+ </div>
92
+
93
+ </div>
94
+
95
+
96
+ <!-- if includes -->
97
+
98
+ <div id="section">
99
+
100
+
101
+
102
+
103
+
104
+
105
+
106
+
107
+ <!-- if method_list -->
108
+ <div id="methods">
109
+ <h3 class="section-bar">Public Instance methods</h3>
110
+
111
+ <div id="method-M000226" class="method-detail">
112
+ <a name="M000226"></a>
113
+
114
+ <div class="method-heading">
115
+ <a href="#M000226" class="method-signature">
116
+ <span class="method-name">call</span><span class="method-args">(*args)</span>
117
+ </a>
118
+ </div>
119
+
120
+ <div class="method-description">
121
+ <p><a class="source-toggle" href="#"
122
+ onclick="toggleCode('M000226-source');return false;">[Source]</a></p>
123
+ <div class="method-source-code" id="M000226-source">
124
+ <pre>
125
+ <span class="ruby-comment cmt"># File lib/wee/core/component.rb, line 328</span>
126
+ <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">call</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
127
+ <span class="ruby-identifier">calling_component</span>.<span class="ruby-identifier">remove_decoration</span>(<span class="ruby-identifier">delegate</span>)
128
+ <span class="ruby-identifier">called_component</span>.<span class="ruby-identifier">remove_decoration</span>(<span class="ruby-identifier">answer</span>)
129
+ <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">return_callback</span>.<span class="ruby-identifier">nil?</span>
130
+ <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">return_callback</span>.<span class="ruby-identifier">respond_to?</span>(<span class="ruby-identifier">:call</span>)
131
+ <span class="ruby-identifier">return_callback</span>.<span class="ruby-identifier">call</span>(<span class="ruby-operator">*</span>(<span class="ruby-identifier">args</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">additional_args</span>))
132
+ <span class="ruby-keyword kw">else</span>
133
+ <span class="ruby-identifier">calling_component</span>.<span class="ruby-identifier">send</span>(<span class="ruby-identifier">return_callback</span>, <span class="ruby-operator">*</span>(<span class="ruby-identifier">args</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">additional_args</span>))
134
+ <span class="ruby-keyword kw">end</span>
135
+ <span class="ruby-keyword kw">end</span>
136
+ </pre>
137
+ </div>
138
+ </div>
139
+ </div>
140
+
141
+
142
+ </div>
143
+
144
+
145
+ </div>
146
+
147
+
148
+ <div id="validator-badges">
149
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
150
+ </div>
151
+
152
+ </body>
153
+ </html>
@@ -83,9 +83,9 @@
83
83
  <div id="description">
84
84
  <p>
85
85
  Abstract base class of all decorations. Forwards the methods <a
86
- href="Decoration.html#M000141">process_callbacks</a>, <a
87
- href="Decoration.html#M000142">do_render</a> and <a
88
- href="Decoration.html#M000143">backtrack_state</a> to the next decoration
86
+ href="Decoration.html#M000176">process_callbacks</a>, <a
87
+ href="Decoration.html#M000177">do_render</a> and <a
88
+ href="Decoration.html#M000178">backtrack_state</a> to the next decoration
89
89
  in the chain. Subclasses should provide special behaviour in these methods,
90
90
  otherwise the decoration does not make sense.
91
91
  </p>
@@ -119,7 +119,7 @@ around the decorations or components below itself:
119
119
  <div id="contents-list">
120
120
  <h3 class="section-bar">Contents</h3>
121
121
  <ul>
122
- <li><a href="#SEC00078">Snapshot</a></li>
122
+ <li><a href="#SEC00086">Snapshot</a></li>
123
123
  </ul>
124
124
  </div>
125
125
 
@@ -127,12 +127,12 @@ around the decorations or components below itself:
127
127
  <h3 class="section-bar">Methods</h3>
128
128
 
129
129
  <div class="name-list">
130
- <a href="#M000143">backtrack_state</a>&nbsp;&nbsp;
131
- <a href="#M000142">do_render</a>&nbsp;&nbsp;
132
- <a href="#M000140">global?</a>&nbsp;&nbsp;
133
- <a href="#M000141">process_callbacks</a>&nbsp;&nbsp;
134
- <a href="#M000145">restore_snapshot</a>&nbsp;&nbsp;
135
- <a href="#M000144">take_snapshot</a>&nbsp;&nbsp;
130
+ <a href="#M000178">backtrack_state</a>&nbsp;&nbsp;
131
+ <a href="#M000177">do_render</a>&nbsp;&nbsp;
132
+ <a href="#M000175">global?</a>&nbsp;&nbsp;
133
+ <a href="#M000176">process_callbacks</a>&nbsp;&nbsp;
134
+ <a href="#M000180">restore_snapshot</a>&nbsp;&nbsp;
135
+ <a href="#M000179">take_snapshot</a>&nbsp;&nbsp;
136
136
  </div>
137
137
  </div>
138
138
 
@@ -173,11 +173,11 @@ everything &quot;below&quot; itself.
173
173
  <div id="methods">
174
174
  <h3 class="section-bar">Public Instance methods</h3>
175
175
 
176
- <div id="method-M000143" class="method-detail">
177
- <a name="M000143"></a>
176
+ <div id="method-M000178" class="method-detail">
177
+ <a name="M000178"></a>
178
178
 
179
179
  <div class="method-heading">
180
- <a href="#M000143" class="method-signature">
180
+ <a href="#M000178" class="method-signature">
181
181
  <span class="method-name">backtrack_state</span><span class="method-args">(snapshot)</span>
182
182
  </a>
183
183
  </div>
@@ -187,8 +187,8 @@ everything &quot;below&quot; itself.
187
187
  Forwards method call to the next decoration in the chain.
188
188
  </p>
189
189
  <p><a class="source-toggle" href="#"
190
- onclick="toggleCode('M000143-source');return false;">[Source]</a></p>
191
- <div class="method-source-code" id="M000143-source">
190
+ onclick="toggleCode('M000178-source');return false;">[Source]</a></p>
191
+ <div class="method-source-code" id="M000178-source">
192
192
  <pre>
193
193
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 59</span>
194
194
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">backtrack_state</span>(<span class="ruby-identifier">snapshot</span>)
@@ -200,11 +200,11 @@ Forwards method call to the next decoration in the chain.
200
200
  </div>
201
201
  </div>
202
202
 
203
- <div id="method-M000142" class="method-detail">
204
- <a name="M000142"></a>
203
+ <div id="method-M000177" class="method-detail">
204
+ <a name="M000177"></a>
205
205
 
206
206
  <div class="method-heading">
207
- <a href="#M000142" class="method-signature">
207
+ <a href="#M000177" class="method-signature">
208
208
  <span class="method-name">do_render</span><span class="method-args">(rendering_context)</span>
209
209
  </a>
210
210
  </div>
@@ -214,8 +214,8 @@ Forwards method call to the next decoration in the chain.
214
214
  Forwards method call to the next decoration in the chain.
215
215
  </p>
216
216
  <p><a class="source-toggle" href="#"
217
- onclick="toggleCode('M000142-source');return false;">[Source]</a></p>
218
- <div class="method-source-code" id="M000142-source">
217
+ onclick="toggleCode('M000177-source');return false;">[Source]</a></p>
218
+ <div class="method-source-code" id="M000177-source">
219
219
  <pre>
220
220
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 53</span>
221
221
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">do_render</span>(<span class="ruby-identifier">rendering_context</span>)
@@ -226,11 +226,11 @@ Forwards method call to the next decoration in the chain.
226
226
  </div>
227
227
  </div>
228
228
 
229
- <div id="method-M000140" class="method-detail">
230
- <a name="M000140"></a>
229
+ <div id="method-M000175" class="method-detail">
230
+ <a name="M000175"></a>
231
231
 
232
232
  <div class="method-heading">
233
- <a href="#M000140" class="method-signature">
233
+ <a href="#M000175" class="method-signature">
234
234
  <span class="method-name">global?</span><span class="method-args">()</span>
235
235
  </a>
236
236
  </div>
@@ -246,8 +246,8 @@ decoration is added in front of all other local decorations but after all
246
246
  global decorations.
247
247
  </p>
248
248
  <p><a class="source-toggle" href="#"
249
- onclick="toggleCode('M000140-source');return false;">[Source]</a></p>
250
- <div class="method-source-code" id="M000140-source">
249
+ onclick="toggleCode('M000175-source');return false;">[Source]</a></p>
250
+ <div class="method-source-code" id="M000175-source">
251
251
  <pre>
252
252
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 43</span>
253
253
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">global?</span>() <span class="ruby-keyword kw">false</span> <span class="ruby-keyword kw">end</span>
@@ -256,11 +256,11 @@ global decorations.
256
256
  </div>
257
257
  </div>
258
258
 
259
- <div id="method-M000141" class="method-detail">
260
- <a name="M000141"></a>
259
+ <div id="method-M000176" class="method-detail">
260
+ <a name="M000176"></a>
261
261
 
262
262
  <div class="method-heading">
263
- <a href="#M000141" class="method-signature">
263
+ <a href="#M000176" class="method-signature">
264
264
  <span class="method-name">process_callbacks</span><span class="method-args">(callback_stream)</span>
265
265
  </a>
266
266
  </div>
@@ -270,8 +270,8 @@ global decorations.
270
270
  Forwards method call to the next decoration in the chain.
271
271
  </p>
272
272
  <p><a class="source-toggle" href="#"
273
- onclick="toggleCode('M000141-source');return false;">[Source]</a></p>
274
- <div class="method-source-code" id="M000141-source">
273
+ onclick="toggleCode('M000176-source');return false;">[Source]</a></p>
274
+ <div class="method-source-code" id="M000176-source">
275
275
  <pre>
276
276
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 47</span>
277
277
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">process_callbacks</span>(<span class="ruby-identifier">callback_stream</span>)
@@ -285,7 +285,7 @@ Forwards method call to the next decoration in the chain.
285
285
 
286
286
  </div>
287
287
  <div id="section">
288
- <h2 class="section-title"><a name="SEC00078">Snapshot</a></h2>
288
+ <h2 class="section-title"><a name="SEC00086">Snapshot</a></h2>
289
289
  <div class="section-comment">
290
290
 
291
291
  </div>
@@ -301,19 +301,19 @@ Forwards method call to the next decoration in the chain.
301
301
  <div id="methods">
302
302
  <h3 class="section-bar">Public Instance methods</h3>
303
303
 
304
- <div id="method-M000145" class="method-detail">
305
- <a name="M000145"></a>
304
+ <div id="method-M000180" class="method-detail">
305
+ <a name="M000180"></a>
306
306
 
307
307
  <div class="method-heading">
308
- <a href="#M000145" class="method-signature">
308
+ <a href="#M000180" class="method-signature">
309
309
  <span class="method-name">restore_snapshot</span><span class="method-args">(snap)</span>
310
310
  </a>
311
311
  </div>
312
312
 
313
313
  <div class="method-description">
314
314
  <p><a class="source-toggle" href="#"
315
- onclick="toggleCode('M000145-source');return false;">[Source]</a></p>
316
- <div class="method-source-code" id="M000145-source">
315
+ onclick="toggleCode('M000180-source');return false;">[Source]</a></p>
316
+ <div class="method-source-code" id="M000180-source">
317
317
  <pre>
318
318
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 78</span>
319
319
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">restore_snapshot</span>(<span class="ruby-identifier">snap</span>)
@@ -324,11 +324,11 @@ Forwards method call to the next decoration in the chain.
324
324
  </div>
325
325
  </div>
326
326
 
327
- <div id="method-M000144" class="method-detail">
328
- <a name="M000144"></a>
327
+ <div id="method-M000179" class="method-detail">
328
+ <a name="M000179"></a>
329
329
 
330
330
  <div class="method-heading">
331
- <a href="#M000144" class="method-signature">
331
+ <a href="#M000179" class="method-signature">
332
332
  <span class="method-name">take_snapshot</span><span class="method-args">()</span>
333
333
  </a>
334
334
  </div>
@@ -336,14 +336,14 @@ Forwards method call to the next decoration in the chain.
336
336
  <div class="method-description">
337
337
  <p>
338
338
  We have to save the @owner attribute to be able to correctly backtrack
339
- calls, as method <a href="Component.html#M000187">Wee::Component#call</a>
339
+ calls, as method <a href="Component.html#M000223">Wee::Component#call</a>
340
340
  modifies it in the call to <tt>component.remove_decoration(answer)</tt>.
341
341
  Removing the answer-decoration has the advantage to be able to call a
342
342
  component more than once!
343
343
  </p>
344
344
  <p><a class="source-toggle" href="#"
345
- onclick="toggleCode('M000144-source');return false;">[Source]</a></p>
346
- <div class="method-source-code" id="M000144-source">
345
+ onclick="toggleCode('M000179-source');return false;">[Source]</a></p>
346
+ <div class="method-source-code" id="M000179-source">
347
347
  <pre>
348
348
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 74</span>
349
349
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">take_snapshot</span>
@@ -83,9 +83,9 @@
83
83
  <div id="description">
84
84
  <p>
85
85
  A <a href="Delegate.html">Wee::Delegate</a> breaks the decoration chain and
86
- forwards the methods <a href="Delegate.html#M000216">process_callbacks</a>,
87
- <a href="Delegate.html#M000217">do_render</a> and <a
88
- href="Delegate.html#M000218">backtrack_state</a> to the corresponding
86
+ forwards the methods <a href="Delegate.html#M000257">process_callbacks</a>,
87
+ <a href="Delegate.html#M000258">do_render</a> and <a
88
+ href="Delegate.html#M000259">backtrack_state</a> to the corresponding
89
89
  <b>chain</b> method of it&#8217;s <em>delegate</em> component (a <a
90
90
  href="Component.html">Wee::Component</a>).
91
91
  </p>
@@ -99,10 +99,10 @@ href="Component.html">Wee::Component</a>).
99
99
  <h3 class="section-bar">Methods</h3>
100
100
 
101
101
  <div class="name-list">
102
- <a href="#M000218">backtrack_state</a>&nbsp;&nbsp;
103
- <a href="#M000217">do_render</a>&nbsp;&nbsp;
104
- <a href="#M000215">new</a>&nbsp;&nbsp;
105
- <a href="#M000216">process_callbacks</a>&nbsp;&nbsp;
102
+ <a href="#M000259">backtrack_state</a>&nbsp;&nbsp;
103
+ <a href="#M000258">do_render</a>&nbsp;&nbsp;
104
+ <a href="#M000256">new</a>&nbsp;&nbsp;
105
+ <a href="#M000257">process_callbacks</a>&nbsp;&nbsp;
106
106
  </div>
107
107
  </div>
108
108
 
@@ -124,19 +124,19 @@ href="Component.html">Wee::Component</a>).
124
124
  <div id="methods">
125
125
  <h3 class="section-bar">Public Class methods</h3>
126
126
 
127
- <div id="method-M000215" class="method-detail">
128
- <a name="M000215"></a>
127
+ <div id="method-M000256" class="method-detail">
128
+ <a name="M000256"></a>
129
129
 
130
130
  <div class="method-heading">
131
- <a href="#M000215" class="method-signature">
131
+ <a href="#M000256" class="method-signature">
132
132
  <span class="method-name">new</span><span class="method-args">(delegate)</span>
133
133
  </a>
134
134
  </div>
135
135
 
136
136
  <div class="method-description">
137
137
  <p><a class="source-toggle" href="#"
138
- onclick="toggleCode('M000215-source');return false;">[Source]</a></p>
139
- <div class="method-source-code" id="M000215-source">
138
+ onclick="toggleCode('M000256-source');return false;">[Source]</a></p>
139
+ <div class="method-source-code" id="M000256-source">
140
140
  <pre>
141
141
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 89</span>
142
142
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">delegate</span>)
@@ -149,11 +149,11 @@ href="Component.html">Wee::Component</a>).
149
149
 
150
150
  <h3 class="section-bar">Public Instance methods</h3>
151
151
 
152
- <div id="method-M000218" class="method-detail">
153
- <a name="M000218"></a>
152
+ <div id="method-M000259" class="method-detail">
153
+ <a name="M000259"></a>
154
154
 
155
155
  <div class="method-heading">
156
- <a href="#M000218" class="method-signature">
156
+ <a href="#M000259" class="method-signature">
157
157
  <span class="method-name">backtrack_state</span><span class="method-args">(snapshot)</span>
158
158
  </a>
159
159
  </div>
@@ -165,8 +165,8 @@ Forwards method to the corresponding top-level <b>chain</b> method of the
165
165
  components, thus we follow the @owner (via super).
166
166
  </p>
167
167
  <p><a class="source-toggle" href="#"
168
- onclick="toggleCode('M000218-source');return false;">[Source]</a></p>
169
- <div class="method-source-code" id="M000218-source">
168
+ onclick="toggleCode('M000259-source');return false;">[Source]</a></p>
169
+ <div class="method-source-code" id="M000259-source">
170
170
  <pre>
171
171
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 111</span>
172
172
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">backtrack_state</span>(<span class="ruby-identifier">snapshot</span>)
@@ -178,11 +178,11 @@ components, thus we follow the @owner (via super).
178
178
  </div>
179
179
  </div>
180
180
 
181
- <div id="method-M000217" class="method-detail">
182
- <a name="M000217"></a>
181
+ <div id="method-M000258" class="method-detail">
182
+ <a name="M000258"></a>
183
183
 
184
184
  <div class="method-heading">
185
- <a href="#M000217" class="method-signature">
185
+ <a href="#M000258" class="method-signature">
186
186
  <span class="method-name">do_render</span><span class="method-args">(rendering_context)</span>
187
187
  </a>
188
188
  </div>
@@ -193,8 +193,8 @@ Forwards method to the corresponding top-level <b>chain</b> method of the
193
193
  <em>delegate</em> component.
194
194
  </p>
195
195
  <p><a class="source-toggle" href="#"
196
- onclick="toggleCode('M000217-source');return false;">[Source]</a></p>
197
- <div class="method-source-code" id="M000217-source">
196
+ onclick="toggleCode('M000258-source');return false;">[Source]</a></p>
197
+ <div class="method-source-code" id="M000258-source">
198
198
  <pre>
199
199
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 103</span>
200
200
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">do_render</span>(<span class="ruby-identifier">rendering_context</span>)
@@ -205,11 +205,11 @@ Forwards method to the corresponding top-level <b>chain</b> method of the
205
205
  </div>
206
206
  </div>
207
207
 
208
- <div id="method-M000216" class="method-detail">
209
- <a name="M000216"></a>
208
+ <div id="method-M000257" class="method-detail">
209
+ <a name="M000257"></a>
210
210
 
211
211
  <div class="method-heading">
212
- <a href="#M000216" class="method-signature">
212
+ <a href="#M000257" class="method-signature">
213
213
  <span class="method-name">process_callbacks</span><span class="method-args">(callback_stream)</span>
214
214
  </a>
215
215
  </div>
@@ -220,8 +220,8 @@ Forwards method to the corresponding top-level <b>chain</b> method of the
220
220
  <em>delegate</em> component.
221
221
  </p>
222
222
  <p><a class="source-toggle" href="#"
223
- onclick="toggleCode('M000216-source');return false;">[Source]</a></p>
224
- <div class="method-source-code" id="M000216-source">
223
+ onclick="toggleCode('M000257-source');return false;">[Source]</a></p>
224
+ <div class="method-source-code" id="M000257-source">
225
225
  <pre>
226
226
  <span class="ruby-comment cmt"># File lib/wee/core/decoration.rb, line 96</span>
227
227
  <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">process_callbacks</span>(<span class="ruby-identifier">callback_stream</span>)