|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.ibisph.mvc.view.SimpleClientRedirection
public class SimpleClientRedirection
Basic Spring MVC client redirection view implementation. This provides two ways to issue a client redirection to a new address. The first is when the controller sets the URL in the model (using the model name property to access the value), with the second using the specified redirection address property.
This can also be done by the controller returning a view name string of:"redirect:" . Another way is to
do this: new RedirectView(foo.do), which is contained in the
org.springframework.web.servlet.view package. This class was created for
view pluggability/XML configuration.
View| Constructor Summary | |
|---|---|
SimpleClientRedirection()
Explicit default constructor |
|
| Method Summary | |
|---|---|
java.lang.String |
getContentType()
Spring View required method. |
java.lang.String |
getRedirectionAddress()
|
java.lang.String |
getURLModelName()
|
void |
render(java.util.Map modelMap,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Core Spring MVC view implementation method call. |
void |
setRedirectionAddress(java.lang.String redirectionAddress)
Sets the default URL redirection address to be used is a URL value is not specified in the model. |
void |
setURLModelName(java.lang.String urlModelName)
Sets the model name for the URL parameter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleClientRedirection()
| Method Detail |
|---|
public java.lang.String getContentType()
getContentType in interface org.springframework.web.servlet.Viewpublic void setURLModelName(java.lang.String urlModelName)
ClientRedirection
setURLModelName in interface ClientRedirectionpublic void setRedirectionAddress(java.lang.String redirectionAddress)
ClientRedirection
setRedirectionAddress in interface ClientRedirectionpublic java.lang.String getURLModelName()
getURLModelName in interface ClientRedirectionpublic java.lang.String getRedirectionAddress()
getRedirectionAddress in interface ClientRedirection
public void render(java.util.Map modelMap,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws java.lang.Exception
response.sendRedirect
call if the model contains a redirection URL parameter, or
redirects to the specified redirection address property. If the
redirection address property is null, then an exception
will be thrown causing the system to display the error view.
render in interface org.springframework.web.servlet.ViewmodelMap - MVC model map.request - HTTP request passed from Spring MVC framework - not used.response - HTTP response passed from Spring MVC framework. This
is used to send the HTTP client redirection to either the model
URL or the redirection address property.
java.lang.Exception
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||