[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [aspectj-users] execution() pointcut is advicing inner enum???
|
Kostas,
>I think the around advice is trying to advice the enum!!! Is this a
bug
>of the aspectj compiler or am I doing something wrong?
Correct. No. An enum is basically a
class and the pointcut will match so take care with such broad wildcards.
Matthew Webster
AOSD Project
Java Technology Centre, MP146
IBM United Kingdom Limited
Hursley Park, Winchester, SO21 2JN, England
Telephone: +44 196 2816139 (external) 246139 (internal)
"Kostas Kougios"
<Kostas.Kougios@xxxxxxxxxxxxx>
Sent by: aspectj-users-bounces@xxxxxxxxxxx
28/03/2007 15:29
Please respond to
aspectj-users@xxxxxxxxxxx |
|
To
| <aspectj-users@xxxxxxxxxxx>
|
cc
|
|
Subject
| [aspectj-users] execution() pointcut
is advicing inner enum??? |
|
Hi,
I've this aspect:
...
pointcut repositoryMethods():execution(* *(..)) && within (*..dao..*);
Object around():repositoryMethods()
{
....
I also have a Dao class which has an inner enum:
Public class MyDao
{
....
enum CreateQueryOp
{
FILTER,
COUNTONLY;
}
}
When I do a clean build, I get the following error:
serialVersionUID of type MyDao$CreateQueryOp needs to be set because of
added non-private method valueOf_aroundBody2
[Xlint:needsSerialVersionUIDField]
I think the around advice is trying to advice the enum!!! Is this a bug
of the aspectj compiler or am I doing something wrong?
I've moved the enum decl out of the class and added a serialVersionUID
and it compiles correctly.
Thanks,
Kostas
______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________
_______________________________________________
aspectj-users mailing list
aspectj-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/aspectj-users
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU