AspectJ Support Plugin

Skip to end of sidebar
Go to start of sidebar
Skip to end of metadata
Go to start of metadata

AspectJ support plugin is intended, well, to support aspect-oriented programming with AspectJ tool.

What's in

AspectJ support in IDEA has grown from a request to ease a development of Spring Roo applications – which use AspectJ inter-type declarations heavily – so at the moment plugin's functionality is centered around that topic, with the goal to make development of aspect-added code as pleasant as native Java one.

Current feature set:

  • resolve, completion, navigation, usages and renaming of inter-type declarations
  • highlighting of declaration conflicts in AspectJ and Java code
  • some IDEA's code mastering features in inter-type declaration bodies (e.g. completion and usages)
  • project building with AJC compiler

IDEA with the plugin and sample Roo project in it:

What's on the way

  • support of missing AspectJ features
  • AspectJ-specific refactorings
  • all the bugs fixing :)

How to try

1) Download the plugin from plugin repository, or install it via IDEA's plugin manager. Note that the plugin usually requires latest Maia EAP to work.

2) Download and install AspectJ; add AspectJ runtime libraries to project dependencies (not required for Roo projects).

3) To make use of your aspects the project should be compiled by AspectJ compiler – so in project settings (File - Settings) open compiler one (Compiler - Java Compiler) and from "Use compiler" list pick "Ajc" option:

Note: since version 0.5 plugin attempts to import compiler settings from Maven projects (e.g. generated by Roo).

If something's wrong

The plugin certainly is far enough from perfection. If you found a bug, or have a complaint, or just want some feature – please post an issue in our tracker, or vote for/comment existing ones.

Updates

Dec 13, 2010 – plugin version 0.7 released with following improvements:

  • debugging (breakpoints and stepping in AspectJ code)
  • more highlighting for incorrect code
  • compiler error reporting improved

Please note: it is the last release of the plugin (as a separate). Since IDEA 10 it comes bundled in.

Oct 5, 2010 – plugin version 0.6.1 released, fixes compiler heap limit setting.

Aug 27, 2010 – plugin version 0.6 released with following improvements:

  • support for interface methods implementation by aspects
  • better usage reporting for private fields accessed in aspects only
  • better JPA integration
  • compiler error reporting improved

Jul 15, 2010 – plugin version 0.5 released with following improvements:

  • more syntax support: nested aspects, aspect constructors, fields and methods
  • more highlighting for incorrect code
  • hasAspect() and aspectOf() synthetic methods
  • Safe Delete for aspects
  • private fields in Roo entity classes are no longer reported as unused
  • structure view for AspectJ files with filter for inter-type declarations
  • compiler support improvements
  • importing compiler settings from Maven projects (e.g. generated by Roo)

Jun 4, 2010 – plugin version 0.4 released with following improvements:

  • live templates, "Surround With" and "Complete Statement" actions now works in aspects
  • "New | Aspect" action (available if aspectjrt.jar lib is in module classpath)
  • in project structure view aspects now looks (almost) like classes
  • renaming aspects (both from editor and project structure view)
  • code formatting
  • automatic weaving from aspects in classpath (Roo tests now runs from IDEA)
  • compiler support improvements
  • better JUnit and TestNG support
  • bug fixes
Labels:
None
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Jul 29, 2010

    Anonymous

    Roo support would be wonderful! Seems like a good thing to blog about

  2. Apr 06, 2012

    Anonymous

    Is this plugin open sourced?

    1. Apr 06, 2012

      No, it's a part of Ultimate Edition.

  3. Jul 03, 2012

    Anonymous

    Adding this plugin for 11 CE, it locks everything up.  I can't view my code anymore, it just says "loading..." when I expand the folder.  Hitting debug/run or edit configurations results in either not working or just showing an empty menu.

    Using Mac OSX Lion.

    1. Jul 03, 2012

      It works in Ultimate Edition only (ships with it since IDEA 10). I've dropped old versions from repository. Sorry for inconvenience.

Add Comment