AJDT 1.6.2 - New and Noteworthy

Overview The theme of this release is Aspects Everywhere. Programmers using AJDT should be able to see the effects of their aspects wherever and whenever they apply. We have particularly focused on ensuring that the IDE treats intertype declarations more like regular declarations.

JDT Weaving Through the use of Equinox Aspects, AJDT is able to weave into Eclipse and hook in to existing functionality that was not exposed before. For more information on what capabilities the JDT Weaving plugin provides AJDT, see the wiki. And see here for more information on how the plugin is implemented.

ITD aware content assist (*.aj files only)

Intertype declared methods, fields, and constructors are now available in content assist. Similarly, appropriately scoped declarations from declare parent super types are also available in content assist.

For example, in the following screen shots, content assist shows the getX() and getY(), which are intertype declarations on the class.

Content assist in AJDT 1.6.2 includes ITDs.

However, this was not possible in AJDT 1.6.1.

Content assist in AJDT 1.6.1 does not include ITDs.

Currently, this functionality is only available in AJ Editors for *.aj files. Also, the project is required to have had a successful build. Adding this functionality to *.java files is a top priority for the next AJDT release.

ITD aware reconciling (*.aj and *.java)

Intertype declaration aware reconciling and eager parsing are now available in both AJ and Java editors. This means that ITD references in a compilation unit will no longer show spurious error bars. Furthermore, AJ editors now provide the same kind of eager error detection as you type that is available in Java editors.

Reconciling in AJDT 1.6.2 and ITD references are OK

Reconciling in AJDT 1.6.1 and ITD references are marked as errors in Java files

ITD aware super-type hierarchies

The type hierarchy view now shows types inserted into the hierarchy through a declare parents declaration.

Super-type hierarchies in AJDT 1.6.2 include ITDs

Super-type hierarchies in AJDT 1.6.1 do not include ITDs

Note that in this release, AJDT can only show super types that have been declared by declare parents. The sub-type hierarchy is not yet ITD aware.

Aspects in Open-Type dialogs The open type dialog now includes aspect types.

Java search for aspects, named pointcuts, and advice

Java search now includes aspects, named pointcuts, and advice.

In order to search for a named pointcut, use the search dialog and select Method:

If All occurrences is selected, then the results will include both declarations and references of the named pointcut:

Advice can similarly be searched for by entering the kind of advice (before, after, or around), selecting Method, and Declarations:

The result shows all advice declarations of the chosen kind:

Aspect references and declarations now appear when types are searched for.

Refactoring Standard rename, move, and copy/paste refactorings can now be applied to aspect compilation units (*.aj files) without errors or uncaught exceptions.

Bug fixes Many bug long standing bugs have finally been addressed due to the capabilities provided through JDT Weaving:
  • 71073 [jdt-weaving] java search not supported in AJDT
  • 106589 [jdt-weaving] [editor] [completion] Missing Containing Class Name on Add Imports
  • 121604 [jdt-weaving] [editor] A type containing main() and an aspect cannot be executed
  • 131467 [jdt-weaving] [debug] Support navigation to stack trace entries from .aj files
  • 132370 [jdt-weaving] Internal duplication: Java and AspectJ modes
  • 133119 [jdt-weaving] [navigation] Show in package explorer doesn't work for .aj files
  • 149711 [jdt-weaving] [editor] .java file cannot refer to class in .aj files
  • 151067 [jdt-weaving] [refactoring] alleged syntax error blocks refactor-rename
  • 177733 [jdt-weaving] Investigate use of AOSGi
  • 188845 [jdt-weaving] [editor] Organize Imports removes necessary import definition
  • 213513 [jdt-weaving] [editor] [refactoring] Files deleted upon failed move refactoring of aspect (.aj) file
  • 236352 [jdt-weaving] [editor] Imports are not organized properly when editing a *.aj source.
  • 240021 [jdt-weaving] Gaining control of CompilationUnit creation in JDT through the use of Aspects
  • 240047 [jdt-weaving] How to ship AJDT that weaves into JDT core
  • 252696 [jdt-weaving] [completion] Content assist should include declarations from ITDs
  • 254431 [jdt-weaving] [refactoring] Unable to rename a package whose aspects are used by another package
  • 256989 [jdt-weaving] [editor] UI incorrectly evaluates type of 'this' in an inter-type method
Other bugs that we have fixed for 1.6.2:
  • 114911 Support overriding inherited abstract methods in the new aspect wizard
  • 154501 [editor] Add gutter marker for deow members in an aspect
  • 238717 [build] Removing source folder does not remove resources from output folder
  • 214815 [build] [multiproject] Currently too difficult to selectively choose what is exported from an AspectJ project that uses inpath
  • 240234 [ajdoc] Generate AJDoc command fails on projects with large number of files
  • 241447 [headless-build] Patch so that AJDT 1.6 passes all tests.
  • 246949 Could not open the aspectj editor on *.aj files
  • 249072 Syntax highlight @xxx pointcuts
  • 252304 [build] Build Timestamps are inconsistent
  • 252624 [editor] Early problem indication (Report errors as you type) not working.
  • 253245 [API] AJDT 1.6.1 breaks Spring IDE
  • 253528 [build] Compilation folder is not marked as 'Derived'
  • 254980 [editor] Quick fix is not working
  • 255548 Compiler exception using iajc in headless build
  • 257438 [handles] error occurred during: Delete and update AspectJ markers
  • 258685 [editor] Editor shows an error on 'case' label with enum constant
  • 258698 [markers] Class cast exception when adding AspectJ markers to a .class file
  • 259033 Plug-in org.eclipse.ajdt.ui was unable to load class org.eclipse.ajdt.internal.ui.resources.AJImageDescriptorSelector.
  • 259034 trying something with the weaving AJDT tool set
  • 259035 Error in JDT Core during reconcile

Thanks! Thanks to all the AJDT users who provided valuable insight into how they are using AJDT and also for reporting bugs particularly with JDT Weaving installation.

And a special thanks goes out to Martin Lippert and Heiko Seeberger on the Equinox Aspects team for helping out with weaving in OSGi.

Previous Releases See here for information on the new features in AJDT 1.6.1.