Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] Newbie question on inter-type member declarations

Hi -
 
Replies inline...
 
------------Original Message------------
From: "Are Meisfjord" <are@xxxxxxxxxxxxx>
To: aspectj-users@xxxxxxxxxxx
Date: Tue, Aug-10-2004 5:56 AM
Subject: Re: [aspectj-users] Newbie question on inter-type member declarations
Hi, Wes,
 
 
Thanks a lot for your answer and your suggestions! I have a couple of follow-up questions though, if you don't mind.
 
[Wes]
Your case is classic generative programming, of applying a rule to create code.  AspectJ if anything is moving away from that.
 
As mentioned before I'm new to AOP, and that's probably why this statement puzzles me a little. Because I thought AspectJ was exactly that: applying rules (pointcuts) to generate code (advice)...?
 
A pointcut is a predicate that can pick out a join point.  Advice runs at a join point, but
is written by the programmer.  Similarly for inter-type declarations.  The main difference between
aspects and classes is that aspects also support crosscutting.  Some crosscutting can be
implemented through generating code, but that's not how we do it (any more).
 
 
 
[Wes]
ITMD's since AspectJ 1.1 have their type resolved at compile-time, mainly to support incremental weaving.
 
Sounds like a good idea to do as much as possible at compile-time. But I can't see why the ITMD types can't be resolved at compile time in my case?
 
Syntactically, since 1.1 they take a type rather than a type pattern, and what you suggested
was more like a type pattern in that it would match many types.
 
 
 
[Wes]
We thought that it would be better to strongly separate generative programming from AspectJ than to continue or expand support for it.
 
Do you (or anybody else) know if there are any generative programming tools available with IDE integration (preferably Eclipse)?  (Btw, I really like the Eclipse integration of AspectJ! I just tried setting a breakpoint inside an advice, which worked smoothly. Nice!)
 
I agree with Adrian's suggestion to check out JET, but haven't myself verified that AJDT
plays nicely with JET.  I suspect that the JET-generated classes should be in another
project and included as binaries using -inpath.
 
 
Best regards,
 
 
Are Meisfjord
 

Back to the top