Hi,
I'm
trying to write a simple aspect that prints a message when the Cancel button of
a specific wizard (the Plug-in Project Creation Wizard) is pressed. Here is the
aspect's code:
import
org.eclipse.pde.internal.ui.wizards.plugin.NewPluginProjectWizard; //org.eclipse.pde.ui
import org.eclipse.jface.wizard.Wizard; //
org.eclipse.jface
public aspect
PluginWizardCancelPressed {
after(): execution(*
Wizard.performCancel(..)) && this(NewPluginProjectWizard){
System.out.println(thisJoinPoint);
}
}
Upon
execution I get tons of errors (shown below), and the aspect has no effect. Note
that everything works fine when rewriting the aspect in the following way:
public aspect
PluginWizardCancelPressed {
after(Object obj): execution(* Wizard.performCancel(..))
&& this(obj){
if(obj instanceof
NewPluginProjectWizard)
System.out.println(thisJoinPoint);
}
}
Any
suggestions?
Thanks,
Oren
The errors:
[org.eclipse.jface]
error can't determine modifiers of missing type org.eclipse.pde.internal.ui.wizards.plugin.NewPluginProjectWizard
when
processing type mungers org.eclipse.jface.preference.IPreferenceStore
when
processing type mungers
when
weaving
[Xlint:cantFindType]
[org.eclipse.jface] error can't
determine modifiers of missing type org.eclipse.pde.internal.ui.wizards.plugin.NewPluginProjectWizard
when
processing type mungers org.eclipse.jface.internal.JFaceActivator
when
processing type mungers
when
weaving
[Xlint:cantFindType]
[org.eclipse.jface] error can't
determine modifiers of missing type org.eclipse.pde.internal.ui.wizards.plugin.NewPluginProjectWizard
when
processing type mungers org.eclipse.jface.dialogs.IDialogSettings
when
processing type mungers
when
weaving
[Xlint:cantFindType]
[org.eclipse.jface] error can't
determine modifiers of missing type org.eclipse.pde.internal.ui.wizards.plugin.NewPluginProjectWizard
when
processing type mungers org.eclipse.jface.preference.PreferenceManager
when
processing type mungers
when
weaving
…
…
The manifest of the plug-in project containing the
aspect:
Manifest-Version:
1.0
Bundle-ManifestVersion: 2
Bundle-Name: Repository Plug-in
Bundle-SymbolicName:
org.highlevelaj.repository
Bundle-Version: 1.0.0
Bundle-Activator:
org.highlevelaj.repository.Activator
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
org.aspectj.runtime;visibility:=reexport,
org.highlevelaj,
org.eclipse.pde.ui
Eclipse-LazyStart:
true
Export-Package: org.aspectj,
org.highlevelaj.repository
Eclipse-SupplementBundle:
org.eclipse.pde.ui, org.eclipse.jface