How to use AOP to intercept a method call in super on an argument?
- by hleinone
I'm extending a class and overriding a method. All I want to do is to call super, but with a modified argument that gets intercepted upon one of its methods is called. An example makes it more clear:
// Foo is an interface and also this method is part of an interface
@Override
public void foo(Foo foo) {
// I want to intercept the call to foo.bar() in super
super.foo(foo);
}
I'd rather use a tool that doesn't require a compiler of its own. What would be the optimal one?