-
Notifications
You must be signed in to change notification settings - Fork 0
spring views
Eric F. Alsheimer edited this page Jan 12, 2018
·
1 revision
ViewResolvers are how a 'view' is 'resolved', i.e. how Spring know what view to use when the controller's action is completed. By default the controller will use the InternalResourceViewResolver to determine what view is to be rendered. When the controller is returning a String, that string will be considered the name of the view that is to be retrieved and rendered (in the WEB-INF/views/.jsp location).
@RequestMapping("/")
public String doWelcome(Model model) {
...
return "welcomeIndex";
}JSPs interpolate controller-model values using ${...}