|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.struts.tiles.TilesUtilImpl
public class TilesUtilImpl
Default implementation of TilesUtil. This class contains default implementation of utilities. This implementation is intended to be used without Struts.
Field Summary | |
---|---|
static String |
DEFINITIONS_FACTORY
Constant name used to store factory in servlet context |
protected static Log |
log
Commons Logging instance. |
Constructor Summary | |
---|---|
TilesUtilImpl()
|
Method Summary | |
---|---|
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,
boolean flush)
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. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final Log log
public static final String DEFINITIONS_FACTORY
Constructor Detail |
---|
public TilesUtilImpl()
Method Detail |
---|
public void doForward(String uri, HttpServletRequest request, HttpServletResponse response, ServletContext servletContext) throws IOException, ServletException
uri
- Uri or Definition name to forward.request
- Current page request.servletContext
- Current servlet context.
IOException
ServletException
public void doInclude(String uri, HttpServletRequest request, HttpServletResponse response, ServletContext servletContext) throws IOException, ServletException
uri
- Uri or Definition name to forward.request
- Current page request.response
- Current page response.servletContext
- Current servlet context.
IOException
ServletException
public void doInclude(String uri, PageContext pageContext, boolean flush) throws IOException, ServletException
uri
- Uri or Definition name to forward.pageContext
- Current page context.flush
- If the writer should be flushed before the include
IOException
ServletException
public DefinitionsFactory getDefinitionsFactory(ServletRequest request, ServletContext servletContext)
null
if not found.public DefinitionsFactory createDefinitionsFactory(ServletContext servletContext, DefinitionsFactoryConfig factoryConfig) throws DefinitionsFactoryException
makeDefinitionsFactoryAccessible(DefinitionsFactory, ServletContext)
.
Factory creation is done by createDefinitionFactoryInstance(String)
.
servletContext
- Servlet Context passed to newly created factory.factoryConfig
- Configuration object passed to factory.
DefinitionsFactoryException
- If an error occur while initializing factoryprotected DefinitionsFactory createDefinitionFactoryInstance(String classname) throws DefinitionsFactoryException
DefinitionsFactory
class.
The factory is wrapped appropriately with ComponentDefinitionsFactoryWrapper
if it is an instance of the deprecated ComponentDefinitionsFactory class.
classname
- Class name of the factory to create.
DefinitionsFactoryException
- If an error occur while initializing factoryprotected void makeDefinitionsFactoryAccessible(DefinitionsFactory factory, ServletContext servletContext)
factory
- Factory to be made accessible.servletContext
- Current servlet context.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |