Class BasicPreparerFactory
- java.lang.Object
-
- org.apache.tiles.preparer.factory.BasicPreparerFactory
-
- All Implemented Interfaces:
PreparerFactory
- Direct Known Subclasses:
CompatibilityPreparerFactory
public class BasicPreparerFactory extends java.lang.Object implements PreparerFactory
Default implementation of thePreparerFactory
. This factory provides no contextual configuration. It simply instantiates the named preparerInstance and returns it.- Since:
- Tiles 2.0
- Version:
- $Rev: 1310865 $ $Date: 2012-04-08 07:01:22 +1000 (Sun, 08 Apr 2012) $
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Map<java.lang.String,ViewPreparer>
preparers
Maps a preparer name to the instantiated preparer.
-
Constructor Summary
Constructors Constructor Description BasicPreparerFactory()
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ViewPreparer
createPreparer(java.lang.String name)
Creates a view preparer for the given name.ViewPreparer
getPreparer(java.lang.String name, org.apache.tiles.request.Request context)
Create a new instance of the named preparerInstance.
-
-
-
Field Detail
-
preparers
protected java.util.Map<java.lang.String,ViewPreparer> preparers
Maps a preparer name to the instantiated preparer.
-
-
Method Detail
-
getPreparer
public ViewPreparer getPreparer(java.lang.String name, org.apache.tiles.request.Request context)
Create a new instance of the named preparerInstance. This factory expects all names to be qualified class names.- Specified by:
getPreparer
in interfacePreparerFactory
- Parameters:
name
- the named preparerInstancecontext
- current context- Returns:
- ViewPreparer instance
-
createPreparer
protected ViewPreparer createPreparer(java.lang.String name)
Creates a view preparer for the given name.- Parameters:
name
- The name of the preparer.- Returns:
- The created preparer.
-
-