[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [aspectj-users] Interface Constructors
|
Hi Matthew,
Being able to discriminate between interfaces and classes was a feature request I made for 1.1. My motivation was to allow enforcing policies like "return only interfaces from the domain tier, not classes (implementations)."
I don't believe you can do it in general with AspectJ 1.1. For a specific project you can use naming patterns, package structuring, or enumeration to identify interfaces.
Ron
Ron Bodkin
Chief Technology Officer
New Aspects of Security
m: (415) 509-2895
> ------------Original Message-------------
> From: "Matthew Webster" <matthew_webster@xxxxxxxxxx>
> To: aspectj-users@xxxxxxxxxxx
> Date: Mon, Aug-18-2003 6:46 AM
> Subject: [aspectj-users] Interface Constructors
>
> If I use the pointcut:
>
> execution (*.new(..));
>
> I will advise the execution of all constructors including interface types.
> Can I exclude interface types without having to enumerate them? Using the
> following scope (interface types do not descend from Object):
>
> within(java.lang.Object+)
>
> does not work.
>
> Thanks.
>
> Matthew Webster
> AOSD Project
> Java Technology Centre, MP146
> IBM Hursley Park, Winchester, SO21 2JN, England
> Telephone: +44 196 2816139 (external) 246139 (internal)
> Email: Matthew Webster/UK/IBM @ IBMGB, matthew_webster@xxxxxxxxxx
> http://w3.hursley.ibm.com/~websterm/
>
> The IBM Academy is sponsoring a conference on Aspect-Oriented Software
> Development, 3rd-4th September, Yorktown, NY.
>
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> http://dev.eclipse.org/mailman/listinfo/aspectj-users
>