public Object invoke(Invocation invocation) throws Throwable
{
System.out.println("YourInterceptor.invoke()");
if (invocation instanceof ConstructorInvocation)
{
ConstructorInvocation ci = (ConstructorInvocation)invocation;
Interceptions.addConstructorInterception(this.getClass(), ci.getConstructor());
}
if (invocation instanceof ConstructionInvocation)
{
ConstructionInvocation ci = (ConstructionInvocation)invocation;
Interceptions.addConstructionInterception(this.getClass(), ci.getConstructor());
}
else if (invocation instanceof MethodInvocation)
{
MethodInvocation mi = (MethodInvocation)invocation;
Interceptions.addMethodInterception(this.getClass(), mi.getMethod());