wee 0.5.0 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +132 -0
- data/INSTALL +13 -3
- data/README +3 -3
- data/Rakefile +5 -1
- data/bin/wee +100 -0
- data/doc/rdoc/classes/Array.html +12 -12
- data/doc/rdoc/classes/Cache/StorageCache.html +38 -38
- data/doc/rdoc/classes/Cache/Strategy/CapacityBounded.html +30 -30
- data/doc/rdoc/classes/Cache/Strategy/LFU.html +24 -24
- data/doc/rdoc/classes/Cache/Strategy/LRU.html +24 -24
- data/doc/rdoc/classes/Cache/Strategy/Unbounded.html +24 -24
- data/doc/rdoc/classes/Enumerable.html +6 -6
- data/doc/rdoc/classes/Main.html +265 -0
- data/doc/rdoc/classes/Object.html +12 -12
- data/doc/rdoc/classes/OgApplication.html +2 -2
- data/doc/rdoc/classes/OgScaffolder.html +444 -64
- data/doc/rdoc/classes/OgScaffolder/Editor.html +490 -0
- data/doc/rdoc/classes/OgSession.html +4 -4
- data/doc/rdoc/classes/Recipe.html +113 -0
- data/doc/rdoc/classes/String.html +12 -12
- data/doc/rdoc/classes/Struct.html +12 -12
- data/doc/rdoc/classes/Wee.html +10 -1
- data/doc/rdoc/classes/Wee/AnswerDecoration.html +9 -9
- data/doc/rdoc/classes/Wee/Application.html +48 -47
- data/doc/rdoc/classes/Wee/Brush.html +19 -23
- data/doc/rdoc/classes/Wee/Brush/AnchorTag.html +17 -14
- data/doc/rdoc/classes/Wee/Brush/FileUploadTag.html +20 -14
- data/doc/rdoc/classes/Wee/Brush/FormTag.html +25 -21
- data/doc/rdoc/classes/Wee/Brush/GenericEncodedTextBrush.html +12 -12
- data/doc/rdoc/classes/Wee/Brush/GenericSingleTagBrush.html +7 -7
- data/doc/rdoc/classes/Wee/Brush/GenericTagBrush.html +234 -100
- data/doc/rdoc/classes/Wee/Brush/GenericTextBrush.html +12 -12
- data/doc/rdoc/classes/Wee/Brush/ImageButtonTag.html +28 -22
- data/doc/rdoc/classes/Wee/Brush/ImageTag.html +23 -24
- data/doc/rdoc/classes/Wee/Brush/InputTag.html +14 -14
- data/doc/rdoc/classes/Wee/Brush/JavascriptTag.html +7 -7
- data/doc/rdoc/classes/Wee/Brush/Page.html +14 -14
- data/doc/rdoc/classes/Wee/Brush/SelectListTag.html +33 -57
- data/doc/rdoc/classes/Wee/Brush/SelectListTag/SelectListCallback.html +154 -0
- data/doc/rdoc/classes/Wee/Brush/SelectOptionTag.html +7 -7
- data/doc/rdoc/classes/Wee/Brush/SubmitButtonTag.html +20 -14
- data/doc/rdoc/classes/Wee/Brush/TableDataTag.html +14 -14
- data/doc/rdoc/classes/Wee/Brush/TableHeaderTag.html +7 -7
- data/doc/rdoc/classes/Wee/Brush/TableRowTag.html +42 -42
- data/doc/rdoc/classes/Wee/Brush/TableTag.html +7 -7
- data/doc/rdoc/classes/Wee/Brush/TextAreaTag.html +27 -21
- data/doc/rdoc/classes/Wee/Brush/TextInputTag.html +20 -14
- data/doc/rdoc/classes/Wee/CallbackRegistry.html +64 -36
- data/doc/rdoc/classes/Wee/CallbackStream.html +21 -21
- data/doc/rdoc/classes/Wee/Canvas.html +24 -24
- data/doc/rdoc/classes/Wee/Component.html +179 -151
- data/doc/rdoc/classes/Wee/Component/OnAnswer.html +12 -12
- data/doc/rdoc/classes/Wee/Decoration.html +42 -42
- data/doc/rdoc/classes/Wee/Delegate.html +27 -27
- data/doc/rdoc/classes/Wee/ErrorResponse.html +14 -14
- data/doc/rdoc/classes/Wee/FormDecoration.html +6 -6
- data/doc/rdoc/classes/Wee/GenericResponse.html +7 -7
- data/doc/rdoc/classes/Wee/HtmlCanvas.html +326 -219
- data/doc/rdoc/classes/Wee/HtmlWriter.html +40 -40
- data/doc/rdoc/classes/Wee/LiteralMethodCallback.html +19 -19
- data/doc/rdoc/classes/Wee/Md5IdGenerator.html +181 -0
- data/doc/rdoc/classes/Wee/MessageBox.html +12 -12
- data/doc/rdoc/classes/Wee/PageDecoration.html +18 -18
- data/doc/rdoc/classes/Wee/PagelessApplication.html +152 -0
- data/doc/rdoc/classes/Wee/PagelessRequest.html +177 -0
- data/doc/rdoc/classes/Wee/PagelessSession.html +320 -0
- data/doc/rdoc/classes/Wee/Presenter.html +145 -89
- data/doc/rdoc/classes/Wee/RedirectResponse.html +7 -7
- data/doc/rdoc/classes/Wee/RefreshResponse.html +7 -7
- data/doc/rdoc/classes/Wee/Request.html +116 -50
- data/doc/rdoc/classes/Wee/RequestHandler.html +31 -31
- data/doc/rdoc/classes/Wee/Response.html +76 -28
- data/doc/rdoc/classes/Wee/Session.html +129 -506
- data/doc/rdoc/classes/Wee/SimpleIdGenerator.html +22 -40
- data/doc/rdoc/classes/Wee/Snapshot.html +19 -19
- data/doc/rdoc/classes/Wee/Utils.html +70 -17
- data/doc/rdoc/classes/Wee/Utils/LRUCache.html +6 -6
- data/doc/rdoc/classes/Wee/ValueHolder.html +18 -18
- data/doc/rdoc/classes/Wee/WEBrickAdaptor.html +82 -49
- data/doc/rdoc/classes/Wee/WrapperDecoration.html +6 -6
- data/doc/rdoc/created.rid +1 -1
- data/doc/rdoc/files/INSTALL.html +17 -5
- data/doc/rdoc/files/README.html +9 -11
- data/doc/rdoc/files/lib/wee/adaptors/webrick_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/application_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/components/page_decoration_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/continuation/session_rb.html +1 -3
- data/doc/rdoc/files/lib/wee/core/callback_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/core/component_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/core_rb.html +3 -3
- data/doc/rdoc/files/lib/wee/databases/og/application_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/databases/og/old_scaffolder_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/databases/og/scaffolder_rb.html +108 -0
- data/doc/rdoc/files/lib/wee/databases/og/session_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/databases/og_rb.html +4 -1
- data/doc/rdoc/files/lib/wee/idgen/md5_rb.html +115 -0
- data/doc/rdoc/files/lib/wee/idgen/simple_rb.html +107 -0
- data/doc/rdoc/files/lib/wee/pageless/application_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/pageless/request_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/pageless/session_rb.html +108 -0
- data/doc/rdoc/files/lib/wee/pageless_rb.html +110 -0
- data/doc/rdoc/files/lib/wee/renderer/html/brushes_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/renderer/html/canvas_rb.html +8 -1
- data/doc/rdoc/files/lib/wee/request_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/response_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/session_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/skeleton/og/components/main_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/skeleton/og/conf/db_rb.html +114 -0
- data/doc/rdoc/files/lib/wee/skeleton/og/models/recipe_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/skeleton/og/run_rb.html +115 -0
- data/doc/rdoc/files/lib/wee/skeleton/simple/components/main_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/skeleton/simple/run_rb.html +111 -0
- data/doc/rdoc/files/lib/wee/template_rb.html +101 -0
- data/doc/rdoc/files/lib/wee/utils/autoreload_rb.html +1 -1
- data/doc/rdoc/files/lib/wee/utils/helper_rb.html +1 -1
- data/doc/rdoc/files/lib/wee_rb.html +4 -2
- data/doc/rdoc/fr_class_index.html +8 -4
- data/doc/rdoc/fr_file_index.html +17 -1
- data/doc/rdoc/fr_method_index.html +312 -267
- data/examples/live-update.rb +1 -1
- data/install.rb +14 -0
- data/lib/wee.rb +6 -2
- data/lib/wee/adaptors/webrick.rb +17 -5
- data/lib/wee/application.rb +2 -1
- data/lib/wee/continuation/session.rb +1 -146
- data/lib/wee/core/callback.rb +11 -5
- data/lib/wee/core/component.rb +14 -10
- data/lib/wee/databases/og.rb +3 -113
- data/lib/wee/databases/og/application.rb +3 -0
- data/lib/wee/databases/og/old_scaffolder.rb +98 -0
- data/lib/wee/databases/og/scaffolder.rb +174 -0
- data/lib/wee/databases/og/session.rb +9 -0
- data/lib/wee/idgen/md5.rb +21 -0
- data/lib/wee/{idgen.rb → idgen/simple.rb} +2 -4
- data/lib/wee/pageless.rb +3 -0
- data/lib/wee/pageless/application.rb +9 -0
- data/lib/wee/pageless/request.rb +15 -0
- data/lib/wee/pageless/session.rb +89 -0
- data/lib/wee/renderer/html/brushes.rb +100 -115
- data/lib/wee/renderer/html/canvas.rb +32 -2
- data/lib/wee/request.rb +36 -24
- data/lib/wee/response.rb +8 -1
- data/lib/wee/session.rb +13 -7
- data/lib/wee/skeleton/og/README +38 -0
- data/lib/wee/skeleton/og/components/main.rb +16 -0
- data/lib/wee/skeleton/og/conf/db.rb +8 -0
- data/lib/wee/skeleton/og/models/recipe.rb +5 -0
- data/lib/wee/skeleton/og/run.rb +23 -0
- data/lib/wee/skeleton/simple/README +32 -0
- data/lib/wee/skeleton/simple/components/main.rb +25 -0
- data/lib/wee/skeleton/simple/run.rb +12 -0
- data/lib/wee/template.rb +28 -0
- data/lib/wee/utils/autoreload.rb +29 -0
- data/lib/wee/utils/helper.rb +9 -5
- data/test/test_request.rb +4 -3
- data/wee.gemspec +3 -1
- metadata +91 -22
@@ -55,6 +55,10 @@
|
|
55
55
|
<tr class="top-aligned-row">
|
56
56
|
<td><strong>In:</strong></td>
|
57
57
|
<td>
|
58
|
+
<a href="../../files/lib/wee/template_rb.html">
|
59
|
+
lib/wee/template.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
58
62
|
<a href="../../files/lib/wee/core/presenter_rb.html">
|
59
63
|
lib/wee/core/presenter.rb
|
60
64
|
</a>
|
@@ -95,11 +99,11 @@ important subclasses.
|
|
95
99
|
<div id="contents-list">
|
96
100
|
<h3 class="section-bar">Contents</h3>
|
97
101
|
<ul>
|
98
|
-
<li><a href="#
|
99
|
-
<li><a href="#
|
100
|
-
<li><a href="#
|
101
|
-
<li><a href="#
|
102
|
-
<li><a href="#
|
102
|
+
<li><a href="#SEC00088">Render</a></li>
|
103
|
+
<li><a href="#SEC00089">Callback</a></li>
|
104
|
+
<li><a href="#SEC00090">Backtrack</a></li>
|
105
|
+
<li><a href="#SEC00091">Session</a></li>
|
106
|
+
<li><a href="#SEC00092">Properties</a></li>
|
103
107
|
</ul>
|
104
108
|
</div>
|
105
109
|
|
@@ -107,18 +111,19 @@ important subclasses.
|
|
107
111
|
<h3 class="section-bar">Methods</h3>
|
108
112
|
|
109
113
|
<div class="name-list">
|
110
|
-
<a href="#
|
111
|
-
<a href="#
|
112
|
-
<a href="#
|
113
|
-
<a href="#
|
114
|
-
<a href="#
|
115
|
-
<a href="#
|
116
|
-
<a href="#
|
117
|
-
<a href="#
|
118
|
-
<a href="#
|
119
|
-
<a href="#
|
120
|
-
<a href="#
|
121
|
-
<a href="#
|
114
|
+
<a href="#M000290">backtrack_state</a>
|
115
|
+
<a href="#M000284">do_render</a>
|
116
|
+
<a href="#M000292">get_property</a>
|
117
|
+
<a href="#M000293">lookup_property</a>
|
118
|
+
<a href="#M000289">process_callbacks</a>
|
119
|
+
<a href="#M000286">r</a>
|
120
|
+
<a href="#M000283">render</a>
|
121
|
+
<a href="#M000285">renderer</a>
|
122
|
+
<a href="#M000288">renderer_class</a>
|
123
|
+
<a href="#M000291">session</a>
|
124
|
+
<a href="#M000282">template</a>
|
125
|
+
<a href="#M000294">uses_property</a>
|
126
|
+
<a href="#M000287">with_renderer_for</a>
|
122
127
|
</div>
|
123
128
|
</div>
|
124
129
|
|
@@ -137,8 +142,59 @@ important subclasses.
|
|
137
142
|
|
138
143
|
|
139
144
|
<!-- if method_list -->
|
145
|
+
<div id="methods">
|
146
|
+
<h3 class="section-bar">Public Class methods</h3>
|
147
|
+
|
148
|
+
<div id="method-M000282" class="method-detail">
|
149
|
+
<a name="M000282"></a>
|
150
|
+
|
151
|
+
<div class="method-heading">
|
152
|
+
<a href="#M000282" class="method-signature">
|
153
|
+
<span class="method-name">template</span><span class="method-args">(method, hash={})</span>
|
154
|
+
</a>
|
155
|
+
</div>
|
156
|
+
|
157
|
+
<div class="method-description">
|
158
|
+
<p><a class="source-toggle" href="#"
|
159
|
+
onclick="toggleCode('M000282-source');return false;">[Source]</a></p>
|
160
|
+
<div class="method-source-code" id="M000282-source">
|
161
|
+
<pre>
|
162
|
+
<span class="ruby-comment cmt"># File lib/wee/template.rb, line 2</span>
|
163
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">template</span>(<span class="ruby-identifier">method</span>, <span class="ruby-identifier">hash</span>={})
|
164
|
+
<span class="ruby-identifier">method</span> = <span class="ruby-identifier">method</span>.<span class="ruby-identifier">to_s</span>
|
165
|
+
|
166
|
+
<span class="ruby-identifier">file_code</span> =
|
167
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">hash</span>.<span class="ruby-identifier">has_key?</span>(<span class="ruby-identifier">:property</span>)
|
168
|
+
<span class="ruby-node">"lookup_property(#{ hash[:property].inspect })"</span>
|
169
|
+
<span class="ruby-keyword kw">elsif</span> <span class="ruby-identifier">hash</span>.<span class="ruby-identifier">has_key?</span>(<span class="ruby-identifier">:file</span>)
|
170
|
+
<span class="ruby-identifier">hash</span>[<span class="ruby-identifier">:file</span>].<span class="ruby-identifier">inspect</span>
|
171
|
+
<span class="ruby-keyword kw">else</span>
|
172
|
+
<span class="ruby-identifier">caller_path</span> = <span class="ruby-identifier">caller</span>.<span class="ruby-identifier">first</span>.<span class="ruby-identifier">sub</span>(<span class="ruby-regexp re">/:\d+$/</span>, <span class="ruby-value str">""</span>)
|
173
|
+
<span class="ruby-identifier">basename</span> = <span class="ruby-identifier">caller_path</span>[<span class="ruby-value">0</span>, <span class="ruby-identifier">caller_path</span>.<span class="ruby-identifier">rindex</span>(<span class="ruby-value str">".rb"</span>)]
|
174
|
+
<span class="ruby-identifier">ext</span> = <span class="ruby-value str">'.tpl'</span>
|
175
|
+
|
176
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">method</span> <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/^render(.*)$/</span>
|
177
|
+
<span class="ruby-identifier">basename</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">ext</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">$1</span>.<span class="ruby-identifier">tr</span>(<span class="ruby-value str">'_'</span>, <span class="ruby-value str">'-'</span>)
|
178
|
+
<span class="ruby-keyword kw">else</span>
|
179
|
+
<span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>
|
180
|
+
<span class="ruby-keyword kw">end</span>.<span class="ruby-identifier">inspect</span>
|
181
|
+
<span class="ruby-keyword kw">end</span>
|
182
|
+
|
183
|
+
<span class="ruby-identifier">class_eval</span> <span class="ruby-node">%{
|
184
|
+
def #{ method }
|
185
|
+
r.template(#{ file_code })
|
186
|
+
end
|
187
|
+
}</span>
|
188
|
+
<span class="ruby-keyword kw">end</span>
|
189
|
+
</pre>
|
190
|
+
</div>
|
191
|
+
</div>
|
192
|
+
</div>
|
193
|
+
|
194
|
+
|
195
|
+
</div>
|
140
196
|
<div id="section">
|
141
|
-
<h2 class="section-title"><a name="
|
197
|
+
<h2 class="section-title"><a name="SEC00088">Render</a></h2>
|
142
198
|
<div class="section-comment">
|
143
199
|
|
144
200
|
</div>
|
@@ -154,11 +210,11 @@ important subclasses.
|
|
154
210
|
<div id="methods">
|
155
211
|
<h3 class="section-bar">Public Instance methods</h3>
|
156
212
|
|
157
|
-
<div id="method-
|
158
|
-
<a name="
|
213
|
+
<div id="method-M000284" class="method-detail">
|
214
|
+
<a name="M000284"></a>
|
159
215
|
|
160
216
|
<div class="method-heading">
|
161
|
-
<a href="#
|
217
|
+
<a href="#M000284" class="method-signature">
|
162
218
|
<span class="method-name">do_render</span><span class="method-args">(rendering_context)</span>
|
163
219
|
</a>
|
164
220
|
</div>
|
@@ -170,8 +226,8 @@ overwrite this method, unless you know exactly what you’re doing!
|
|
170
226
|
</p>
|
171
227
|
<p>
|
172
228
|
Creates a new renderer object of the class returned by method <a
|
173
|
-
href="Presenter.html#
|
174
|
-
renderer, then invokes method <a href="Presenter.html#
|
229
|
+
href="Presenter.html#M000288">renderer_class</a>, makes this the current
|
230
|
+
renderer, then invokes method <a href="Presenter.html#M000283">render</a>.
|
175
231
|
</p>
|
176
232
|
<dl>
|
177
233
|
<dt><tt>rendering_context</tt></dt><dd>An object of class <a href="RenderingContext.html">RenderingContext</a>
|
@@ -179,8 +235,8 @@ renderer, then invokes method <a href="Presenter.html#M000228">render</a>.
|
|
179
235
|
</dd>
|
180
236
|
</dl>
|
181
237
|
<p><a class="source-toggle" href="#"
|
182
|
-
onclick="toggleCode('
|
183
|
-
<div class="method-source-code" id="
|
238
|
+
onclick="toggleCode('M000284-source');return false;">[Source]</a></p>
|
239
|
+
<div class="method-source-code" id="M000284-source">
|
184
240
|
<pre>
|
185
241
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 33</span>
|
186
242
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">do_render</span>(<span class="ruby-identifier">rendering_context</span>)
|
@@ -191,11 +247,11 @@ renderer, then invokes method <a href="Presenter.html#M000228">render</a>.
|
|
191
247
|
</div>
|
192
248
|
</div>
|
193
249
|
|
194
|
-
<div id="method-
|
195
|
-
<a name="
|
250
|
+
<div id="method-M000283" class="method-detail">
|
251
|
+
<a name="M000283"></a>
|
196
252
|
|
197
253
|
<div class="method-heading">
|
198
|
-
<a href="#
|
254
|
+
<a href="#M000283" class="method-signature">
|
199
255
|
<span class="method-name">render</span><span class="method-args">()</span>
|
200
256
|
</a>
|
201
257
|
</div>
|
@@ -210,12 +266,12 @@ view. By default this method does nothing!
|
|
210
266
|
</p>
|
211
267
|
<p>
|
212
268
|
Use the current renderer as returned by <a
|
213
|
-
href="Presenter.html#
|
214
|
-
href="Presenter.html#
|
269
|
+
href="Presenter.html#M000285">renderer</a> or it’s short-cut <a
|
270
|
+
href="Presenter.html#M000286">r</a>.
|
215
271
|
</p>
|
216
272
|
<p><a class="source-toggle" href="#"
|
217
|
-
onclick="toggleCode('
|
218
|
-
<div class="method-source-code" id="
|
273
|
+
onclick="toggleCode('M000283-source');return false;">[Source]</a></p>
|
274
|
+
<div class="method-source-code" id="M000283-source">
|
219
275
|
<pre>
|
220
276
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 20</span>
|
221
277
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">render</span>
|
@@ -227,22 +283,22 @@ href="Presenter.html#M000231">r</a>.
|
|
227
283
|
|
228
284
|
<h3 class="section-bar">Protected Instance methods</h3>
|
229
285
|
|
230
|
-
<div id="method-
|
231
|
-
<a name="
|
286
|
+
<div id="method-M000286" class="method-detail">
|
287
|
+
<a name="M000286"></a>
|
232
288
|
|
233
289
|
<div class="method-heading">
|
234
|
-
<a href="#
|
290
|
+
<a href="#M000286" class="method-signature">
|
235
291
|
<span class="method-name">r</span><span class="method-args">()</span>
|
236
292
|
</a>
|
237
293
|
</div>
|
238
294
|
|
239
295
|
<div class="method-description">
|
240
296
|
<p>
|
241
|
-
Short cut for <a href="Presenter.html#
|
297
|
+
Short cut for <a href="Presenter.html#M000285">renderer</a>.
|
242
298
|
</p>
|
243
299
|
<p><a class="source-toggle" href="#"
|
244
|
-
onclick="toggleCode('
|
245
|
-
<div class="method-source-code" id="
|
300
|
+
onclick="toggleCode('M000286-source');return false;">[Source]</a></p>
|
301
|
+
<div class="method-source-code" id="M000286-source">
|
246
302
|
<pre>
|
247
303
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 43</span>
|
248
304
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">r</span>() <span class="ruby-ivar">@renderer</span> <span class="ruby-keyword kw">end</span>
|
@@ -251,11 +307,11 @@ Short cut for <a href="Presenter.html#M000230">renderer</a>.
|
|
251
307
|
</div>
|
252
308
|
</div>
|
253
309
|
|
254
|
-
<div id="method-
|
255
|
-
<a name="
|
310
|
+
<div id="method-M000285" class="method-detail">
|
311
|
+
<a name="M000285"></a>
|
256
312
|
|
257
313
|
<div class="method-heading">
|
258
|
-
<a href="#
|
314
|
+
<a href="#M000285" class="method-signature">
|
259
315
|
<span class="method-name">renderer</span><span class="method-args">()</span>
|
260
316
|
</a>
|
261
317
|
</div>
|
@@ -265,8 +321,8 @@ Short cut for <a href="Presenter.html#M000230">renderer</a>.
|
|
265
321
|
Returns the current renderer object for use by the render methods.
|
266
322
|
</p>
|
267
323
|
<p><a class="source-toggle" href="#"
|
268
|
-
onclick="toggleCode('
|
269
|
-
<div class="method-source-code" id="
|
324
|
+
onclick="toggleCode('M000285-source');return false;">[Source]</a></p>
|
325
|
+
<div class="method-source-code" id="M000285-source">
|
270
326
|
<pre>
|
271
327
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 40</span>
|
272
328
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">renderer</span>() <span class="ruby-ivar">@renderer</span> <span class="ruby-keyword kw">end</span>
|
@@ -275,11 +331,11 @@ Returns the current renderer object for use by the render methods.
|
|
275
331
|
</div>
|
276
332
|
</div>
|
277
333
|
|
278
|
-
<div id="method-
|
279
|
-
<a name="
|
334
|
+
<div id="method-M000288" class="method-detail">
|
335
|
+
<a name="M000288"></a>
|
280
336
|
|
281
337
|
<div class="method-heading">
|
282
|
-
<a href="#
|
338
|
+
<a href="#M000288" class="method-signature">
|
283
339
|
<span class="method-name">renderer_class</span><span class="method-args">()</span>
|
284
340
|
</a>
|
285
341
|
</div>
|
@@ -290,8 +346,8 @@ Returns the class used as renderer for this presenter. Overwrite this
|
|
290
346
|
method if you want to use a different renderer.
|
291
347
|
</p>
|
292
348
|
<p><a class="source-toggle" href="#"
|
293
|
-
onclick="toggleCode('
|
294
|
-
<div class="method-source-code" id="
|
349
|
+
onclick="toggleCode('M000288-source');return false;">[Source]</a></p>
|
350
|
+
<div class="method-source-code" id="M000288-source">
|
295
351
|
<pre>
|
296
352
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 66</span>
|
297
353
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">renderer_class</span>
|
@@ -302,11 +358,11 @@ method if you want to use a different renderer.
|
|
302
358
|
</div>
|
303
359
|
</div>
|
304
360
|
|
305
|
-
<div id="method-
|
306
|
-
<a name="
|
361
|
+
<div id="method-M000287" class="method-detail">
|
362
|
+
<a name="M000287"></a>
|
307
363
|
|
308
364
|
<div class="method-heading">
|
309
|
-
<a href="#
|
365
|
+
<a href="#M000287" class="method-signature">
|
310
366
|
<span class="method-name">with_renderer_for</span><span class="method-args">(rendering_context) {|| ...}</span>
|
311
367
|
</a>
|
312
368
|
</div>
|
@@ -314,14 +370,14 @@ method if you want to use a different renderer.
|
|
314
370
|
<div class="method-description">
|
315
371
|
<p>
|
316
372
|
Creates a new renderer object of the class returned by method <a
|
317
|
-
href="Presenter.html#
|
373
|
+
href="Presenter.html#M000288">renderer_class</a>, then makes this the
|
318
374
|
current renderer for the time the block it yields to executes. Finally, it
|
319
375
|
restores the current renderer to the former one and closes the newly
|
320
376
|
created renderer.
|
321
377
|
</p>
|
322
378
|
<p><a class="source-toggle" href="#"
|
323
|
-
onclick="toggleCode('
|
324
|
-
<div class="method-source-code" id="
|
379
|
+
onclick="toggleCode('M000287-source');return false;">[Source]</a></p>
|
380
|
+
<div class="method-source-code" id="M000287-source">
|
325
381
|
<pre>
|
326
382
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 50</span>
|
327
383
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">with_renderer_for</span>(<span class="ruby-identifier">rendering_context</span>)
|
@@ -344,7 +400,7 @@ created renderer.
|
|
344
400
|
|
345
401
|
</div>
|
346
402
|
<div id="section">
|
347
|
-
<h2 class="section-title"><a name="
|
403
|
+
<h2 class="section-title"><a name="SEC00089">Callback</a></h2>
|
348
404
|
<div class="section-comment">
|
349
405
|
|
350
406
|
</div>
|
@@ -360,11 +416,11 @@ created renderer.
|
|
360
416
|
<div id="methods">
|
361
417
|
<h3 class="section-bar">Public Instance methods</h3>
|
362
418
|
|
363
|
-
<div id="method-
|
364
|
-
<a name="
|
419
|
+
<div id="method-M000289" class="method-detail">
|
420
|
+
<a name="M000289"></a>
|
365
421
|
|
366
422
|
<div class="method-heading">
|
367
|
-
<a href="#
|
423
|
+
<a href="#M000289" class="method-signature">
|
368
424
|
<span class="method-name">process_callbacks</span><span class="method-args">(callback_stream) {|| ...}</span>
|
369
425
|
</a>
|
370
426
|
</div>
|
@@ -387,8 +443,8 @@ NOTE: Input callbacks should never call other components!
|
|
387
443
|
</dd>
|
388
444
|
</dl>
|
389
445
|
<p><a class="source-toggle" href="#"
|
390
|
-
onclick="toggleCode('
|
391
|
-
<div class="method-source-code" id="
|
446
|
+
onclick="toggleCode('M000289-source');return false;">[Source]</a></p>
|
447
|
+
<div class="method-source-code" id="M000289-source">
|
392
448
|
<pre>
|
393
449
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 87</span>
|
394
450
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">process_callbacks</span>(<span class="ruby-identifier">callback_stream</span>) <span class="ruby-comment cmt"># :yields:</span>
|
@@ -415,7 +471,7 @@ NOTE: Input callbacks should never call other components!
|
|
415
471
|
|
416
472
|
</div>
|
417
473
|
<div id="section">
|
418
|
-
<h2 class="section-title"><a name="
|
474
|
+
<h2 class="section-title"><a name="SEC00090">Backtrack</a></h2>
|
419
475
|
<div class="section-comment">
|
420
476
|
|
421
477
|
</div>
|
@@ -431,11 +487,11 @@ NOTE: Input callbacks should never call other components!
|
|
431
487
|
<div id="methods">
|
432
488
|
<h3 class="section-bar">Public Instance methods</h3>
|
433
489
|
|
434
|
-
<div id="method-
|
435
|
-
<a name="
|
490
|
+
<div id="method-M000290" class="method-detail">
|
491
|
+
<a name="M000290"></a>
|
436
492
|
|
437
493
|
<div class="method-heading">
|
438
|
-
<a href="#
|
494
|
+
<a href="#M000290" class="method-signature">
|
439
495
|
<span class="method-name">backtrack_state</span><span class="method-args">(snapshot)</span>
|
440
496
|
</a>
|
441
497
|
</div>
|
@@ -443,7 +499,7 @@ NOTE: Input callbacks should never call other components!
|
|
443
499
|
<div class="method-description">
|
444
500
|
<p>
|
445
501
|
Dummy implementation. See <a
|
446
|
-
href="Component.html#
|
502
|
+
href="Component.html#M000263">Component#backtrack_state</a> for more
|
447
503
|
information.
|
448
504
|
</p>
|
449
505
|
<dl>
|
@@ -452,8 +508,8 @@ information.
|
|
452
508
|
</dd>
|
453
509
|
</dl>
|
454
510
|
<p><a class="source-toggle" href="#"
|
455
|
-
onclick="toggleCode('
|
456
|
-
<div class="method-source-code" id="
|
511
|
+
onclick="toggleCode('M000290-source');return false;">[Source]</a></p>
|
512
|
+
<div class="method-source-code" id="M000290-source">
|
457
513
|
<pre>
|
458
514
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 115</span>
|
459
515
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">backtrack_state</span>(<span class="ruby-identifier">snapshot</span>)
|
@@ -466,7 +522,7 @@ information.
|
|
466
522
|
|
467
523
|
</div>
|
468
524
|
<div id="section">
|
469
|
-
<h2 class="section-title"><a name="
|
525
|
+
<h2 class="section-title"><a name="SEC00091">Session</a></h2>
|
470
526
|
<div class="section-comment">
|
471
527
|
|
472
528
|
</div>
|
@@ -482,11 +538,11 @@ information.
|
|
482
538
|
<div id="methods">
|
483
539
|
<h3 class="section-bar">Public Instance methods</h3>
|
484
540
|
|
485
|
-
<div id="method-
|
486
|
-
<a name="
|
541
|
+
<div id="method-M000291" class="method-detail">
|
542
|
+
<a name="M000291"></a>
|
487
543
|
|
488
544
|
<div class="method-heading">
|
489
|
-
<a href="#
|
545
|
+
<a href="#M000291" class="method-signature">
|
490
546
|
<span class="method-name">session</span><span class="method-args">()</span>
|
491
547
|
</a>
|
492
548
|
</div>
|
@@ -498,8 +554,8 @@ associated session. The returned object is of class <a
|
|
498
554
|
href="Session.html">Wee::Session</a> or a subclass thereof.
|
499
555
|
</p>
|
500
556
|
<p><a class="source-toggle" href="#"
|
501
|
-
onclick="toggleCode('
|
502
|
-
<div class="method-source-code" id="
|
557
|
+
onclick="toggleCode('M000291-source');return false;">[Source]</a></p>
|
558
|
+
<div class="method-source-code" id="M000291-source">
|
503
559
|
<pre>
|
504
560
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 128</span>
|
505
561
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">session</span>
|
@@ -513,7 +569,7 @@ href="Session.html">Wee::Session</a> or a subclass thereof.
|
|
513
569
|
|
514
570
|
</div>
|
515
571
|
<div id="section">
|
516
|
-
<h2 class="section-title"><a name="
|
572
|
+
<h2 class="section-title"><a name="SEC00092">Properties</a></h2>
|
517
573
|
<div class="section-comment">
|
518
574
|
|
519
575
|
</div>
|
@@ -542,11 +598,11 @@ href="Session.html">Wee::Session</a> or a subclass thereof.
|
|
542
598
|
<div id="methods">
|
543
599
|
<h3 class="section-bar">Public Class methods</h3>
|
544
600
|
|
545
|
-
<div id="method-
|
546
|
-
<a name="
|
601
|
+
<div id="method-M000294" class="method-detail">
|
602
|
+
<a name="M000294"></a>
|
547
603
|
|
548
604
|
<div class="method-heading">
|
549
|
-
<a href="#
|
605
|
+
<a href="#M000294" class="method-signature">
|
550
606
|
<span class="method-name">uses_property</span><span class="method-args">(*args)</span>
|
551
607
|
</a>
|
552
608
|
</div>
|
@@ -557,8 +613,8 @@ This is currently only used for describing which properties are required by
|
|
557
613
|
the underlying component.
|
558
614
|
</p>
|
559
615
|
<p><a class="source-toggle" href="#"
|
560
|
-
onclick="toggleCode('
|
561
|
-
<div class="method-source-code" id="
|
616
|
+
onclick="toggleCode('M000294-source');return false;">[Source]</a></p>
|
617
|
+
<div class="method-source-code" id="M000294-source">
|
562
618
|
<pre>
|
563
619
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 197</span>
|
564
620
|
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">uses_property</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
@@ -570,11 +626,11 @@ the underlying component.
|
|
570
626
|
|
571
627
|
<h3 class="section-bar">Public Instance methods</h3>
|
572
628
|
|
573
|
-
<div id="method-
|
574
|
-
<a name="
|
629
|
+
<div id="method-M000292" class="method-detail">
|
630
|
+
<a name="M000292"></a>
|
575
631
|
|
576
632
|
<div class="method-heading">
|
577
|
-
<a href="#
|
633
|
+
<a href="#M000292" class="method-signature">
|
578
634
|
<span class="method-name">get_property</span><span class="method-args">(prop)</span>
|
579
635
|
</a>
|
580
636
|
</div>
|
@@ -584,8 +640,8 @@ the underlying component.
|
|
584
640
|
Returns an "owned" property.
|
585
641
|
</p>
|
586
642
|
<p><a class="source-toggle" href="#"
|
587
|
-
onclick="toggleCode('
|
588
|
-
<div class="method-source-code" id="
|
643
|
+
onclick="toggleCode('M000292-source');return false;">[Source]</a></p>
|
644
|
+
<div class="method-source-code" id="M000292-source">
|
589
645
|
<pre>
|
590
646
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 140</span>
|
591
647
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">get_property</span>(<span class="ruby-identifier">prop</span>)
|
@@ -600,11 +656,11 @@ Returns an "owned" property.
|
|
600
656
|
</div>
|
601
657
|
</div>
|
602
658
|
|
603
|
-
<div id="method-
|
604
|
-
<a name="
|
659
|
+
<div id="method-M000293" class="method-detail">
|
660
|
+
<a name="M000293"></a>
|
605
661
|
|
606
662
|
<div class="method-heading">
|
607
|
-
<a href="#
|
663
|
+
<a href="#M000293" class="method-signature">
|
608
664
|
<span class="method-name">lookup_property</span><span class="method-args">(prop)</span>
|
609
665
|
</a>
|
610
666
|
</div>
|
@@ -638,8 +694,8 @@ Search order:
|
|
638
694
|
</li>
|
639
695
|
</ol>
|
640
696
|
<p><a class="source-toggle" href="#"
|
641
|
-
onclick="toggleCode('
|
642
|
-
<div class="method-source-code" id="
|
697
|
+
onclick="toggleCode('M000293-source');return false;">[Source]</a></p>
|
698
|
+
<div class="method-source-code" id="M000293-source">
|
643
699
|
<pre>
|
644
700
|
<span class="ruby-comment cmt"># File lib/wee/core/presenter.rb, line 166</span>
|
645
701
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">lookup_property</span>(<span class="ruby-identifier">prop</span>)
|