public class DynamicallyCreatedTransientAdvice extends AroundAdvice {
public DynamicallyCreatedTransientAdvice() {
super();
}
public Object execute(final JoinPoint joinPoint) throws Throwable {
MethodJoinPoint jp = (MethodJoinPoint)joinPoint;
((Loggable)jp.getTargetObject()).log("before ");
final Object result = joinPoint.proceed();
((Loggable)jp.getTargetObject()).log("after ");
return result;
}