|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.aop.framework.JdkDynamicAopProxy
InvocationHandler implementation for the Spring AOP framework, based on J2SE 1.3+ dynamic proxies.
Creates a J2SE proxy, implementing the interfaces exposed by the proxy. Dynamic proxies cannot be used to proxy methods defined in classes, rather than interface.
Objects of this type should be obtained through proxy factories, configured by an AdvisedSupport class. This class is internal to the Spring framework and need not be used directly by client code.
Proxies created using this class will be threadsafe if the underlying (target) class is threadsafe.
Proxies are serializable so long as all Advisors are serializable (meaning both Advices and Pointcuts) and the TargetSource is serializable.
Proxy
,
AdvisedSupport
,
ProxyFactory
Constructor Summary | |
protected |
JdkDynamicAopProxy(AdvisedSupport config)
Construct a new JDK proxy. |
Method Summary | |
boolean |
equals(Object other)
Equality means interfaces, advisors and TargetSource are equal. |
Object |
getProxy()
Create a new Proxy object for the given object. |
Object |
getProxy(ClassLoader classLoader)
Create a new Proxy object for the given object. |
int |
hashCode()
Proxy uses the hash code of the TargetSource. |
Object |
invoke(Object proxy,
Method method,
Object[] args)
Implementation of InvocationHandler.invoke. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected JdkDynamicAopProxy(AdvisedSupport config) throws AopConfigException
AopConfigException
- if the config is invalid. We try
to throw an informative exception in this case, rather than let
a mysterious failure happen later.Method Detail |
public Object getProxy()
AopProxy
getProxy
in interface AopProxy
Thread.getContextClassLoader()
public Object getProxy(ClassLoader classLoader)
AopProxy
getProxy
in interface AopProxy
classLoader
- the class loader to usepublic Object invoke(Object proxy, Method method, Object[] args) throws Throwable
invoke
in interface InvocationHandler
Throwable
public int hashCode()
public boolean equals(Object other)
other
- may be a dynamic proxy wrapping an instance of this classObject.equals(java.lang.Object)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |