[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] Type Patterns in declare statements

What you got is pretty much as good as it gets!


On Dec 19, 2007 4:13 PM, neil loughran <loughran@xxxxxxxxxxxxxxxx> wrote:
Lots of questions today ;-)

Was just wondering if it is possible to use some kind of type pattern within
declare parents statements?

For example given the following class that I want to serialise

class Foo {
private Bar a;
private Far b;


Can I write the following in a single statement by somehow just referring to
Foo i.e. Foo and all members in Foo..?

declare parents: Foo implements Serializable;
declare parents: Bar implements Serializable;
declare parents: Far implements Serializable;

I know I can also write

declare parents: (Foo || Bar || Far) implements Serializable;

but was just wondering if there were some additional
operators/designators/tricks/idioms I could utilise for expressing "Foo and
all members within Foo" without resorting to the above.


Neil Loughran

aspectj-users mailing list