if?(!this.equalsDefined?&&?AopUtils.isEqualsMethod(method)){??
return?(equals(args[0])??Boolean.TRUE?:?Boolean.FALSE);??
} ?
//hashCode()方法,具目標對象未實現(xiàn)此方法??
if?(!this.hashCodeDefined?&&?AopUtils.isHashCodeMethod(method)){??
return?newInteger(hashCode());??
} ?
//Advised接口或者其父接口中定義的方法,直接反射調用,不應用通知??
if?(!this.advised.opaque?&&method.getDeclaringClass().isInterface()??
&&method.getDeclaringClass().isAssignableFrom(Advised.class))?{??
//?Service?invocations?onProxyConfig?with?the?proxy?config...??
return?AopUtils.invokeJoinpointUsingReflection(this.advised,method,?args);??
}??
Object?retVal?=?null; ?
if?(this.advised.exposeProxy)?{??
//?Make?invocation?available?ifnecessary.??
oldProxy?=?AopContext.setCurrentProxy(proxy);??
setProxyContext?=?true;??
} ?
//獲得目標對象的類??
target?=?targetSource.getTarget();??
if?(target?!=?null)?{??
targetClass?=?target.getClass();??
} ?
//獲取可以應用到此方法上的Interceptor列表??
評論
查看更多