org.apache.tiles.factory
Class AbstractTilesContainerFactory

Package class diagram package AbstractTilesContainerFactory
java.lang.Object
  extended by org.apache.tiles.factory.AbstractTilesContainerFactory
Direct Known Subclasses:
BasicTilesContainerFactory, TilesContainerFactory

public abstract class AbstractTilesContainerFactory
extends java.lang.Object

Abstract Factory that creates instances of TilesContainerFactory.

Since:
2.1.0

Field Summary
static java.lang.String CONTAINER_FACTORY_INIT_PARAM
          Initialization parameter that represents the container factory class name.
 
Constructor Summary
AbstractTilesContainerFactory()
           
 
Method Summary
abstract  TilesContainer createContainer(java.lang.Object context)
          Creates a Tiles container.
protected static java.lang.String getInitParameter(java.lang.Object context, java.lang.String parameterName)
          Returns the value of an initialization parameter.
protected static java.util.Map<java.lang.String,java.lang.String> getInitParameterMap(java.lang.Object context)
          Returns a map containing parameters name-value entries.
static AbstractTilesContainerFactory getTilesContainerFactory(java.lang.Object context)
          Creates a factory instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTAINER_FACTORY_INIT_PARAM

public static final java.lang.String CONTAINER_FACTORY_INIT_PARAM
Initialization parameter that represents the container factory class name.

Since:
2.1.0
See Also:
Constant Field Values
Constructor Detail

AbstractTilesContainerFactory

public AbstractTilesContainerFactory()
Method Detail

getTilesContainerFactory

public static AbstractTilesContainerFactory getTilesContainerFactory(java.lang.Object context)
Creates a factory instance.

Parameters:
context - The application context object.
Returns:
The created factory.
Throws:
TilesContainerFactoryException - If something goes wrong during creation.
Since:
2.1.0

createContainer

public abstract TilesContainer createContainer(java.lang.Object context)
Creates a Tiles container.

Parameters:
context - The (application) context object.
Returns:
The created container.
Throws:
TilesContainerFactoryException - If something goes wrong during instantiation.
Since:
2.1.0

getInitParameterMap

protected static java.util.Map<java.lang.String,java.lang.String> getInitParameterMap(java.lang.Object context)
Returns a map containing parameters name-value entries.

Parameters:
context - The (application) context object to use.
Returns:
The initialization parameters map.
Throws:
TilesContainerFactoryException - If the context object has not been recognized.
Since:
2.1.0

getInitParameter

protected static java.lang.String getInitParameter(java.lang.Object context,
                                                   java.lang.String parameterName)
Returns the value of an initialization parameter.

Parameters:
context - The (application) context object to use.
parameterName - The parameter name to retrieve.
Returns:
The parameter value.
Throws:
TilesContainerFactoryException - If the context has not been recognized.
Since:
2.1.0