zoukankan      html  css  js  c++  java
  • Features of Spring Web MVC

    21.1.1 Features of Spring Web MVC

    Spring’s web module includes many unique web support features:

    • Clear separation of roles. Each role — controller, validator, command object, form object, model object, DispatcherServlet, handler mapping, view resolver, and so on — can be fulfilled by a specialized object.
    • Powerful and straightforward configuration of both framework and application classes as JavaBeans. This configuration capability includes easy referencing across contexts, such as from web controllers to business objects and validators.
    • Adaptability, non-intrusiveness, and flexibility. Define any controller method signature you need, possibly using one of the parameter annotations (such as @RequestParam, @RequestHeader, @PathVariable, and more) for a given scenario.
    • Reusable business code, no need for duplication. Use existing business objects as command or form objects instead of mirroring them to extend a particular framework base class.
    • Customizable binding and validation. Type mismatches as application-level validation errors that keep the offending value, localized date and number binding, and so on instead of String-only form objects with manual parsing and conversion to business objects.
    • Customizable handler mapping and view resolution. Handler mapping and view resolution strategies range from simple URL-based configuration, to sophisticated, purpose-built resolution strategies. Spring is more flexible than web MVC frameworks that mandate a particular technique.
    • Flexible model transfer. Model transfer with a name/value Map supports easy integration with any view technology.
    • Customizable locale, time zone and theme resolution, support for JSPs with or without Spring tag library, support for JSTL, support for Velocity without the need for extra bridges, and so on.
    • A simple yet powerful JSP tag library known as the Spring tag library that provides support for features such as data binding and themes. The custom tags allow for maximum flexibility in terms of markup code. For information on the tag library descriptor, see the appendix entitled Chapter 40, spring.tld
    • A JSP form tag library, introduced in Spring 2.0, that makes writing forms in JSP pages much easier. For information on the tag library descriptor, see the appendix entitled Chapter 41, spring-form.tld
    • Beans whose lifecycle is scoped to the current HTTP request or HTTP Session. This is not a specific feature of Spring MVC itself, but rather of theWebApplicationContext container(s) that Spring MVC uses. These bean scopes are described in Section 6.5.4, “Request, session, and global session scopes”

    http://docs.spring.io/spring/docs/4.2.0.RC1/spring-framework-reference/htmlsingle/#mvc-features

  • 相关阅读:
    C# Excel导出超出65536行报错 Invalid row number (65536) outside allowable range (0..65535)
    C# 获取指定类型的文件
    C# 控制台定时器
    C# 去除Split()中去除内容为空的数据
    C#获取当前服务器运行程序的根目录,获取当前运行程序物理路径
    C#实体转为json字符串
    C#Split的用法,Split分割字符串
    C#直接引用js文件调js里的数据
    java虚拟机学习记录(内存划分、垃圾回收、类加载等机制)
    关于MySQL数据库事务的机制学习总结
  • 原文地址:https://www.cnblogs.com/softidea/p/5894392.html
Copyright © 2011-2022 走看看