AspectJ Documentation and Resources

AspectJ tm is a seamless aspect-oriented extension to Javatm. The compiler and development tools are available under an open-source license, require Java 2 to run, and produce code that runs in JDK 1.1 and later VM's. For the latest materials, see http://aspectj.org, especially the FAQ.

SectionContents
docs tutorial and FAQ, Quick Reference, programming and development guides, API and (local) examples
distributions compiler, AJDE, docs, and Ant taskdefs (binary - source)
resources aosd.net; aspectj.org bug db and email, mail lists for users and support
paths for those new to AspectJ

AspectJ documentation

DocumentationDescription
AspectJ Tutorial (web) These slides outline the rationale and concepts of AOP and the basics of the AspectJ language. Of note: join point terminology, advice parameters, the comparisons with regular Java code for typical applications, and the context-passing example.
AspectJ Quick Reference (web) This is a two-page quick reference for the AspectJ language.
Programming Guide (printable pdf or html - web ) This introduces AOP and the AspectJ language. Getting Started describes basic semantics, and shows development- and production-time applications. The AspectJ Language describes join points, pointcuts, advice, and introduction, all features new to AOP. Examples walks you through the examples included with the documentation, and there are two short chapters on useful Idioms and a few Pitfalls The appendices have reference information: the Quick Reference summarizes AspectJ syntax, the Language Semantics best describes AspectJ usage, and Implementation Limitations notes that the current version is limited to code the compiler controls.
Development Environment Guide
(printable html - web )
Find here a guide to the command-line compiler ajc and API doc tool ajdoc, as well as the AspectJ Development Environment (AJDE) for managing crosscutting structure in JBuilder, Forte, Emacs, and the stand-alone ajbrowser. (For using ajc and ajdoc in Ant builds, see the taskdefs distribution.)
AspectJ API (web) API documentation for AspectJ runtime classes. JoinPoint shows the state automatically available at each join point.
FAQ (web) Frequently-asked questions about the AspectJ language, tools, and project.
Porting guide (web) How users can convert code from pre-1.0 versions of AspectJ to 1.0.
Changes (web) Changes between the latest releases.
Examples (local) AspectJ code to demonstrate some language features and implement JavaBean properties, the Observer pattern, a tracing library, and a game application where aspects handle display updating.

AspectJ distributions

DistributionsDescription
Tools The tools distribution has the command-line tools - the ajc compiler, ajdoc API doc generator, and ajdb debugger - along with the stand-alone GUI structure browser, ajbrowser.
Documentation This documentation and examples, summarized above.
AJDE AspectJ Development Environment support for JBuilder, Forte/SunONE Studio 4, Eclipse, and Emacs.
Ant taskdefs Support for invoking ajc and ajdoc using Apache's Ant 1.3 build tool.
Source Source code for the tools and AJDE.

Other AspectJ resources

ResourcesDescription
user email list Developers use the users@aspectj.org mail list to discuss tips and best practices for developing with AspectJ.
announce email list announce@aspectj.org has notices about releases and AspectJ team events.
email us Email support@aspectj.org to contact the AspectJ team directly. (As a small team, we cannot reply as fast as users can for usage questions.)
Bug DB and email Please send AspectJ bugs! (as a small program that reproduces the problem)
http://aosd.net - the AOSD web site This site has discussion and announcements related to aspect-oriented software development (AOSD) in general. Use announce@aosd.net to get and publish notices about AOSD workshops, conferences, and technology releases. Use discuss@aosd.net for general AOSD discussions.

Suggested paths for those new to AspectJ

For a conceptual overview of AspectJ as an aspect-oriented programming (AOP) language, the tutorial slides state the problem of crosscutting concerns addressed by AOP and how solutions can be framed in the AspectJ language. For other work in this area, see http://aosd.net.

To learn the AspectJ language, read the Programming Guide, keeping the Semantics appendix nearby as the best reference for AspectJ usage. Focus initially on the join point model and pointcuts, concepts AOP adds to OOP. To see how the code works, tour your local examples as described in the Examples section of the Programming Guide. View and navigate the crosscutting structure using the ajbrowser structure viewer, as described in the ajbrowser section of the Development Environment Guide.

To start using AspectJ with your own code, modify the example aspects to apply to your classes. The Development Environment Guide shows how to build using the command-line tools or with JBuilder, Forte, or Emacs. As you learn, use the compiler's -Xlint flag to catch some common mistakes. (Understand that the current implementation is limited to code the compiler controls.)

To plan how to adopt AspectJ into a project, read the Programming Guide on development- and production-time aspects and the FAQ entries for How should I start using AspectJ?, Deciding to adopt AspectJ, the Development tools sections (one, two), AspectJ as open-source and available support and consulting.

Otherwise, see the FAQ, view or email the AspectJ users list, and enjoy the language!

The AspectJ Team


Top - last updated: July 24, 2002