java.lang.Object
org.activemq.util.AsyncProxy
- All Implemented Interfaces:
- java.lang.reflect.InvocationHandler
- public class AsyncProxy
- extends java.lang.Object
- implements java.lang.reflect.InvocationHandler
A proxy to some service which offers an asynchronous way to invoke methods which
are void and don't throw exceptions. Calling the method results in a command object
being added to a queue for later execution.
- Version:
- $Revision: 1.1.1.1 $
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
realObject
private java.lang.Object realObject
executor
private EDU.oswego.cs.dl.util.concurrent.Executor executor
log
private org.apache.commons.logging.Log log
AsyncProxy
public AsyncProxy(java.lang.Object realObject,
EDU.oswego.cs.dl.util.concurrent.Executor executor)
AsyncProxy
public AsyncProxy(java.lang.Object realObject,
EDU.oswego.cs.dl.util.concurrent.Executor executor,
org.apache.commons.logging.Log log)
AsyncProxy
public AsyncProxy(EDU.oswego.cs.dl.util.concurrent.Executor executor,
org.apache.commons.logging.Log log)
createProxy
public static java.lang.Object createProxy(java.lang.Class interfaceType,
java.lang.Object realObject,
EDU.oswego.cs.dl.util.concurrent.Executor executor)
invoke
public java.lang.Object invoke(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args)
throws java.lang.Throwable
- Description copied from interface:
java.lang.reflect.InvocationHandler
- When a method is invoked on a proxy instance, it is wrapped and
this method is called instead, so that you may decide at runtime
how the original method should behave.
- Specified by:
invoke in interface java.lang.reflect.InvocationHandler
doAsyncMethodInvoke
protected void doAsyncMethodInvoke(java.lang.reflect.Method method,
java.lang.Object[] args)