mirror of
https://github.com/eclipse-aspectj/aspectj.git
synced 2024-08-16 02:10:48 +02:00
30 lines
605 B
Java
30 lines
605 B
Java
import java.lang.annotation.*;
|
|
|
|
@Retention(RetentionPolicy.RUNTIME)
|
|
@interface Annot {}
|
|
|
|
@Retention(RetentionPolicy.RUNTIME)
|
|
@interface Foo {}
|
|
|
|
class Person {
|
|
@Foo
|
|
public void foo() {}
|
|
@Foo
|
|
public boolean bar() {return false;}
|
|
@Foo
|
|
public String getString() { return null; }
|
|
@Foo
|
|
public boolean isSet() { return false; }
|
|
@Foo
|
|
public void isNotReturningBoolean() { }
|
|
|
|
public void getin() {}
|
|
}
|
|
|
|
aspect DAMethod2 {
|
|
|
|
declare @method: !(* *.get*()) && !(* aspectOf(..)) && !(* hasAspect(..)): @Annot;
|
|
|
|
declare @method: !@Foo * *(..) && !(* aspectOf(..)) && !(* hasAspect(..)): @Annot;
|
|
}
|