Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] Modifying the parameters of methods with arbitrary signatures

I want to use aspectj to provide a generic interceptor framework where we can plug in code at any point to modify input parameters to our methods.

Ideally, what I want is something like this, but I'm not sure how to accomplish it in aspectj (this uses a bastardization of the Java5 varargs syntax, below, for illustrative purposes).

around(Object... args): methodPointCut(args(args)) {
    newArgs = invokeHook (args);
    proceed(newArgs);
}

Is there any way to do this without needing to enumerate the parameters in the aspect?

--
Chris Rose
Developer    Planet Consulting Group
(780) 577-8433
crose@xxxxxxxxxxxx


Back to the top