- Spring 2.5 Aspect Oriented Programming
- Massimiliano Dessi
- 528字
- 2021-05-21 20:23:10
What this book covers
Chapter 1 introduces the ideas that led to Aspect-Oriented Programming. An overview of main concepts of AOP is used to describe components and features provided by Spring AOP, while a set of concise yet clear examples lets the reader discover what can actually be done with AOP.
Chapter 2 describes in detail the fundamentals of AOP in Spring, presenting interfaces and classes introduced in early 1.x versions of the framework. This chapter shows how to use AOP programmatically, to let the reader discover the basis of Spring AOP and the components that implement Aspect-Oriented Programming in Spring.
Chapter 3 explains how the weaving of AOP components is done using the proxy pattern and JDK or CGLIB implementations. It describes the purpose of proxies and how to use them effectively. Some practical examples show how to use the proxies programmatically, with annotations and with XML; they explain the ProxyFactoryBean and how to make the programmer's work easier with AutoProxy. The chapter describes also some smart techniques on target sources.
Chapter 4 explains how Spring AOP is supported by AspectJ. Configuration activity is made simpler, more flexible and more powerful, thanks to annotations and the syntax of AspectJ on pointcuts (without which those costructs would not be available). All examples show how to use AspectJ with both annotations and XML. The chapter contains practical recipes for specific cases, such as the injection of dependencies on domain objects, the management of aspects' priority, the use of different life cycles for Aspects and how to use Load Time Weaving. The chapter ends with some strategies on how to choose different AOP approaches to fulfil specific requirements.
Chapter 5 describes the design alternatives that can be implemented using AOP. These alternatives are solutions for common requirements: concurrency, caching, and security. Using AOP, they can be achieved in a very elegant and easy way, being at the same time totally transparent for the system where they are applied.
Chapter 6 introduces Domain-Driven Development as a alternative way to design applications. The prototype example presented in this chapter is a typical Three-Layer application, where DDD is used for design and AOP is used to inject the dependencies on domain objects. iBatis is used for persistence to the database.
Chapter 7 completes the prototype application started in Chapter 6, showing the application layer and the user interface. The latter is implemented with Spring MVC using annotations. Integration and unit tests are used to verify the correctness of the classes; DBUnit is used to test persistence classes, while some Mock classes are used to test the UI. The chapter contains the configurations for the prototype infrastructure, including autentication and authorization with Spring Security and the JUnit 4.5 test suite.
Chapter 8 describes the development tools needed to include Spring AOP and AspectJ in the Eclipse IDE. The reader can find here detailed istructions on how to configure Eclipse with the plug-ins for Spring and for the AspectJ Development Tool, and how to install the PostgreSQL database and the Apache Tomcat servlet engine. All installation procedures are described for the three main operating systems: Ubuntu Linux, Apple Mac OS X, and Microsoft Windows XP.
- Photoshop CC 網店視覺設計
- UG NX 12.0中文版完全自學一本通
- SolidWorks 2021中文版機械設計從入門到精通
- DSP開發寶典
- Drupal 6 Panels Cookbook
- ASP.NET jQuery Cookbook
- CryENGINE 3 Cookbook
- 中文版Photoshop CC2018從入門到精通(第4版)
- Capture One 22 Pro高級實戰教程
- SPSS統計分析
- AutoCAD 2016中文版基礎教程(全圖解視頻版)
- 中文版Illustrator 2020基礎教程
- 中文版CINEMA 4D R20 實用教程
- 中文版AutoCAD 2022從入門到精通
- 中文版Premiere Pro CS6視頻編輯(慕課版)