AspectJ Cookbook

Front Cover
"O'Reilly Media, Inc.", 2005 - Computers - 331 pages

When Object Oriented programming (OO) first appeared, it was a revelation. OO gave developers the ability to create software that was more flexible and robust, but as time went on and applications became more sophisticated, too, certain areas of "traditional" OO architectures were found wanting. Aspect-oriented programming (AOP) addresses those issues by extending the OO approach even further.

Many developers are interested in AOP--especially in AspectJ, the open source extension of the Java programming language that explicitly supports the AOP approach. Yet, although AspectJ is included with Eclipse, the increasingly popular open source IDE for Java, finding a practical and non-theoretical way to learn this language and other AOP tools and techniques has been a real problem.

Until now. The AspectJ Cookbook offers a hands-on solution--in fact, several--with a wide variety of code recipes for solving day-to-day design and coding problems using AOP's unique approach.

AOP allows the global properties of a program to determine how it's compiled into an executable program. Before AOP, important program design decisions were difficult to capture in actual code. Instead, the implementation of those design decisions--known as "aspects"--were scattered throughout, resulting in "tangled" code that was hard to develop and maintain. AOP has been compared to the manufacturing of cloth, in which threads are automatically interwoven. Without AOP, programmers must stitch the threads by hand.

The AspectJ Cookbook shows readers why, and how, common Java development problems can be solved by using AOP techniques. With our popular problem-solution-discussion format, the book presents real world examples to demonstrate that AOP is more than just a concept; it's a development process that will benefit users in an immediate and visible manner.

If you're interested in how AOP is changing the way software is developed, and how you can use AspectJ to make code more modular, easier to develop, maintain, evolve and deploy, this is the book that really delivers.

 

What people are saying - Write a review

We haven't found any reviews in the usual places.

Contents

Preface
Aspect Orientation Overview
Getting Started with AspectJ
Deploying AspectJ Applications
Capturing Join Points on Methods
Capturing Join Points on ExceptionHandling
Capturing Join Points on Advice
Capturing Join Points on Classand Object Construction
Defining Aspect Instantiation
Defining Aspect Relationships
Enhancing Classes and the Compiler
Implementing Creational ObjectOriented Design Patterns
Implementing Structural ObjectOriented Design Patterns
Implementing Behavioral ObjectOriented Design Patterns
Applying Class and ComponentScale Aspects
Applying Application Scale Aspects

Capturing Join Points on Attributes
Capturing Join Points WithinProgrammatic Scope
Capturing Join Points Basedon Control Flow
Capturing Join Points Basedon Object Type
Capturing Join Points Based on aBoolean or Combined Expression
Defining Advice
Applying Enterprise Scale Aspects
Applying AspectOrientedDesign Patterns
The AspectJ Runtime API
Index
Copyright

Other editions - View all

Common terms and phrases

Bibliographic information