[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [aspectj-dev] declare annotation
|
Andrew Clement wrote:
thats odd - it works for me... oh hang on I've not committed it yet :)
Declare annotation is fully implemented and will be in a build in the
next day or so !
However, the actual syntax is:
declare @type: BierWerbung: @PremiumPartner;
thanks, now it compiles. But nevertheless it seems not to work. Here my
test cases (PremiumPartner has RetentionPolicy.RUNTIME):
public void testAnnotatedClass() {
checkAnnotation(Artikel.class);
}
public void testAnnotatedAspect() {
checkAnnotation(BierWerbung.class);
}
private void checkAnnotation(Class<? extends Object> cl) {
Annotation a = cl.getAnnotation(PremiumPartner.class);
assertNotNull(a);
}
Yesterday I updated to the latest AJDT build - is the implementation
inside or do I have to wait for the next build?
with related variants
declare @method: <method sig>: @<someannotation>
declare @constructor: <constructor sig>: @<someannotation>
declare @field: <field sig>: @<someannotation>
thank you for the syntax - I will test it in the next days...
have a nice weekend
Oliver
--
Oliver Böhm
http://www.javatux.de