public class Redirect extends Object implements Consequence
| Modifier and Type | Field and Description |
|---|---|
static String |
REDIRURL_PARAM
The parameter's name in the output containing the URL to redirect to.
|
| Constructor and Description |
|---|
Redirect()
Creates a redirect with a dynamic url.
|
Redirect(ActionConfig ac) |
Redirect(ActionConfig ac,
boolean appendOutput) |
Redirect(boolean appendOutput)
Creates a redirect with a dynamic URL and dynamic parameters.
|
Redirect(String url)
Creates a normal redirect for the given url.
|
Redirect(String url,
boolean appendOutput)
Creates a redirect for the given url with dynamic parameters.
|
public static final String REDIRURL_PARAM
public Redirect(String url)
url - is the url for this redirect.public Redirect(ActionConfig ac)
public Redirect(String url, boolean appendOutput)
Output object for the
Action. All the parameters are appended to the URL query string.url - is the url for this redirect.appendOutput - is true if this redirect is to use dynamic parameters.public Redirect(ActionConfig ac, boolean appendOutput)
public Redirect()
public Redirect(boolean appendOutput)
Output object for
the Action. All the parameters are appended to the URL query
string.appendOutput - is true if this redirect is to use dynamic parameters.public void execute(Action act, String result, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) throws ConsequenceException
execute in interface Consequenceact - action to be redirected.req - request object.res - response objectresult - The result generated by the action.ConsequenceException - if an error is detected during construction of the redirection
URL.Copyright © 2015. All Rights Reserved.