Community
Participate
Working Groups
If an aspect contains a main mehod (public static etc), it still can not be run via the Run --> Run As... --> Java application. The message is: "The active editor does not contain a main type". Try this out by opening the examples that come with aspectj and try to run introduction.HashablePoint Note that it runs fine from the command line.
This will be fixed in the forthcoming AJDT release. In the meantime, there is a workaround, which is as follows: * create a run "Java Application" launch profile by selecting "run..." and then clicking new. * Ignore the "search" button next to the "main class" entry field and just type in the fully-qualified name of the aspect you want to run. * Click apply, and then run. * The saved launch profile can be used immediately for running or debugging from now on.
A new launching option - Run 'AspectJ/Java Application' has been added to the run menu that finds main methods in aspects. We have also added shortcuts to this launcher from aspects in the package explorer by right clicking on an aspect then clicking Run > 'AspectJ/Java Application'. Available in CVS now and to be included in the 1.1.13 release of AJDT.