[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
RE: [aspectj-users] Get annotation value on field setting
|
Hi
Andy,
Thanks
for this information, I had not seen your post.
I
will use this new annotation binding quickly and I will subscribing
now to aspect-dev mailing list ;-).
Thanks
a lot Andy.
Cheers,
Mickaël
In case you haven't seen my
post to aspectj-dev@xxxxxxxxxxx, annotation
binding is now working in the dev codebase.
So, this will work:
before(MyAnnot mine) : set(String myField) &&
@annotation(mine) {
System.out.println(mine.value());
}
Current dev build is available from the AspectJ download page -
an
AJDT with it in is imminent.
cheers,
Andy.
Rifflard Mickaël
<Mickael.Rifflard@xxxxxxxxxxxxxx> Sent by: aspectj-users-admin@xxxxxxxxxxx
31/01/2005 10:47
Please respond
to aspectj-users@xxxxxxxxxxx |
|
To
| <aspectj-users@xxxxxxxxxxx>
|
cc
|
|
Subject
| RE: [aspectj-users] Get
annotation value on field setting |
|
Hi Wes,
I like this solution.
I wait with much impatience
its implementation (M2 ?)
Mickaël RIFFLARD
(Atos
Origin)
-----Message d'origine-----
De :
aspectj-users-admin@xxxxxxxxxxx
[mailto:aspectj-users-admin@xxxxxxxxxxx]De
la part de Wes Isberg
Envoyé : lundi 31 janvier 2005 11:37
À :
aspectj-users@xxxxxxxxxxx
Objet : Re: [aspectj-users] Get annotation value
on field setting
The AspectJ 5 developer's notebook suggests this
should work:
before(MyAnnot mine) : set(String myField)
&& @annotation(mine) {
System.out.println("test.something=" +
test.something());
}
But binding is not implemented yet for
annotations.
Wes
> ------------Original
Message------------
> From: Rifflard Mickaël
<Mickael.Rifflard@xxxxxxxxxxxxxx>
> To:
aspectj-users@xxxxxxxxxxx
> Date: Mon, Jan-31-2005 1:06 AM
>
Subject: [aspectj-users] Get annotation value on field setting
>
>
Hi,
>
> I try to retrieve an annotation value of a field during
its setting.
>
> Exemple :
>
>
public class MyClass {
>
>
@MyAnnot(test)
>
public String myField;
>
>
public void myMethod() {
>
...
>
// Try to
get myField annotation value here
>
this.myField = "newValue";
>
...
>
}
>
}
>
> How to obtain this information (test) without reflexion ?
>
> Thanks,
>
> Mickaël Rifflard
> (Atos
Origin)
>
>
_______________________________________________
> aspectj-users mailing
list
> aspectj-users@xxxxxxxxxxx
>
http://dev.eclipse.org/mailman/listinfo/aspectj-users
>
_______________________________________________
aspectj-users
mailing
list
aspectj-users@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/aspectj-users