[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[List Home]
|
[aspectj-users] Weaving on UI paint methods isn't working for me :f
|
- From: FraGMenT <poemcompiler@xxxxxxxxx>
- Date: Tue, 14 Jul 2009 18:52:24 +0200
- Delivered-to: aspectj-users@eclipse.org
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=wIPIfIsg4E7ppCMjtx2++l/l/ZrmpHMM0MdNcTdUVhQ=; b=JJeKPt1syeD5TO4bMq1/ElvLoo38CA96mZfsoywEM3EV1tJ9GosNYl+oryQQ8/cf7T 9qeD//OtAifM14ZHJq9PE6qTPqHj/Ok41PNfGkOyIdshuvzZB9e5LieGxQ11b2Gfu7u8 XWbRohxzQ0kRL8FYBzuFRwPM/TeH3xctd6nyo=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=UyeSHaPO2hp1bmchkFlDygQqtWpWbl0y5Pgt00yWAkEGgmFLxR69Q7W+taQyWnLkDI gJGL9AxTLkYweumk0FNabDR8/26dHLsv/XmdktFxqwTsDh+OvNkHOjXyo52IxTHQFujh BgjCdMRy7uDr3YxjrXDgtc/30NDJ2teO3S8eY=
Hello.
Hello, I want to execute some code using aspectj before any element of the UI is drawn.
To do that, I define the following pointcut:
pointcut gonnaBeDrawn() :
execution(public void java.awt.Component+.repaint()) ||
execution(public void java.awt.Component+.update(Graphics))||
execution(public void java.awt.Component+.paint(Graphics))||
execution(public void java.awt.Component+.paintAll(Graphics));
Then the advice:
before() : gonnaBeDrawn()
{
System.out.println("Component drawn!");
}
As far as I know this should do the work, but I don't get any expected message on the console. I get the following warning at compile time though.
advice defined in main.Prueba has not been applied [Xlint:adviceDidNotMatch] (The file's name is main.Prueba.aj)
Other aspects are working fine, so I think it's not a problem of environment configuration.
What am I doing wrong? Do I need to do Load Time Weaving or something?
Thanks for your time! ^^'