org.apache.tiles.jsp.context
Class JspTilesRequestContext

java.lang.Object
  extended by org.apache.tiles.context.TilesRequestContextWrapper
      extended by org.apache.tiles.jsp.context.JspTilesRequestContext
All Implemented Interfaces:
TilesRequestContext

public class JspTilesRequestContext
extends TilesRequestContextWrapper
implements TilesRequestContext

Context implementation used for executing tiles within a jsp tag library.

Version:
$Rev: 736275 $ $Date: 2009-01-21 10:58:20 +0100 (mer, 21 gen 2009) $

Constructor Summary
JspTilesRequestContext(javax.servlet.ServletContext context, javax.servlet.jsp.PageContext pageContext)
          Deprecated. Use JspTilesRequestContext(TilesRequestContext, PageContext).
JspTilesRequestContext(TilesRequestContext enclosedRequest, javax.servlet.jsp.PageContext pageContext)
          Constructor.
 
Method Summary
 void dispatch(java.lang.String path)
          Dispatches a path.
 javax.servlet.jsp.PageContext getPageContext()
          Returns the page context that originated the request.
 java.io.PrintWriter getPrintWriter()
          
 java.lang.Object[] getRequestObjects()
          
 javax.servlet.http.HttpServletResponse getResponse()
          Deprecated. Use getPageContext() or getPrintWriter().
 java.io.Writer getWriter()
          
 void include(java.lang.String path)
          
 
Methods inherited from class org.apache.tiles.context.TilesRequestContextWrapper
getApplicationContext, getHeader, getHeaderValues, getOutputStream, getParam, getParamValues, getRequest, getRequestLocale, getRequestScope, getSessionScope, getWrappedRequest, isResponseCommitted, isUserInRole, setContentType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.tiles.context.TilesRequestContext
getApplicationContext, getHeader, getHeaderValues, getOutputStream, getParam, getParamValues, getRequest, getRequestLocale, getRequestScope, getSessionScope, isResponseCommitted, isUserInRole, setContentType
 

Constructor Detail

JspTilesRequestContext

public JspTilesRequestContext(TilesRequestContext enclosedRequest,
                              javax.servlet.jsp.PageContext pageContext)
Constructor.

Parameters:
enclosedRequest - The request that is wrapped here.
pageContext - The page context to use.

JspTilesRequestContext

@Deprecated
public JspTilesRequestContext(javax.servlet.ServletContext context,
                                         javax.servlet.jsp.PageContext pageContext)
Deprecated. Use JspTilesRequestContext(TilesRequestContext, PageContext).

Constructor.

Parameters:
context - The servlet context to use.
pageContext - The page context to use.
Method Detail

dispatch

public void dispatch(java.lang.String path)
              throws java.io.IOException
Dispatches a path. In fact it "includes" it!

Specified by:
dispatch in interface TilesRequestContext
Overrides:
dispatch in class TilesRequestContextWrapper
Parameters:
path - The path to dispatch to.
Throws:
java.io.IOException - If something goes wrong during dispatching.
See Also:
ServletTilesRequestContext.dispatch(java.lang.String)

include

public void include(java.lang.String path)
             throws java.io.IOException

Specified by:
include in interface TilesRequestContext
Overrides:
include in class TilesRequestContextWrapper
Throws:
java.io.IOException

getPrintWriter

public java.io.PrintWriter getPrintWriter()
                                   throws java.io.IOException

Specified by:
getPrintWriter in interface TilesRequestContext
Overrides:
getPrintWriter in class TilesRequestContextWrapper
Throws:
java.io.IOException

getWriter

public java.io.Writer getWriter()
                         throws java.io.IOException

Specified by:
getWriter in interface TilesRequestContext
Overrides:
getWriter in class TilesRequestContextWrapper
Throws:
java.io.IOException

getRequestObjects

public java.lang.Object[] getRequestObjects()

Specified by:
getRequestObjects in interface TilesRequestContext
Overrides:
getRequestObjects in class TilesRequestContextWrapper

getPageContext

public javax.servlet.jsp.PageContext getPageContext()
Returns the page context that originated the request.

Returns:
The page context.

getResponse

@Deprecated
public javax.servlet.http.HttpServletResponse getResponse()
Deprecated. Use getPageContext() or getPrintWriter().

Returns the response object, obtained by the JSP page context. The print writer will use the object obtained by JspContext.getOut().

Specified by:
getResponse in interface TilesRequestContext
Overrides:
getResponse in class TilesRequestContextWrapper
Returns:
The response object.


Copyright © 2001-2010 Apache Software Foundation. All Rights Reserved.