public class ViewControllerRegistration
extends java.lang.Object
Constructor and Description |
---|
ViewControllerRegistration(java.lang.String urlPath) |
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
getUrlPath() |
protected ParameterizableViewController |
getViewController() |
protected void |
setApplicationContext(ApplicationContext applicationContext) |
ViewControllerRegistration |
setStatusCode(HttpStatus statusCode)
Set the status code to set on the response.
|
void |
setViewName(java.lang.String viewName)
Set the view name to return.
|
public ViewControllerRegistration(java.lang.String urlPath)
public ViewControllerRegistration setStatusCode(HttpStatus statusCode)
If not set the response status will be 200 (OK).
public void setViewName(java.lang.String viewName)
If not specified, the view controller will return null
as the
view name in which case the configured RequestToViewNameTranslator
will select the view name. The DefaultRequestToViewNameTranslator
for example translates "/foo/bar" to "foo/bar".
DefaultRequestToViewNameTranslator
protected void setApplicationContext(ApplicationContext applicationContext)
protected java.lang.String getUrlPath()
protected ParameterizableViewController getViewController()