erubis 2.2.0 → 2.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGES +120 -3
- data/README.txt +1 -1
- data/benchmark/Makefile +6 -0
- data/benchmark/bench.rb +306 -0
- data/benchmark/{erubybench.yaml → bench_context.yaml} +20 -20
- data/benchmark/templates/_footer.html +4 -0
- data/benchmark/{erubybench.rhtml → templates/_header.html} +1 -34
- data/benchmark/templates/bench_erb.rhtml +29 -0
- data/benchmark/templates/bench_erubis.rhtml +29 -0
- data/benchmark/templates/bench_eruby.rhtml +29 -0
- data/bin/erubis +2 -2
- data/contrib/erubis +3 -3114
- data/contrib/erubis-run.rb +132 -0
- data/contrib/inline-require +1 -1
- data/doc-api/classes/{ERB.html → ActionView/Base/ERB.html} +3 -3
- data/doc-api/classes/Erubis.html +8 -1
- data/doc-api/classes/Erubis/ArrayEnhancer.html +12 -12
- data/doc-api/classes/Erubis/Basic/Converter.html +24 -24
- data/doc-api/classes/Erubis/BiPatternEnhancer.html +14 -14
- data/doc-api/classes/Erubis/CGenerator.html +60 -60
- data/doc-api/classes/Erubis/Context.html +42 -42
- data/doc-api/classes/Erubis/Converter.html +27 -27
- data/doc-api/classes/Erubis/DeleteIndentEnhancer.html +150 -0
- data/doc-api/classes/Erubis/DeleteIndentEruby.html +120 -0
- data/doc-api/classes/Erubis/Engine.html +31 -31
- data/doc-api/classes/Erubis/ErboutEnhancer.html +175 -0
- data/doc-api/classes/Erubis/ErboutEruby.html +120 -0
- data/doc-api/classes/Erubis/Eruby.html +5 -0
- data/doc-api/classes/Erubis/EscapeEnhancer.html +6 -6
- data/doc-api/classes/Erubis/Evaluator.html +19 -19
- data/doc-api/classes/Erubis/FastEruby.html +131 -0
- data/doc-api/classes/Erubis/HeaderFooterEnhancer.html +14 -14
- data/doc-api/classes/Erubis/Helpers/RailsHelper.html +49 -45
- data/doc-api/classes/Erubis/InterpolationEnhancer.html +304 -0
- data/doc-api/classes/Erubis/InterpolationEruby.html +120 -0
- data/doc-api/classes/Erubis/JavaGenerator.html +54 -54
- data/doc-api/classes/Erubis/JavascriptGenerator.html +60 -60
- data/doc-api/classes/Erubis/Main.html +35 -27
- data/doc-api/classes/Erubis/NoCodeEnhancer.html +5 -5
- data/doc-api/classes/Erubis/NoTextEnhancer.html +7 -7
- data/doc-api/classes/Erubis/OptimizedEruby.html +6 -6
- data/doc-api/classes/Erubis/OptimizedGenerator.html +72 -72
- data/doc-api/classes/Erubis/OptimizedXmlEruby.html +6 -6
- data/doc-api/classes/Erubis/PI/Converter.html +18 -18
- data/doc-api/classes/Erubis/PI/Ec.html +6 -6
- data/doc-api/classes/Erubis/PI/Ejava.html +6 -6
- data/doc-api/classes/Erubis/PI/Ejavascript.html +6 -6
- data/doc-api/classes/Erubis/PI/Eperl.html +6 -6
- data/doc-api/classes/Erubis/PI/Ephp.html +6 -6
- data/doc-api/classes/Erubis/PI/Eruby.html +7 -7
- data/doc-api/classes/Erubis/PI/Escheme.html +6 -6
- data/doc-api/classes/Erubis/PI/TinyEruby.html +24 -24
- data/doc-api/classes/Erubis/PercentLineEnhancer.html +8 -8
- data/doc-api/classes/Erubis/PerlGenerator.html +54 -54
- data/doc-api/classes/Erubis/PhpGenerator.html +54 -54
- data/doc-api/classes/Erubis/PrintEnabledEnhancer.html +20 -20
- data/doc-api/classes/Erubis/PrintOutEnhancer.html +30 -30
- data/doc-api/classes/Erubis/RubyEvaluator.html +12 -12
- data/doc-api/classes/Erubis/RubyGenerator.html +48 -48
- data/doc-api/classes/Erubis/SchemeGenerator.html +60 -60
- data/doc-api/classes/Erubis/SimplifyEnhancer.html +8 -8
- data/doc-api/classes/Erubis/StdoutEnhancer.html +12 -12
- data/doc-api/classes/Erubis/StringBufferEnhancer.html +12 -12
- data/doc-api/classes/Erubis/TinyEruby.html +24 -24
- data/doc-api/classes/Erubis/XmlHelper.html +14 -14
- data/doc-api/created.rid +1 -1
- data/doc-api/files/README_txt.html +4 -4
- data/doc-api/files/erubis/context_rb.html +2 -2
- data/doc-api/files/erubis/converter_rb.html +2 -2
- data/doc-api/files/erubis/engine/ec_rb.html +2 -2
- data/doc-api/files/erubis/engine/ejava_rb.html +2 -2
- data/doc-api/files/erubis/engine/ejavascript_rb.html +2 -2
- data/doc-api/files/erubis/engine/enhanced_rb.html +2 -2
- data/doc-api/files/erubis/engine/eperl_rb.html +2 -2
- data/doc-api/files/erubis/engine/ephp_rb.html +2 -2
- data/doc-api/files/erubis/engine/eruby_rb.html +2 -2
- data/doc-api/files/erubis/engine/escheme_rb.html +2 -2
- data/doc-api/files/erubis/engine/optimized_rb.html +2 -2
- data/doc-api/files/erubis/engine_rb.html +2 -2
- data/doc-api/files/erubis/enhancer_rb.html +2 -2
- data/doc-api/files/erubis/error_rb.html +2 -2
- data/doc-api/files/erubis/evaluator_rb.html +2 -2
- data/doc-api/files/erubis/generator_rb.html +2 -2
- data/doc-api/files/erubis/helper_rb.html +2 -2
- data/doc-api/files/erubis/helpers/rails_helper_rb.html +2 -2
- data/doc-api/files/erubis/local-setting_rb.html +2 -2
- data/doc-api/files/erubis/main_rb.html +2 -2
- data/doc-api/files/erubis/tiny_rb.html +2 -2
- data/doc-api/files/erubis_rb.html +1 -1
- data/doc-api/fr_class_index.html +8 -1
- data/doc-api/fr_method_index.html +166 -158
- data/doc/users-guide.html +623 -215
- data/lib/erubis.rb +2 -2
- data/lib/erubis/context.rb +2 -2
- data/lib/erubis/converter.rb +2 -2
- data/lib/erubis/engine.rb +3 -3
- data/lib/erubis/engine/ec.rb +2 -2
- data/lib/erubis/engine/ejava.rb +2 -2
- data/lib/erubis/engine/ejavascript.rb +2 -2
- data/lib/erubis/engine/enhanced.rb +17 -2
- data/lib/erubis/engine/eperl.rb +2 -2
- data/lib/erubis/engine/ephp.rb +2 -2
- data/lib/erubis/engine/eruby.rb +10 -2
- data/lib/erubis/engine/escheme.rb +2 -2
- data/lib/erubis/engine/optimized.rb +2 -2
- data/lib/erubis/enhancer.rb +134 -25
- data/lib/erubis/error.rb +2 -2
- data/lib/erubis/evaluator.rb +2 -2
- data/lib/erubis/generator.rb +2 -2
- data/lib/erubis/helper.rb +2 -2
- data/lib/erubis/helpers/rails_helper.rb +19 -75
- data/lib/erubis/local-setting.rb +2 -2
- data/lib/erubis/main.rb +63 -36
- data/lib/erubis/tiny.rb +2 -2
- data/test/assert-text-equal.rb +2 -2
- data/test/data/users-guide/Example.ejava +55 -0
- data/test/data/users-guide/array_example.result +9 -0
- data/test/data/users-guide/arraybuffer_example.result +9 -0
- data/test/data/users-guide/bipattern-example.rhtml +4 -0
- data/test/data/users-guide/bipattern_example.result +6 -0
- data/test/data/users-guide/context.rb +6 -0
- data/test/data/users-guide/context.yaml +8 -0
- data/test/data/users-guide/escape_example.result +9 -0
- data/test/data/users-guide/example.ec +27 -0
- data/test/data/users-guide/example.ejs +20 -0
- data/test/data/users-guide/example.eperl +18 -0
- data/test/data/users-guide/example.ephp +18 -0
- data/test/data/users-guide/example.eruby +6 -0
- data/test/data/users-guide/example.escheme +28 -0
- data/test/data/users-guide/example1.eruby +6 -0
- data/test/data/users-guide/example1.rb +16 -0
- data/test/data/users-guide/example1.result +16 -0
- data/test/data/users-guide/example10.rb +4 -0
- data/test/data/users-guide/example10.result +17 -0
- data/test/data/users-guide/example10.xhtml +14 -0
- data/test/data/users-guide/example10_x.result +17 -0
- data/test/data/users-guide/example11.php +20 -0
- data/test/data/users-guide/example11.result +23 -0
- data/test/data/users-guide/example11.rhtml +21 -0
- data/test/data/users-guide/example11_C.result +10 -0
- data/test/data/users-guide/example11_N.result +16 -0
- data/test/data/users-guide/example11_U.result +16 -0
- data/test/data/users-guide/example11_php.result +15 -0
- data/test/data/users-guide/example1_x.result +9 -0
- data/test/data/users-guide/example2.eruby +7 -0
- data/test/data/users-guide/example2.rb +10 -0
- data/test/data/users-guide/example2.result +27 -0
- data/test/data/users-guide/example2_trim.result +10 -0
- data/test/data/users-guide/example2_x.result +10 -0
- data/test/data/users-guide/example3.eruby +6 -0
- data/test/data/users-guide/example3.rb +10 -0
- data/test/data/users-guide/example31.result +22 -0
- data/test/data/users-guide/example32.result +4 -0
- data/test/data/users-guide/example3_e.result +8 -0
- data/test/data/users-guide/example4.eruby +3 -0
- data/test/data/users-guide/example4.rb +11 -0
- data/test/data/users-guide/example4.result +10 -0
- data/test/data/users-guide/example4_x.result +5 -0
- data/test/data/users-guide/example5.eruby +6 -0
- data/test/data/users-guide/example5.rb +16 -0
- data/test/data/users-guide/example5.result +7 -0
- data/test/data/users-guide/example6.rb +12 -0
- data/test/data/users-guide/example6.result +7 -0
- data/test/data/users-guide/example7.eruby +8 -0
- data/test/data/users-guide/example71.result +13 -0
- data/test/data/users-guide/example72.result +13 -0
- data/test/data/users-guide/example8.eruby +6 -0
- data/test/data/users-guide/example8_ruby.result +7 -0
- data/test/data/users-guide/example8_yaml.result +7 -0
- data/test/data/users-guide/example9.eruby +3 -0
- data/test/data/users-guide/example9.rb +8 -0
- data/test/data/users-guide/example9.result +9 -0
- data/test/data/users-guide/example91.result +5 -0
- data/test/data/users-guide/example92.result +4 -0
- data/test/data/users-guide/example_c.result +29 -0
- data/test/data/users-guide/example_java.result +56 -0
- data/test/data/users-guide/example_js.result +22 -0
- data/test/data/users-guide/example_perl.result +20 -0
- data/test/data/users-guide/example_php.result +19 -0
- data/test/data/users-guide/example_scheme.result +30 -0
- data/test/data/users-guide/example_scheme_display.result +29 -0
- data/test/data/users-guide/fasteruby.rb +11 -0
- data/test/data/users-guide/fasteruby.result +38 -0
- data/test/data/users-guide/fasteruby.rhtml +15 -0
- data/test/data/users-guide/headerfooter-example.eruby +9 -0
- data/test/data/users-guide/headerfooter-example2.rb +8 -0
- data/test/data/users-guide/headerfooter-example2.rhtml +10 -0
- data/test/data/users-guide/headerfooter_example.result +11 -0
- data/test/data/users-guide/headerfooter_example2.result +13 -0
- data/test/data/users-guide/interpolation_example.result +9 -0
- data/test/data/users-guide/nocode-example.eruby +14 -0
- data/test/data/users-guide/nocode-php.result +20 -0
- data/test/data/users-guide/nocode_example.result +15 -0
- data/test/data/users-guide/normal-eruby-test.eruby +9 -0
- data/test/data/users-guide/normal_eruby_test.result +11 -0
- data/test/data/users-guide/notext-example.eruby +14 -0
- data/test/data/users-guide/notext-example.php +19 -0
- data/test/data/users-guide/notext-php.result +20 -0
- data/test/data/users-guide/notext_example.result +16 -0
- data/test/data/users-guide/percentline-example.rhtml +4 -0
- data/test/data/users-guide/percentline_example.result +7 -0
- data/test/data/users-guide/printenable_example.result +4 -0
- data/test/data/users-guide/printenabled-example.eruby +3 -0
- data/test/data/users-guide/printenabled-example.rb +8 -0
- data/test/data/users-guide/printstatement_example.result +8 -0
- data/test/data/users-guide/simplify_example.result +9 -0
- data/test/data/users-guide/stdout_exmple.result +9 -0
- data/test/data/users-guide/stringbuffer_example.result +9 -0
- data/test/test-engines.rb +2 -2
- data/test/test-enhancers.rb +569 -0
- data/test/test-erubis.rb +3 -380
- data/test/test-main.rb +39 -15
- data/test/test-users-guide.rb +56 -0
- data/test/test.rb +4 -3
- data/test/testutil.rb +2 -2
- metadata +166 -57
- data/benchmark/erubybench-lib.rb +0 -189
- data/benchmark/erubybench.rb +0 -600
- data/bin/notext +0 -154
- data/test/test-notext.rb +0 -27
@@ -80,16 +80,16 @@
|
|
80
80
|
<h3 class="section-bar">Methods</h3>
|
81
81
|
|
82
82
|
<div class="name-list">
|
83
|
-
<a href="#
|
84
|
-
<a href="#
|
85
|
-
<a href="#
|
86
|
-
<a href="#
|
87
|
-
<a href="#
|
88
|
-
<a href="#
|
89
|
-
<a href="#
|
90
|
-
<a href="#
|
91
|
-
<a href="#
|
92
|
-
<a href="#
|
83
|
+
<a href="#M000032">add_expr_debug</a>
|
84
|
+
<a href="#M000031">add_expr_escaped</a>
|
85
|
+
<a href="#M000030">add_expr_literal</a>
|
86
|
+
<a href="#M000033">add_postamble</a>
|
87
|
+
<a href="#M000025">add_preamble</a>
|
88
|
+
<a href="#M000029">add_stmt</a>
|
89
|
+
<a href="#M000028">add_text</a>
|
90
|
+
<a href="#M000026">escape_text</a>
|
91
|
+
<a href="#M000027">escaped_expr</a>
|
92
|
+
<a href="#M000024">init_generator</a>
|
93
93
|
</div>
|
94
94
|
</div>
|
95
95
|
|
@@ -118,19 +118,19 @@
|
|
118
118
|
<div id="methods">
|
119
119
|
<h3 class="section-bar">Public Instance methods</h3>
|
120
120
|
|
121
|
-
<div id="method-
|
122
|
-
<a name="
|
121
|
+
<div id="method-M000032" class="method-detail">
|
122
|
+
<a name="M000032"></a>
|
123
123
|
|
124
124
|
<div class="method-heading">
|
125
|
-
<a href="#
|
125
|
+
<a href="#M000032" class="method-signature">
|
126
126
|
<span class="method-name">add_expr_debug</span><span class="method-args">(src, code)</span>
|
127
127
|
</a>
|
128
128
|
</div>
|
129
129
|
|
130
130
|
<div class="method-description">
|
131
131
|
<p><a class="source-toggle" href="#"
|
132
|
-
onclick="toggleCode('
|
133
|
-
<div class="method-source-code" id="
|
132
|
+
onclick="toggleCode('M000032-source');return false;">[Source]</a></p>
|
133
|
+
<div class="method-source-code" id="M000032-source">
|
134
134
|
<pre>
|
135
135
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 72</span>
|
136
136
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_expr_debug</span>(<span class="ruby-identifier">src</span>, <span class="ruby-identifier">code</span>)
|
@@ -142,19 +142,19 @@
|
|
142
142
|
</div>
|
143
143
|
</div>
|
144
144
|
|
145
|
-
<div id="method-
|
146
|
-
<a name="
|
145
|
+
<div id="method-M000031" class="method-detail">
|
146
|
+
<a name="M000031"></a>
|
147
147
|
|
148
148
|
<div class="method-heading">
|
149
|
-
<a href="#
|
149
|
+
<a href="#M000031" class="method-signature">
|
150
150
|
<span class="method-name">add_expr_escaped</span><span class="method-args">(src, code)</span>
|
151
151
|
</a>
|
152
152
|
</div>
|
153
153
|
|
154
154
|
<div class="method-description">
|
155
155
|
<p><a class="source-toggle" href="#"
|
156
|
-
onclick="toggleCode('
|
157
|
-
<div class="method-source-code" id="
|
156
|
+
onclick="toggleCode('M000031-source');return false;">[Source]</a></p>
|
157
|
+
<div class="method-source-code" id="M000031-source">
|
158
158
|
<pre>
|
159
159
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 68</span>
|
160
160
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_expr_escaped</span>(<span class="ruby-identifier">src</span>, <span class="ruby-identifier">code</span>)
|
@@ -165,19 +165,19 @@
|
|
165
165
|
</div>
|
166
166
|
</div>
|
167
167
|
|
168
|
-
<div id="method-
|
169
|
-
<a name="
|
168
|
+
<div id="method-M000030" class="method-detail">
|
169
|
+
<a name="M000030"></a>
|
170
170
|
|
171
171
|
<div class="method-heading">
|
172
|
-
<a href="#
|
172
|
+
<a href="#M000030" class="method-signature">
|
173
173
|
<span class="method-name">add_expr_literal</span><span class="method-args">(src, code)</span>
|
174
174
|
</a>
|
175
175
|
</div>
|
176
176
|
|
177
177
|
<div class="method-description">
|
178
178
|
<p><a class="source-toggle" href="#"
|
179
|
-
onclick="toggleCode('
|
180
|
-
<div class="method-source-code" id="
|
179
|
+
onclick="toggleCode('M000030-source');return false;">[Source]</a></p>
|
180
|
+
<div class="method-source-code" id="M000030-source">
|
181
181
|
<pre>
|
182
182
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 63</span>
|
183
183
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_expr_literal</span>(<span class="ruby-identifier">src</span>, <span class="ruby-identifier">code</span>)
|
@@ -189,19 +189,19 @@
|
|
189
189
|
</div>
|
190
190
|
</div>
|
191
191
|
|
192
|
-
<div id="method-
|
193
|
-
<a name="
|
192
|
+
<div id="method-M000033" class="method-detail">
|
193
|
+
<a name="M000033"></a>
|
194
194
|
|
195
195
|
<div class="method-heading">
|
196
|
-
<a href="#
|
196
|
+
<a href="#M000033" class="method-signature">
|
197
197
|
<span class="method-name">add_postamble</span><span class="method-args">(src)</span>
|
198
198
|
</a>
|
199
199
|
</div>
|
200
200
|
|
201
201
|
<div class="method-description">
|
202
202
|
<p><a class="source-toggle" href="#"
|
203
|
-
onclick="toggleCode('
|
204
|
-
<div class="method-source-code" id="
|
203
|
+
onclick="toggleCode('M000033-source');return false;">[Source]</a></p>
|
204
|
+
<div class="method-source-code" id="M000033-source">
|
205
205
|
<pre>
|
206
206
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 77</span>
|
207
207
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_postamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -214,19 +214,19 @@
|
|
214
214
|
</div>
|
215
215
|
</div>
|
216
216
|
|
217
|
-
<div id="method-
|
218
|
-
<a name="
|
217
|
+
<div id="method-M000025" class="method-detail">
|
218
|
+
<a name="M000025"></a>
|
219
219
|
|
220
220
|
<div class="method-heading">
|
221
|
-
<a href="#
|
221
|
+
<a href="#M000025" class="method-signature">
|
222
222
|
<span class="method-name">add_preamble</span><span class="method-args">(src)</span>
|
223
223
|
</a>
|
224
224
|
</div>
|
225
225
|
|
226
226
|
<div class="method-description">
|
227
227
|
<p><a class="source-toggle" href="#"
|
228
|
-
onclick="toggleCode('
|
229
|
-
<div class="method-source-code" id="
|
228
|
+
onclick="toggleCode('M000025-source');return false;">[Source]</a></p>
|
229
|
+
<div class="method-source-code" id="M000025-source">
|
230
230
|
<pre>
|
231
231
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 29</span>
|
232
232
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_preamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -240,19 +240,19 @@
|
|
240
240
|
</div>
|
241
241
|
</div>
|
242
242
|
|
243
|
-
<div id="method-
|
244
|
-
<a name="
|
243
|
+
<div id="method-M000029" class="method-detail">
|
244
|
+
<a name="M000029"></a>
|
245
245
|
|
246
246
|
<div class="method-heading">
|
247
|
-
<a href="#
|
247
|
+
<a href="#M000029" class="method-signature">
|
248
248
|
<span class="method-name">add_stmt</span><span class="method-args">(src, code)</span>
|
249
249
|
</a>
|
250
250
|
</div>
|
251
251
|
|
252
252
|
<div class="method-description">
|
253
253
|
<p><a class="source-toggle" href="#"
|
254
|
-
onclick="toggleCode('
|
255
|
-
<div class="method-source-code" id="
|
254
|
+
onclick="toggleCode('M000029-source');return false;">[Source]</a></p>
|
255
|
+
<div class="method-source-code" id="M000029-source">
|
256
256
|
<pre>
|
257
257
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 59</span>
|
258
258
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_stmt</span>(<span class="ruby-identifier">src</span>, <span class="ruby-identifier">code</span>)
|
@@ -263,19 +263,19 @@
|
|
263
263
|
</div>
|
264
264
|
</div>
|
265
265
|
|
266
|
-
<div id="method-
|
267
|
-
<a name="
|
266
|
+
<div id="method-M000028" class="method-detail">
|
267
|
+
<a name="M000028"></a>
|
268
268
|
|
269
269
|
<div class="method-heading">
|
270
|
-
<a href="#
|
270
|
+
<a href="#M000028" class="method-signature">
|
271
271
|
<span class="method-name">add_text</span><span class="method-args">(src, text)</span>
|
272
272
|
</a>
|
273
273
|
</div>
|
274
274
|
|
275
275
|
<div class="method-description">
|
276
276
|
<p><a class="source-toggle" href="#"
|
277
|
-
onclick="toggleCode('
|
278
|
-
<div class="method-source-code" id="
|
277
|
+
onclick="toggleCode('M000028-source');return false;">[Source]</a></p>
|
278
|
+
<div class="method-source-code" id="M000028-source">
|
279
279
|
<pre>
|
280
280
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 48</span>
|
281
281
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_text</span>(<span class="ruby-identifier">src</span>, <span class="ruby-identifier">text</span>)
|
@@ -293,19 +293,19 @@
|
|
293
293
|
</div>
|
294
294
|
</div>
|
295
295
|
|
296
|
-
<div id="method-
|
297
|
-
<a name="
|
296
|
+
<div id="method-M000026" class="method-detail">
|
297
|
+
<a name="M000026"></a>
|
298
298
|
|
299
299
|
<div class="method-heading">
|
300
|
-
<a href="#
|
300
|
+
<a href="#M000026" class="method-signature">
|
301
301
|
<span class="method-name">escape_text</span><span class="method-args">(text)</span>
|
302
302
|
</a>
|
303
303
|
</div>
|
304
304
|
|
305
305
|
<div class="method-description">
|
306
306
|
<p><a class="source-toggle" href="#"
|
307
|
-
onclick="toggleCode('
|
308
|
-
<div class="method-source-code" id="
|
307
|
+
onclick="toggleCode('M000026-source');return false;">[Source]</a></p>
|
308
|
+
<div class="method-source-code" id="M000026-source">
|
309
309
|
<pre>
|
310
310
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 37</span>
|
311
311
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">escape_text</span>(<span class="ruby-identifier">text</span>)
|
@@ -318,19 +318,19 @@
|
|
318
318
|
</div>
|
319
319
|
</div>
|
320
320
|
|
321
|
-
<div id="method-
|
322
|
-
<a name="
|
321
|
+
<div id="method-M000027" class="method-detail">
|
322
|
+
<a name="M000027"></a>
|
323
323
|
|
324
324
|
<div class="method-heading">
|
325
|
-
<a href="#
|
325
|
+
<a href="#M000027" class="method-signature">
|
326
326
|
<span class="method-name">escaped_expr</span><span class="method-args">(code)</span>
|
327
327
|
</a>
|
328
328
|
</div>
|
329
329
|
|
330
330
|
<div class="method-description">
|
331
331
|
<p><a class="source-toggle" href="#"
|
332
|
-
onclick="toggleCode('
|
333
|
-
<div class="method-source-code" id="
|
332
|
+
onclick="toggleCode('M000027-source');return false;">[Source]</a></p>
|
333
|
+
<div class="method-source-code" id="M000027-source">
|
334
334
|
<pre>
|
335
335
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 43</span>
|
336
336
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">escaped_expr</span>(<span class="ruby-identifier">code</span>)
|
@@ -342,19 +342,19 @@
|
|
342
342
|
</div>
|
343
343
|
</div>
|
344
344
|
|
345
|
-
<div id="method-
|
346
|
-
<a name="
|
345
|
+
<div id="method-M000024" class="method-detail">
|
346
|
+
<a name="M000024"></a>
|
347
347
|
|
348
348
|
<div class="method-heading">
|
349
|
-
<a href="#
|
349
|
+
<a href="#M000024" class="method-signature">
|
350
350
|
<span class="method-name">init_generator</span><span class="method-args">(properties={})</span>
|
351
351
|
</a>
|
352
352
|
</div>
|
353
353
|
|
354
354
|
<div class="method-description">
|
355
355
|
<p><a class="source-toggle" href="#"
|
356
|
-
onclick="toggleCode('
|
357
|
-
<div class="method-source-code" id="
|
356
|
+
onclick="toggleCode('M000024-source');return false;">[Source]</a></p>
|
357
|
+
<div class="method-source-code" id="M000024-source">
|
358
358
|
<pre>
|
359
359
|
<span class="ruby-comment cmt"># File erubis/engine/escheme.rb, line 23</span>
|
360
360
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">init_generator</span>(<span class="ruby-identifier">properties</span>={})
|
@@ -74,7 +74,7 @@
|
|
74
74
|
|
75
75
|
<div id="description">
|
76
76
|
<p>
|
77
|
-
get <a href="SimplifyEnhancer.html#
|
77
|
+
get <a href="SimplifyEnhancer.html#M000023">convert</a> faster, but spaces
|
78
78
|
around ’<%…%>’ are not trimmed.
|
79
79
|
</p>
|
80
80
|
<p>
|
@@ -90,7 +90,7 @@ this is language-independent.
|
|
90
90
|
<h3 class="section-bar">Methods</h3>
|
91
91
|
|
92
92
|
<div class="name-list">
|
93
|
-
<a href="#
|
93
|
+
<a href="#M000023">convert</a>
|
94
94
|
</div>
|
95
95
|
</div>
|
96
96
|
|
@@ -130,21 +130,21 @@ DEFAULT_REGEXP = /(^[ \t]*)?<%(=+|\#)?(.*?)-?%>([ \t]*\r?\n)?/m
|
|
130
130
|
<div id="methods">
|
131
131
|
<h3 class="section-bar">Public Instance methods</h3>
|
132
132
|
|
133
|
-
<div id="method-
|
134
|
-
<a name="
|
133
|
+
<div id="method-M000023" class="method-detail">
|
134
|
+
<a name="M000023"></a>
|
135
135
|
|
136
136
|
<div class="method-heading">
|
137
|
-
<a href="#
|
137
|
+
<a href="#M000023" class="method-signature">
|
138
138
|
<span class="method-name">convert</span><span class="method-args">(input)</span>
|
139
139
|
</a>
|
140
140
|
</div>
|
141
141
|
|
142
142
|
<div class="method-description">
|
143
143
|
<p><a class="source-toggle" href="#"
|
144
|
-
onclick="toggleCode('
|
145
|
-
<div class="method-source-code" id="
|
144
|
+
onclick="toggleCode('M000023-source');return false;">[Source]</a></p>
|
145
|
+
<div class="method-source-code" id="M000023-source">
|
146
146
|
<pre>
|
147
|
-
<span class="ruby-comment cmt"># File erubis/enhancer.rb, line
|
147
|
+
<span class="ruby-comment cmt"># File erubis/enhancer.rb, line 343</span>
|
148
148
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">convert</span>(<span class="ruby-identifier">input</span>)
|
149
149
|
<span class="ruby-identifier">src</span> = <span class="ruby-value str">""</span>
|
150
150
|
<span class="ruby-identifier">add_preamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -89,8 +89,8 @@ this is only for <a href="Eruby.html">Eruby</a>.
|
|
89
89
|
<h3 class="section-bar">Methods</h3>
|
90
90
|
|
91
91
|
<div class="name-list">
|
92
|
-
<a href="#
|
93
|
-
<a href="#
|
92
|
+
<a href="#M000064">add_postamble</a>
|
93
|
+
<a href="#M000063">add_preamble</a>
|
94
94
|
</div>
|
95
95
|
</div>
|
96
96
|
|
@@ -112,19 +112,19 @@ this is only for <a href="Eruby.html">Eruby</a>.
|
|
112
112
|
<div id="methods">
|
113
113
|
<h3 class="section-bar">Public Instance methods</h3>
|
114
114
|
|
115
|
-
<div id="method-
|
116
|
-
<a name="
|
115
|
+
<div id="method-M000064" class="method-detail">
|
116
|
+
<a name="M000064"></a>
|
117
117
|
|
118
118
|
<div class="method-heading">
|
119
|
-
<a href="#
|
119
|
+
<a href="#M000064" class="method-signature">
|
120
120
|
<span class="method-name">add_postamble</span><span class="method-args">(src)</span>
|
121
121
|
</a>
|
122
122
|
</div>
|
123
123
|
|
124
124
|
<div class="method-description">
|
125
125
|
<p><a class="source-toggle" href="#"
|
126
|
-
onclick="toggleCode('
|
127
|
-
<div class="method-source-code" id="
|
126
|
+
onclick="toggleCode('M000064-source');return false;">[Source]</a></p>
|
127
|
+
<div class="method-source-code" id="M000064-source">
|
128
128
|
<pre>
|
129
129
|
<span class="ruby-comment cmt"># File erubis/enhancer.rb, line 74</span>
|
130
130
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_postamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -135,19 +135,19 @@ this is only for <a href="Eruby.html">Eruby</a>.
|
|
135
135
|
</div>
|
136
136
|
</div>
|
137
137
|
|
138
|
-
<div id="method-
|
139
|
-
<a name="
|
138
|
+
<div id="method-M000063" class="method-detail">
|
139
|
+
<a name="M000063"></a>
|
140
140
|
|
141
141
|
<div class="method-heading">
|
142
|
-
<a href="#
|
142
|
+
<a href="#M000063" class="method-signature">
|
143
143
|
<span class="method-name">add_preamble</span><span class="method-args">(src)</span>
|
144
144
|
</a>
|
145
145
|
</div>
|
146
146
|
|
147
147
|
<div class="method-description">
|
148
148
|
<p><a class="source-toggle" href="#"
|
149
|
-
onclick="toggleCode('
|
150
|
-
<div class="method-source-code" id="
|
149
|
+
onclick="toggleCode('M000063-source');return false;">[Source]</a></p>
|
150
|
+
<div class="method-source-code" id="M000063-source">
|
151
151
|
<pre>
|
152
152
|
<span class="ruby-comment cmt"># File erubis/enhancer.rb, line 70</span>
|
153
153
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_preamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -89,8 +89,8 @@ this is only for <a href="Eruby.html">Eruby</a>.
|
|
89
89
|
<h3 class="section-bar">Methods</h3>
|
90
90
|
|
91
91
|
<div class="name-list">
|
92
|
-
<a href="#
|
93
|
-
<a href="#
|
92
|
+
<a href="#M000160">add_postamble</a>
|
93
|
+
<a href="#M000159">add_preamble</a>
|
94
94
|
</div>
|
95
95
|
</div>
|
96
96
|
|
@@ -112,19 +112,19 @@ this is only for <a href="Eruby.html">Eruby</a>.
|
|
112
112
|
<div id="methods">
|
113
113
|
<h3 class="section-bar">Public Instance methods</h3>
|
114
114
|
|
115
|
-
<div id="method-
|
116
|
-
<a name="
|
115
|
+
<div id="method-M000160" class="method-detail">
|
116
|
+
<a name="M000160"></a>
|
117
117
|
|
118
118
|
<div class="method-heading">
|
119
|
-
<a href="#
|
119
|
+
<a href="#M000160" class="method-signature">
|
120
120
|
<span class="method-name">add_postamble</span><span class="method-args">(src)</span>
|
121
121
|
</a>
|
122
122
|
</div>
|
123
123
|
|
124
124
|
<div class="method-description">
|
125
125
|
<p><a class="source-toggle" href="#"
|
126
|
-
onclick="toggleCode('
|
127
|
-
<div class="method-source-code" id="
|
126
|
+
onclick="toggleCode('M000160-source');return false;">[Source]</a></p>
|
127
|
+
<div class="method-source-code" id="M000160-source">
|
128
128
|
<pre>
|
129
129
|
<span class="ruby-comment cmt"># File erubis/enhancer.rb, line 215</span>
|
130
130
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_postamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -136,19 +136,19 @@ this is only for <a href="Eruby.html">Eruby</a>.
|
|
136
136
|
</div>
|
137
137
|
</div>
|
138
138
|
|
139
|
-
<div id="method-
|
140
|
-
<a name="
|
139
|
+
<div id="method-M000159" class="method-detail">
|
140
|
+
<a name="M000159"></a>
|
141
141
|
|
142
142
|
<div class="method-heading">
|
143
|
-
<a href="#
|
143
|
+
<a href="#M000159" class="method-signature">
|
144
144
|
<span class="method-name">add_preamble</span><span class="method-args">(src)</span>
|
145
145
|
</a>
|
146
146
|
</div>
|
147
147
|
|
148
148
|
<div class="method-description">
|
149
149
|
<p><a class="source-toggle" href="#"
|
150
|
-
onclick="toggleCode('
|
151
|
-
<div class="method-source-code" id="
|
150
|
+
onclick="toggleCode('M000159-source');return false;">[Source]</a></p>
|
151
|
+
<div class="method-source-code" id="M000159-source">
|
152
152
|
<pre>
|
153
153
|
<span class="ruby-comment cmt"># File erubis/enhancer.rb, line 211</span>
|
154
154
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_preamble</span>(<span class="ruby-identifier">src</span>)
|
@@ -101,10 +101,10 @@ ex.
|
|
101
101
|
<h3 class="section-bar">Methods</h3>
|
102
102
|
|
103
103
|
<div class="name-list">
|
104
|
-
<a href="#
|
105
|
-
<a href="#
|
106
|
-
<a href="#
|
107
|
-
<a href="#
|
104
|
+
<a href="#M000162">convert</a>
|
105
|
+
<a href="#M000164">evaluate</a>
|
106
|
+
<a href="#M000161">new</a>
|
107
|
+
<a href="#M000163">result</a>
|
108
108
|
</div>
|
109
109
|
</div>
|
110
110
|
|
@@ -152,19 +152,19 @@ ex.
|
|
152
152
|
<div id="methods">
|
153
153
|
<h3 class="section-bar">Public Class methods</h3>
|
154
154
|
|
155
|
-
<div id="method-
|
156
|
-
<a name="
|
155
|
+
<div id="method-M000161" class="method-detail">
|
156
|
+
<a name="M000161"></a>
|
157
157
|
|
158
158
|
<div class="method-heading">
|
159
|
-
<a href="#
|
159
|
+
<a href="#M000161" class="method-signature">
|
160
160
|
<span class="method-name">new</span><span class="method-args">(input=nil)</span>
|
161
161
|
</a>
|
162
162
|
</div>
|
163
163
|
|
164
164
|
<div class="method-description">
|
165
165
|
<p><a class="source-toggle" href="#"
|
166
|
-
onclick="toggleCode('
|
167
|
-
<div class="method-source-code" id="
|
166
|
+
onclick="toggleCode('M000161-source');return false;">[Source]</a></p>
|
167
|
+
<div class="method-source-code" id="M000161-source">
|
168
168
|
<pre>
|
169
169
|
<span class="ruby-comment cmt"># File erubis/tiny.rb, line 20</span>
|
170
170
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">input</span>=<span class="ruby-keyword kw">nil</span>)
|
@@ -177,19 +177,19 @@ ex.
|
|
177
177
|
|
178
178
|
<h3 class="section-bar">Public Instance methods</h3>
|
179
179
|
|
180
|
-
<div id="method-
|
181
|
-
<a name="
|
180
|
+
<div id="method-M000162" class="method-detail">
|
181
|
+
<a name="M000162"></a>
|
182
182
|
|
183
183
|
<div class="method-heading">
|
184
|
-
<a href="#
|
184
|
+
<a href="#M000162" class="method-signature">
|
185
185
|
<span class="method-name">convert</span><span class="method-args">(input)</span>
|
186
186
|
</a>
|
187
187
|
</div>
|
188
188
|
|
189
189
|
<div class="method-description">
|
190
190
|
<p><a class="source-toggle" href="#"
|
191
|
-
onclick="toggleCode('
|
192
|
-
<div class="method-source-code" id="
|
191
|
+
onclick="toggleCode('M000162-source');return false;">[Source]</a></p>
|
192
|
+
<div class="method-source-code" id="M000162-source">
|
193
193
|
<pre>
|
194
194
|
<span class="ruby-comment cmt"># File erubis/tiny.rb, line 27</span>
|
195
195
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">convert</span>(<span class="ruby-identifier">input</span>)
|
@@ -223,19 +223,19 @@ ex.
|
|
223
223
|
</div>
|
224
224
|
</div>
|
225
225
|
|
226
|
-
<div id="method-
|
227
|
-
<a name="
|
226
|
+
<div id="method-M000164" class="method-detail">
|
227
|
+
<a name="M000164"></a>
|
228
228
|
|
229
229
|
<div class="method-heading">
|
230
|
-
<a href="#
|
230
|
+
<a href="#M000164" class="method-signature">
|
231
231
|
<span class="method-name">evaluate</span><span class="method-args">(_context=Object.new)</span>
|
232
232
|
</a>
|
233
233
|
</div>
|
234
234
|
|
235
235
|
<div class="method-description">
|
236
236
|
<p><a class="source-toggle" href="#"
|
237
|
-
onclick="toggleCode('
|
238
|
-
<div class="method-source-code" id="
|
237
|
+
onclick="toggleCode('M000164-source');return false;">[Source]</a></p>
|
238
|
+
<div class="method-source-code" id="M000164-source">
|
239
239
|
<pre>
|
240
240
|
<span class="ruby-comment cmt"># File erubis/tiny.rb, line 62</span>
|
241
241
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">evaluate</span>(<span class="ruby-identifier">_context</span>=<span class="ruby-constant">Object</span>.<span class="ruby-identifier">new</span>)
|
@@ -251,11 +251,11 @@ ex.
|
|
251
251
|
</div>
|
252
252
|
</div>
|
253
253
|
|
254
|
-
<div id="method-
|
255
|
-
<a name="
|
254
|
+
<div id="method-M000163" class="method-detail">
|
255
|
+
<a name="M000163"></a>
|
256
256
|
|
257
257
|
<div class="method-heading">
|
258
|
-
<a href="#
|
258
|
+
<a href="#M000163" class="method-signature">
|
259
259
|
<span class="method-name">result</span><span class="method-args">(_binding=TOPLEVEL_BINDING)</span>
|
260
260
|
</a>
|
261
261
|
</div>
|
@@ -271,8 +271,8 @@ def escape_text(text)
|
|
271
271
|
end
|
272
272
|
</p>
|
273
273
|
<p><a class="source-toggle" href="#"
|
274
|
-
onclick="toggleCode('
|
275
|
-
<div class="method-source-code" id="
|
274
|
+
onclick="toggleCode('M000163-source');return false;">[Source]</a></p>
|
275
|
+
<div class="method-source-code" id="M000163-source">
|
276
276
|
<pre>
|
277
277
|
<span class="ruby-comment cmt"># File erubis/tiny.rb, line 58</span>
|
278
278
|
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">result</span>(<span class="ruby-identifier">_binding</span>=<span class="ruby-constant">TOPLEVEL_BINDING</span>)
|