Author: cbrisson
Date: Mon Jul 18 21:47:56 2016
New Revision: 1753321
URL: http://svn.apache.org/viewvc?rev=1753321&view=rev
Log:
[site] same in prod
Modified:
velocity/site/production/engine/devel/changes.html
velocity/site/production/engine/devel/developer-guide.html
Modified: velocity/site/production/engine/devel/changes.html
URL:
http://svn.apache.org/viewvc/velocity/site/production/engine/devel/changes.html?rev=1753321&r1=1753320&r2=1753321&view=diff
==============================================================================
--- velocity/site/production/engine/devel/changes.html (original)
+++ velocity/site/production/engine/devel/changes.html Mon Jul 18 21:47:56 2016
@@ -316,6 +316,13 @@ h2:hover > .headerlink, h3:hover > .head
<td>
<img src="images/add.png"/>
</td>
+ <td> The new configuration property context.autoreference.key, if
present, allows to specify the name of the reference under which the context is
accessible in itself . Fixes <a
href="https://issues.apache.org/jira/browse/VELOCITY-799">VELOCITY-799</a>.
</td>
+ <td>cbrisson</td>
+ </tr>
+ <tr>
+ <td>
+ <img src="images/add.png"/>
+ </td>
<td> MethodExceptionEventHandler now provide template location infos .
Fixes <a
href="https://issues.apache.org/jira/browse/VELOCITY-746">VELOCITY-746</a>.
</td>
<td>cbrisson</td>
</tr>
Modified: velocity/site/production/engine/devel/developer-guide.html
URL:
http://svn.apache.org/viewvc/velocity/site/production/engine/devel/developer-guide.html?rev=1753321&r1=1753320&r2=1753321&view=diff
==============================================================================
--- velocity/site/production/engine/devel/developer-guide.html (original)
+++ velocity/site/production/engine/devel/developer-guide.html Mon Jul 18
21:47:56 2016
@@ -283,6 +283,7 @@ h2:hover > .headerlink, h3:hover > .head
<li><a href="#math">Math</a></li>
<li><a href="#parser-configuration">Parser Configuration</a></li>
<li><a href="#pluggable-introspection">Pluggable Introspection</a></li>
+<li><a href="#context">Context</a></li>
</ul>
</li>
<li><a href="#configuring-logging">Configuring Logging</a></li>
@@ -1036,8 +1037,8 @@ eventhandler.escape.sql.match = /sql.*/
<p><code><name>.resource.loader.modificationCheckInterval = 2</code></p>
<blockquote>
<p>This is the number of seconds between modification checks when caching is
turned on. When this is an integer > 0, this represents the number of
seconds between checks to see if the template was modified. If the template
has been modified since last check, then it is reloaded and reparsed.
Otherwise nothing is done. When <= 0, no modification checks will take
place, and assuming that the property <code>cache</code> (above) is true, once
a template is loaded and parsed the first time it is used, it will not be
checked or reloaded after that until the application or servlet engine is
restarted.</p>
-</blockquote>
<p>To illustrate, here is an example taken right from the default Velocity
properties, showing how setting up the FileResourceLoader is managed</p>
+</blockquote>
<div class="codehilite"><pre>resource.loader = file
file.resource.loader.description = Velocity File Resource Loader
@@ -1117,8 +1118,15 @@ file.resource.loader.modificationCheckIn
</blockquote>
<h3 id="pluggable-introspection">Pluggable Introspection<a class="headerlink"
href="#pluggable-introspection" title="Permanent link">¶</a></h3>
<p><code>runtime.introspector.uberspect =
org.apache.velocity.util.introspection.UberspectImpl</code></p>
+<blockquote>
<p>This property sets the 'Uberspector', the introspection package that
handles all introspection strategies for Velocity. You can specify a
comma-separated list of Uberspector classes, in which case all Uberspectors are
chained. The default chaining behaviour is to return the first non-null value
for each introspection call among all provided uberspectors. You can modify
this behaviour (for instance to restrict access to some methods) by subclassing
org.apache.velocity.util.introspection.AbstractChainableUberspector (or
implementing directly
org.apache.velocity.util.introspection.ChainableUberspector). This allows you
to create more interesting rules or patterns for Uberspection, rather than just
returning the first non-null value.</p>
<p>Some alternate Uberspectors are provided. You would for instance use
<code>runtime.introspector.uberspect =
org.apache.velocity.util.introspection.SecureUberspector</code> to avoid
template authors to instanciate new classes or to use reflection, or use
<code>runtime.introspector.uberspect =
org.apache.velocity.util.introspection.UberspectImpl,
org.apache.velocity.util.introspection.UberspectPublicFields</code> to expose
Java public fields in your templates.</p>
+</blockquote>
+<h3 id="context">Context<a class="headerlink" href="#context" title="Permanent
link">¶</a></h3>
+<p><code>context.autoreference.key = *name*</code></p>
+<blockquote>
+<p>This property has no default value. If present, the Context object will
become accessible from the templates under the provided name. For instance,
with the configuration <code>context.autoreference.key = self</code>,
<code>$self</code> will contain the context itself. This feature is meant to be
used for debugging purposes.</p>
+</blockquote>
<h2 id="configuring-logging">Configuring Logging<a class="headerlink"
href="#configuring-logging" title="Permanent link">¶</a></h2>
<p>Since version 2.0, Velocity has switched to the <a
href="http://www.slf4j.org/">SLF4J</a> logging facade.</p>
<p>All you have to do to enable logging is to make sure that your classpath
contains the slf4j-api jar, and one and only one slf4j binding jar towards your
favourite logsystem or facade. See the <a href="#dependencies">dependecies</a>
section for a list of SLF4J bindings.</p>