public CachingAdvice() {
super();
}
public Object execute(final JoinPoint joinPoint) throws Throwable {
MethodJoinPoint jp = (MethodJoinPoint)joinPoint;
final Long hash = new Long(calculateHash(jp));
final Object cachedResult = m_cache.get(hash);
if (cachedResult != null) {
System.out.println("using cache");
CacheStatistics.addCacheInvocation(jp.getMethodName(), jp.getParameterTypes());
return cachedResult;
}
final Object result = joinPoint.proceed();