Spring Framework tagging library Beginner's Guide

Source: Internet
Author: User
Spring is an application framework that serves all layers: it provides bean configuration basics, AOP support, JDBC extraction framework, and abstract transaction support. It has a very notable feature: At a certain level, if you do not need Spring support, you can use only some of its functions instead of the String class. From its design philosophy, you can see that String helps you achieve true separation between the logic layer and the web layer.
Compared with EJB, Spring is a lightweight J2EE application development framework. The lightweight mentioned here refers to the Spring Framework itself, rather than Spring can only be applied to lightweight application development. The lightness of Spring is reflected in the infrastructure of its framework and its support and assembly capabilities for other application tools. Compared with the Giants like EJB, Spring reduces the risks between different technical layers. EJB has a strong cohesion. For example, data persistence layer management, transaction management, and lifecycle management are all handed over to the EJB container for management, the White Box feature of cohesion makes it necessary to discard some controllability and trust container capabilities. Spring considers how to "not build wheels" and how to assemble these wheels to make them rotate better. For example, you can use hibernate for data persistence layer management and jakartacommonlogging for log management. A more appropriate metaphor is: "We need to pin a few nails. To achieve this goal, the hammer manufacturer has produced a series of hammers, large and small. Each Hammer has a set of complicated methods to use, it's a headache for us. To solve the problem of too many hammers, we can use several hammers through spring, but it seems that there is only one hammer ". (Note: I have seen this article on the internet. I personally think it is very vivid to cite this metaphor here.) there are also some simple summary about this framework: "Spring has several main parts: bean + ApplicationContext: Searches, manages, assembles, and uses system components in a unified and IoC manner, replacing all factories, Persistence frameworks, and web frameworks. The "J2EE framework" is RodJohnson's vision, and he hopes that Spring will provide a base-to-top comprehensive infrastructure support for J2EE lightweight solutions ."
The above is a brief introduction to a new Framework, which is said to be the development direction of J2EE in the future. I used to discuss the best J2EE combination on the forum. I heard that this JSTL + Struts (or webwork) + Spring + Hibernate combination is very promising. If you are interested, go to the SpringFramework Chinese forum. The following is the subject of this article.

Spring tag library introduction and usage:
This article focuses on the tag library provided by Spring and its usage:
When you use Spring Framework in your project, you can select the tag library that comes with Spring Framework for the presentation layer. Of course, this is not your only choice. You can choose another tag library or template replacement technology. Spring Framework does not provide a rich tag library for applications. The markup library provided by Spring Framework is only available for use, and it is not all-encompassing. This is different from Struts's rich tag library. In fact, this is in line with RodJohnson's starting point, neither making wheels ". Of course, the Spring Framework tag library has its own characteristics, which can be a useful supplement.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.