org.springframework.web.servlet.view
Class RedirectView

org.springframework.context.support.ApplicationObjectSupport
  |
  +--org.springframework.web.context.support.WebApplicationObjectSupport
        |
        +--org.springframework.web.servlet.view.AbstractView
              |
              +--org.springframework.web.servlet.view.AbstractUrlBasedView
                    |
                    +--org.springframework.web.servlet.view.RedirectView

public class RedirectView
extends AbstractUrlBasedView

View that redirects to an internal or external URL, exposing all model attributes as HTTP query parameters.

A URL for this view is supposed to be a HTTP redirect URL, i.e. suitable for HttpServletResponse's sendRedirect method.

Author:
Rod Johnson, Juergen Hoeller
Version: $Id: RedirectView.java,v 1.4 2003/12/15 08:33:57 jhoeller Exp $
See Also: javax.servlet.http.HttpServletResponse#sendRedirect

Field Summary
 final static StringDEFAULT_ENCODING_SCHEME
           

Constructor Summary
RedirectView()
          Constructor for use as a bean.
RedirectView(String url)
          Create a new RedirectView with the given URL.

Method Summary
 voidsetEncodingScheme(String encodingScheme)
          Set the encoding scheme for this view.

Methods inherited from class org.springframework.web.servlet.view.AbstractUrlBasedView
getUrl, setUrl

Methods inherited from class org.springframework.web.servlet.view.AbstractView
addStaticAttribute, getBeanName, getStaticAttributes, render, setAttributes, setAttributesCSV, setAttributesMap, setBeanName, setContentType, setRequestContextAttribute

Methods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, setApplicationContext

Field Detail

DEFAULT_ENCODING_SCHEME

public final static String DEFAULT_ENCODING_SCHEME
Constructor Detail

RedirectView

public RedirectView()
Constructor for use as a bean.

RedirectView

public RedirectView(String url)
Create a new RedirectView with the given URL.
Parameters:
url - the URL to redirect to
Method Detail

setEncodingScheme

public void setEncodingScheme(String encodingScheme)
Set the encoding scheme for this view.

Association Links

to Class java.lang.String

to Class java.lang.String