-
Book Overview & Buying
-
Table Of Contents
Spring MVC Beginner's Guide - Second Edition
By :
As I already mentioned, Spring MVC does not make any assumptions about specific View technologies. According to Spring MVC, a View is identifiable as an implementation of the org.springframework.web.servlet.View interface:
public interface View {
String getContentType();
void render(Map<String, ?> model, HttpServletRequest request, HttpServletResponse response) throws Exception;
}
The render method from the Spring MVC View interface defines, as the main responsibility for a view object, that it should render proper content as a response (javax.servlet.http.HttpServletResponse) based on the given Model and request (javax.servlet.http.HttpServletRequest).
Because of the simplicity of the Spring MVC View interface, if we want we can write our own View implementation. But Spring MVC provides many convenient View implementations that are ready to use by simply configuring them in our web application context configuration file...
Change the font size
Change margin width
Change background colour