![](https://csdnimg.cn/release/download_crawler_static/9597633/bg12.jpg)
Spring Framework Reference Documentation
4.3.2.RELEASE Spring Framework xviii
22.11. Handling exceptions ..................................................................................... 532
HandlerExceptionResolver .............................................................................. 532
@ExceptionHandler ........................................................................................ 532
Handling Standard Spring MVC Exceptions ...................................................... 533
Annotating Business Exceptions With @ResponseStatus .................................. 534
Customizing the Default Servlet Container Error Page ...................................... 534
22.12. Web Security ............................................................................................... 535
22.13. Convention over configuration support ........................................................... 535
The Controller ControllerClassNameHandlerMapping ........................................ 535
The Model ModelMap (ModelAndView) ............................................................ 536
The View - RequestToViewNameTranslator ..................................................... 537
22.14. HTTP caching support .................................................................................. 538
Cache-Control HTTP header ........................................................................... 539
HTTP caching support for static resources ....................................................... 539
Support for the Cache-Control, ETag and Last-Modified response headers in
Controllers ...................................................................................................... 540
Shallow ETag support ..................................................................................... 541
22.15. Code-based Servlet container initialization ..................................................... 542
22.16. Configuring Spring MVC ............................................................................... 543
Enabling the MVC Java Config or the MVC XML Namespace ............................ 544
Customizing the Provided Configuration ........................................................... 545
Conversion and Formatting ............................................................................. 546
Validation ....................................................................................................... 547
Interceptors .................................................................................................... 548
Content Negotiation ........................................................................................ 549
View Controllers ............................................................................................. 550
View Resolvers .............................................................................................. 550
Serving of Resources ..................................................................................... 551
Falling Back On the "Default" Servlet To Serve Resources ................................ 554
Path Matching ................................................................................................ 555
Message Converters ....................................................................................... 556
Advanced Customizations with MVC Java Config ............................................. 557
Advanced Customizations with the MVC Namespace ........................................ 558
23. View technologies ..................................................................................................... 559
23.1. Introduction .................................................................................................... 559
23.2. Thymeleaf ..................................................................................................... 559
23.3. Groovy Markup Templates .............................................................................. 559
Configuration .................................................................................................. 559
Example ......................................................................................................... 560
23.4. Velocity & FreeMarker .................................................................................... 560
Dependencies ................................................................................................ 560
Context configuration ...................................................................................... 560
Creating templates ......................................................................................... 561
Advanced configuration ................................................................................... 561
velocity.properties ................................................................................... 561
FreeMarker ............................................................................................. 562
Bind support and form handling ....................................................................... 562
The bind macros .................................................................................... 562
Simple binding ........................................................................................ 563
Form input generation macros ................................................................. 563