Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-dev] AJ 5 @AJ and aspectOf

I have started to have a look at APT.
This one could easily be used to handle aspectOf() for @AJ aspect.

Right now aspectOf is introduced to the @AJ aspect (compile time with
ajc or LTW), and the user can use an API like
Aspect*s*.aspectOf(MyAspect.class) 
Aspect*s*.aspectOf(MyAspect.class, Object perX instance)
etc that behaves reflectively

APT could be used to generated (source gen) for each @AJ aspect MyAspect a class
MyAspectFactory that contains the static aspectOf method and binding /
unbinding methods.
The user could then easily invoke MyAspect MyAspectFactory.aspectOf() 
in his code, without any performance drawback, without beeing required
to expose its aspect to LTW or ajc compilation and use them as binary 
form.

thoughts ?
Alex


Back to the top