org.apache.struts.tiles
Class TilesUtilImpl
java.lang.Object
org.apache.struts.tiles.TilesUtilImpl
- Serializable
public class TilesUtilImpl
extends java.lang.Object
implements Serializable
Default implementation of TilesUtil.
This class contains default implementation of utilities. This implementation
is intended to be used without Struts.
static String | DEFINITIONS_FACTORY - Constant name used to store factory in servlet context
|
protected Log | log - Commons Logging instance.
|
protected DefinitionsFactory | createDefinitionFactoryInstance(String classname) - Create Definition factory of specified classname.
|
DefinitionsFactory | createDefinitionsFactory(ServletContext servletContext, DefinitionsFactoryConfig factoryConfig) - Create Definition factory from specified configuration object.
|
void | doForward(String uri, HttpServletRequest request, HttpServletResponse response, ServletContext servletContext) - Do a forward using request dispatcher.
|
void | doInclude(String uri, HttpServletRequest request, HttpServletResponse response, ServletContext servletContext) - Do an include using request dispatcher.
|
void | doInclude(String uri, PageContext pageContext) - Do an include using PageContext.include().
|
DefinitionsFactory | getDefinitionsFactory(ServletRequest request, ServletContext servletContext) - Get definition factory from appropriate servlet context.
|
protected void | makeDefinitionsFactoryAccessible(DefinitionsFactory factory, ServletContext servletContext) - Make definition factory accessible to Tags.
|
DEFINITIONS_FACTORY
public static final String DEFINITIONS_FACTORY
Constant name used to store factory in servlet context
log
protected Log log
Commons Logging instance.
createDefinitionsFactory
public DefinitionsFactory createDefinitionsFactory(ServletContext servletContext,
DefinitionsFactoryConfig factoryConfig)
throws DefinitionsFactoryException
servletContext
- Servlet Context passed to newly created factory.factoryConfig
- Configuration object passed to factory.
- newly created factory of type specified in the config object.
doForward
public void doForward(String uri,
HttpServletRequest request,
HttpServletResponse response,
ServletContext servletContext)
throws IOException,
ServletException
Do a forward using request dispatcher.
This method is used by the Tiles package anytime a forward is required.
uri
- Uri or Definition name to forward.request
- Current page request.servletContext
- Current servlet context.
doInclude
public void doInclude(String uri,
HttpServletRequest request,
HttpServletResponse response,
ServletContext servletContext)
throws IOException,
ServletException
Do an include using request dispatcher.
This method is used by the Tiles package when an include is required.
The Tiles package can use indifferently any form of this method.
uri
- Uri or Definition name to forward.request
- Current page request.response
- Current page response.servletContext
- Current servlet context.
doInclude
public void doInclude(String uri,
PageContext pageContext)
throws IOException,
ServletException
Do an include using PageContext.include().
This method is used by the Tiles package when an include is required.
The Tiles package can use indifferently any form of this method.
uri
- Uri or Definition name to forward.pageContext
- Current page context.
getDefinitionsFactory
public DefinitionsFactory getDefinitionsFactory(ServletRequest request,
ServletContext servletContext)
Get definition factory from appropriate servlet context.
- Definitions factory or
null
if not found.
makeDefinitionsFactoryAccessible
protected void makeDefinitionsFactoryAccessible(DefinitionsFactory factory,
ServletContext servletContext)
Make definition factory accessible to Tags.
Factory is stored in servlet context.
factory
- Factory to be made accessible.servletContext
- Current servlet context.
Copyright B) 2000-2007 - The Apache Software Foundation