Author: buildbot
Date: Sat Jul 5 15:19:36 2014
New Revision: 915098
Log:
Production update by buildbot for tapestry
Modified:
websites/production/tapestry/content/cache/main.pageCache
websites/production/tapestry/content/starting-the-ioc-registry.html
Modified: websites/production/tapestry/content/cache/main.pageCache
==============================================================================
Binary files - no diff available.
Modified: websites/production/tapestry/content/starting-the-ioc-registry.html
==============================================================================
--- websites/production/tapestry/content/starting-the-ioc-registry.html
(original)
+++ websites/production/tapestry/content/starting-the-ioc-registry.html Sat Jul
5 15:19:36 2014
@@ -77,36 +77,15 @@ table.ScrollbarTable td.ScrollbarParent
table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width:
16px;border: none;}
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td
colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect"
href="typecoercer-service.html"><img align="middle" border="0"
src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16"
height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName"
width="33%"><a shape="rect" href="typecoercer-service.html">TypeCoercer
Service</a> </td><td colspan="1" rowspan="1" class="ScrollbarParent"
width="33%"><sup><a shape="rect" href="ioc.html"><img align="middle" border="0"
src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8"
height="8"></a></sup><a shape="rect" href="ioc.html">IoC</a></td><td
colspan="1" rowspan="1" class="ScrollbarNextName" width="33%"> <a
shape="rect" href="registry-startup.html">Registry Startup</a></td><td
colspan="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect"
href="registry-startup.html"><img align="middle" border="0" s
rc="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16"
height="16"></a></td></tr></table></div>
-
-<h1 id="StartingtheIoCRegistry-StartingtheTapestryIoCRegistry">Starting the
Tapestry IoC Registry</h1>
-
-<p>Primarily, you will use the IoC Registry as part of a Tapestry application.
In those situations, the <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/TapestryFilter.html">TapestryFilter</a>
will be responsible for starting and stopping the registry.</p>
-
-<p>However, you may want to do some integration testing using the Registry
from within a test case, or you may even use Tapestry IoC separately from
Tapestry.</p>
-
-<h1 id="StartingtheIoCRegistry-BuildingtheRegistry">Building the Registry</h1>
-
-<p>The class <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/RegistryBuilder.html">RegistryBuilder</a>
is used to create a Registry.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent
panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false"
type="syntaxhighlighter"><![CDATA[
-RegistryBuilder builder = new RegistryBuilder();
+/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td
colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect"
href="typecoercer-service.html"><img align="middle" border="0"
src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16"
height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName"
width="33%"><a shape="rect" href="typecoercer-service.html">TypeCoercer
Service</a> </td><td colspan="1" rowspan="1" class="ScrollbarParent"
width="33%"><sup><a shape="rect" href="ioc.html"><img align="middle" border="0"
src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8"
height="8"></a></sup><a shape="rect" href="ioc.html">IoC</a></td><td
colspan="1" rowspan="1" class="ScrollbarNextName" width="33%"> <a
shape="rect" href="registry-startup.html">Registry Startup</a></td><td
colspan="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect"
href="registry-startup.html"><img align="middle" border="0" s
rc="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16"
height="16"></a></td></tr></table></div><h1
id="StartingtheIoCRegistry-StartingtheTapestryIoCRegistry">Starting the
Tapestry IoC Registry</h1><p>Primarily, you will use the IoC Registry as part
of a Tapestry application. In those situations, the <a shape="rect"
class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/TapestryFilter.html">TapestryFilter</a>
will be responsible for starting and stopping the registry.</p><p>However, you
may want to do some integration testing using the Registry from within a test
case, or you may even use Tapestry IoC separately from Tapestry.</p><h1
id="StartingtheIoCRegistry-BuildingtheRegistry">Building the
Registry</h1><p>The class <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/RegistryBuilder.html">RegistryBuilder</a>
is used to create a Registry.</p><div class="code panel
pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false"
type="syntaxhighlighter"><![CDATA[RegistryBuilder builder = new
RegistryBuilder();
builder.add(AppModule.class, UtilModule.class);
Registry registry = builder.build();
registry.performRegistryStartup();]]></script>
-</div></div>
-
-<p>You may invoke add() as many times as you wish, or pass as many module
classes as you wish.</p>
-
-<p>Using this approach, you will form a Registry containing the built-in
services from the <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/services/TapestryIoCModule.html">Tapestry
IoC module</a>, plus the modules you explicitly list.</p>
-
-<p>The call to performRegistryStartup() is necessary to ensure that any
services marked with the <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/annotations/EagerLoad.html">EagerLoad</a>
annotation are, in fact, loaded.</p>
-
-
+</div></div><p>You may invoke add() as many times as you wish, or pass as many
module classes as you wish.</p><p>Using this approach, you will form a Registry
containing the built-in services from the <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/services/TapestryIoCModule.html">Tapestry
IoC module</a>, plus the modules you explicitly list.</p><p>The call to
performRegistryStartup() is necessary to ensure that any services marked with
the <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/annotations/EagerLoad.html">EagerLoad</a>
annotation are, in fact, loaded.</p>
<div class="aui-message hint shadowed information-macro">
<p class="title">Added in 5.2</p>
@@ -118,29 +97,10 @@ registry.performRegistryStartup();]]></s
</div>
<div style="border-right: 20px solid #D8E4F1;border-left: 20px solid #D8E4F1;">
-</div>
-
-<p>As of version 5.2 the class <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/RegistryBuilder.html">RegistryBuilder</a>
has convenience methods to build and start a Registry. The static method <a
shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/RegistryBuilder.html#buildAndStartupRegistry(java.lang.Class...)">RegistryBuilder.buildAndStartupRegistry(Class...)</a>
constructs a registry, adds a number of modules to the registry and performs
registry startup. The returned registry is ready to use.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent
panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false"
type="syntaxhighlighter"><![CDATA[
-Registry registry = RegistryBuilder.buildAndStartupRegistry(AppModule.class,
UtilModule.class);
+<p> </p></div><p>As of version 5.2 the class <a shape="rect"
class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/RegistryBuilder.html">RegistryBuilder</a>
has convenience methods to build and start a Registry. The static method <a
shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/RegistryBuilder.html#buildAndStartupRegistry(java.lang.Class...)">RegistryBuilder.buildAndStartupRegistry(Class...)</a>
constructs a registry, adds a number of modules to the registry and performs
registry startup. The returned registry is ready to use.</p><div class="code
panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false"
type="syntaxhighlighter"><![CDATA[Registry registry =
RegistryBuilder.buildAndStartupRegistry(AppModule.class, UtilModule.class);
]]></script>
-</div></div>
-
-<h1 id="StartingtheIoCRegistry-BuildingtheDefaultRegistry">Building the
Default Registry</h1>
-
-<p>The default registry is available by invoking the static method <a
shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/IOCUtilities.html#buildDefaultRegistry">IOCUtilities.buildDefaultRegistry()</a>.
This method builds a Registry using <a shape="rect"
href="autoloading-modules.html">autoloading logic</a>, where modules to load
are identified via a JAR Manifest entry.</p>
-
-<p>In addition, the JVM system property <code>tapestry.modules</code> (if
specified) is a list of additional module classes to load. This is often used
in development, where tests may be executed against the local classes, not
JARs, and so there no manifest to read.</p>
-
-<h1 id="StartingtheIoCRegistry-ShuttingdowntheRegistry">Shutting down the
Registry</h1>
-
-<p>The method <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/Registry.html#shutdown">Registry.shutdown()</a>
will shutdown the Registry. This immediately invalidates all service proxies.
Some services may have chosen to register for shutdown notification (for
example, to do cleanup work such as closing a database connection).</p>
-
-<p>Once the Registry is shutdown, it may not be used again: it will not be
possible to access services within the Registry, or invoke methods on services
previously acquired. All you can do is release the Registry to the garbage
collector.</p>
-
-<style type="text/css">/*<![CDATA[*/
+</div></div><h1
id="StartingtheIoCRegistry-BuildingtheDefaultRegistry">Building the Default
Registry</h1><p>The default registry is available by invoking the static method
<a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/IOCUtilities.html#buildDefaultRegistry">IOCUtilities.buildDefaultRegistry()</a>.
This method builds a Registry using <a shape="rect"
href="autoloading-modules.html">autoloading logic</a>, where modules to load
are identified via a JAR Manifest entry.</p><p>In addition, the JVM system
property <code>tapestry.modules</code> (if specified) is a list of additional
module classes to load. This is often used in development, where tests may be
executed against the local classes, not JARs, and so there is no manifest to
read.</p><h1 id="StartingtheIoCRegistry-ShuttingdowntheRegistry">Shutting down
the Registry</h1><p>The method <a shape="rect" class="external-link"
href="http://tapestry.apache.org/current/apidoc
s/org/apache/tapestry5/ioc/Registry.html#shutdown">Registry.shutdown()</a>
will shutdown the Registry. This immediately invalidates all service proxies.
Some services may have chosen to register for shutdown notification (for
example, to do cleanup work such as closing a database connection).</p><p>Once
the Registry is shutdown, it may not be used again: it will not be possible to
access services within the Registry, or invoke methods on services previously
acquired. All you can do is release the Registry to the garbage
collector.</p><style type="text/css">/*<![CDATA[*/
table.ScrollbarTable {border: none;padding: 3px;width: 100%;padding:
3px;margin: 0px;background-color: #f0f0f0}
table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width:
16px;border: none;}
table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}