org.springframework.web.servlet.view.tiles
Class TilesConfigurer

org.springframework.context.support.ApplicationObjectSupport
  |
  +--org.springframework.web.context.support.WebApplicationObjectSupport
        |
        +--org.springframework.web.servlet.view.tiles.TilesConfigurer

public class TilesConfigurer
extends WebApplicationObjectSupport

Helper class to configure Tiles for the Spring Framework (see http://jakarta.apache.org/struts for more information about Tiles, which basically is a templating mechanism for JSP-based web applications).

The TilesConfigurer simply configures tiles using a set of files containing definitions. The rest is done by an appropriate Resolver which could for instance be the org.springframework.web.servlet.view.InternalResourceViewResolver InternalResourceViewResolver or the org.springframework.web.servlet.view.ResourceBundleViewResolver ResourceBundleViewResolver. Usage of the TilesConfigurer is done as follows:

<bean id="tilesConfigurer" class="org.springframework.web.servlet.view.tiles.TilesConfigurer">
<property name="definitions">
<list>
<value>/WEB-INF/defs/general.xml</value>
<value>/WEB-INF/defs/widgets.xml</value>
<value>/WEB-INF/defs/administrator.xml</value>
<value>/WEB-INF/defs/customer.xml</value>
<value>/WEB-INF/defs/templates.xml</value>
</list>
</property>
</bean>

The values in the list are the actual files containing the definitions.

Author:
Alef Arendsen, Juergen Hoeller
See Also: TilesView

Method Summary
 voidsetDefinitions(String[] definitions)
          Set the Tiles definitions, i.e.
 voidsetFactoryClass(Class factoryClass)
          Set the factory class for Tiles.
 voidsetValidateDefinitions(boolean validateDefinitions)
          Validate the Tiles definitions? Default is false.

Methods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, setApplicationContext

Method Detail

setDefinitions

public void setDefinitions(String[] definitions)
Set the Tiles definitions, i.e. the list of files.
Parameters:
definitions - the files containing the definitions

setFactoryClass

public void setFactoryClass(Class factoryClass)
Set the factory class for Tiles. Default is I18nFactorySet.
See Also:
org.apache.struts.tiles.xmlDefinition.I18nFactorySet

setValidateDefinitions

public void setValidateDefinitions(boolean validateDefinitions)
Validate the Tiles definitions? Default is false.
Parameters:
validateDefinitions - true to validate, false otherwise

Association Links

to Class java.lang.Class

factory class for Tiles

to Class java.lang.String

definition URLs mapped to descriptions