org.glassfish.jersey.servlet.mvc.internal
Class RequestDispatcherWrapper

java.lang.Object
  extended by org.glassfish.jersey.servlet.mvc.internal.RequestDispatcherWrapper
All Implemented Interfaces:
javax.servlet.RequestDispatcher

public final class RequestDispatcherWrapper
extends Object
implements javax.servlet.RequestDispatcher

Request dispatcher wrapper for setting attributes (e.g. it).

Author:
Paul Sandoz (paul.sandoz at oracle.com), Michal Gajdos (michal.gajdos at oracle.com)

Field Summary
 
Fields inherited from interface javax.servlet.RequestDispatcher
ERROR_EXCEPTION, ERROR_EXCEPTION_TYPE, ERROR_MESSAGE, ERROR_REQUEST_URI, ERROR_SERVLET_NAME, ERROR_STATUS_CODE, FORWARD_CONTEXT_PATH, FORWARD_PATH_INFO, FORWARD_QUERY_STRING, FORWARD_REQUEST_URI, FORWARD_SERVLET_PATH, INCLUDE_CONTEXT_PATH, INCLUDE_PATH_INFO, INCLUDE_QUERY_STRING, INCLUDE_REQUEST_URI, INCLUDE_SERVLET_PATH
 
Constructor Summary
RequestDispatcherWrapper(javax.servlet.RequestDispatcher dispatcher, String basePath, HttpContext httpContext, Viewable viewable)
          Creates new RequestDispatcherWrapper responsible for setting request attributes and forwarding the processing to the given dispatcher.
 
Method Summary
 void forward(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
           
 void include(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RequestDispatcherWrapper

public RequestDispatcherWrapper(javax.servlet.RequestDispatcher dispatcher,
                                String basePath,
                                HttpContext httpContext,
                                Viewable viewable)
Creates new RequestDispatcherWrapper responsible for setting request attributes and forwarding the processing to the given dispatcher.

Parameters:
dispatcher - dispatcher processing the request after all the request attributes were set.
basePath - base path of all JSP set to request attribute.
httpContext - http context set to request attribute.
viewable - viewable to obtain model and resolving class from.
Method Detail

forward

public void forward(javax.servlet.ServletRequest request,
                    javax.servlet.ServletResponse response)
             throws javax.servlet.ServletException,
                    IOException
Specified by:
forward in interface javax.servlet.RequestDispatcher
Throws:
javax.servlet.ServletException
IOException

include

public void include(javax.servlet.ServletRequest request,
                    javax.servlet.ServletResponse response)
             throws javax.servlet.ServletException,
                    IOException
Specified by:
include in interface javax.servlet.RequestDispatcher
Throws:
javax.servlet.ServletException
IOException


Copyright © 2007-2013 Oracle Corporation. All Rights Reserved. Use is subject to license terms.