Home > Store

Eclipse AspectJ: Aspect-Oriented Programming with AspectJ and the Eclipse AspectJ Development Tools

Register your product to gain access to bonus material or receive a coupon.

Eclipse AspectJ: Aspect-Oriented Programming with AspectJ and the Eclipse AspectJ Development Tools


  • Sorry, this book is no longer in print.
Not for Sale



The definitive (and only) introduction to Aspect-Oriented Programming (AOP) using Eclipse and ASpectJ.

° Author team is made up of the lead developers of AspectJ Development Tools(AJDT)

° AOP and AspectJ are rapidly growing and evolving along with Eclipse

° The first book to present a complete package of a productive development environment for AOP


  • Copyright 2005
  • Dimensions: 7" x 9-1/4"
  • Edition: 1st
  • Book
  • ISBN-10: 0-321-24587-3
  • ISBN-13: 978-0-321-24587-8

Now every Java developer can leverage the immense power of AOP With AspectJ, Java developers can leverage the breakthrough power of Aspect-Oriented Programming (AOP) using a language they already know, within the comfortable, highly productive Eclipse development environment. In this book, AspectJ's lead developers help you master AOP's essential principles and techniques, as you use them to address your toughest software quality, productivity, and maintenance challenges.

AOP improves the modularity of programs, making the code much closer to the design. It can dramatically reduce the time taken to implement common features and functions, improve quality, integrate plain-old Java objects with systems and services, create simpler, more reusable components, and much more besides.

Drawing on their experience as tool developers, programmers, and mentors, the authors cover every facet of AOP development with AspectJ and Eclipse, from creating new projects through extending and

documenting full-fledged applications. You'll find an authoritative tutorial covering the entire AspectJ language, a complete API reference, and realistic guidance on adopting AspectJ in your organization.

  • No AOP or Eclipse experience necessary!

  • Install and configure both Eclipse and the AspectJ Development Tools (AJDT)

  • Discover how AOP can modularize and optimize everything from error checking to performance

  • Craft new AspectJ applications and incorporate AOP capabilities into existing systems

  • Build, debug, and document AspectJ applications

  • Understand crucial AOP concepts, such as join points, pointcuts, advice, and inter-type declarations

  • Master advanced techniques: Aspect libraries, linking with compiled .class files, visualization, aspect-oriented design, and more

The accompanying website, www.awprofessional.com/title/0321245873, is full of samples, examples, and source code to help you start writing Java-based AOP software today.

© Copyright Pearson Education. All rights reserved.


Source Code

This source code file contains the code from Eclipse AspectJ: Aspect-Oriented Programming with AspectJ and the Eclipse AspectJ Development Tools by Adrian Colyer, Andy Clement, George Harley and Matthew Webster.

Sample Content

Online Sample Chapter

Using Eclipse AspectJ: Your First Steps

Downloadable Sample Chapter

Download the Sample Chapter related to this title.

Table of Contents




1. Getting Started.

    What Is Eclipse?

    Installing Eclipse.

    Eclipse Basics.

    Installing AJDT.

    Examples for This Book.

    Summary .

2. First Steps in AJDT.

    A Simple Insurance Application.

    Tracking Policy Updates.

    Creating an AspectJ Project.

    Creating the PolicyChangeNotification Aspect.

    Stating the Notification Policy.

    Implementing the Notification Policy.

    Showing Advice In AJDT.

    Evaluating the Implementation.

    Finishing Touches.


3. Extending the Application.

    The Story So Far.

    Serialization-Based Persistence.


    Managing Build Configurations.


4. More AJDT.

    Building an ASPECTJ Project.


    Editor Templates and the Outline View Toolbar.

    Generating Documentation (Ajdoc).

    AspectJ Help, Examples, and Cheat Sheets.



5. An Overview of AspectJ.

    What Is An Aspect?

    Join Points and Pointcuts.


    Inter-Type Declarations.

    Key Design Properties of the AspectJ Language.



6. Straight to the Point.

    The Calculator Program.

    Introduction to Pointcut Designators.

    The Method Call Pointcut Designator.

    Pointcut Composition.

    Patterns and Signatures.

    The Method Execution Pointcut Designator.

    The Target Pointcut Designator.

    The this Pointcut Designator.

    The get and set Pointcut Designators.

    Capturing Context with the args Pointcut Designator.

    Extracting Values with this and target.

    The handler Pointcut Designator.

    Initialization Pointcut Designators.

    Static Scoping Pointcut Designators: within, withincode.

    Dynamic Scoping Pointcut Designators: cflow, cflowbelow.

    The adviceexecution Pointcut Designator.

    The if Pointcut Designator.

    How to Write a Good Pointcut.

    Common Pitfalls.


7. Take My Advice.

    The Different Types of Advice.

    Advice Parameters and Pointcuts.

    Writing Logic in the Body of Advice.

    Advice Ordering.

    Softening Exceptions.

    declare warning and declare error.

    Common Pitfalls. 



8. Inter-Type Declarations.

    Fields, Methods, and Constructors.

    Scope and Visibility.

    Inter-Type Declarations and Interfaces.

    Extending Classes.

    Using Pointcuts and Advice with Inter-Type Declarations.


9. Aspects.

    Aspect Definition and Initialization.

    Aspect Instantiation.

    Aspect Inheritance.

    Inner Aspects.

    Aspect Privilege.

    Common Pitfalls.


10. Using the AspectJ API.

    Package org.aspectj.lang.

    Package org.aspectj.lang.reflect.



11. Adopting AspectJ.

    The Adoption Process.

    Different Types of Aspects.

    Enforcement Aspect Examples.

    Infrastructure Aspect Examples.

    Core Aspect Examples.

    Evaluating the Simple Insurance Application.



12. Advanced AJDT.

    Aspect Libraries.

    Linking Aspects with Compiled .class Files.

    Ant Integration.

    Aspect Visualization.


13. Aspect-Oriented Design.

    Finding Aspects.

    What Makes a Good Aspect?

    Closing Thoughts.

Appendix A. Command-Line AspectJ.

    Installing AspectJ.

    Using the Compiler.

    Building with Ant.

Appendix B. AspectJ Language Quick Reference.

    Aspect Declaration.




    Inter-Type Declarations.

Appendix C. Next Steps.

    Mailing Lists and FAQ.

    Raising Bugs and Enhancement Requests.

    Contributing to the Development of AspectJ and AJDT

Appendix D. AJDT Icons Reference.


    Object Adornments.


    Build Configuration.



Submit Errata

More Information

Unlimited one-month access with your purchase
Free Safari Membership