org.apache.thrift.async
Class TAsyncClient
java.lang.Object
org.apache.thrift.async.TAsyncClient
public abstract class TAsyncClient
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
protocolFactory
protected final TProtocolFactory protocolFactory
transport
protected final TNonblockingTransport transport
manager
protected final TAsyncClientManager manager
currentMethod
protected TAsyncMethodCall currentMethod
TAsyncClient
public TAsyncClient(TProtocolFactory protocolFactory,
TAsyncClientManager manager,
TNonblockingTransport transport)
TAsyncClient
public TAsyncClient(TProtocolFactory protocolFactory,
TAsyncClientManager manager,
TNonblockingTransport transport,
long timeout)
getProtocolFactory
public TProtocolFactory getProtocolFactory()
getTimeout
public long getTimeout()
hasTimeout
public boolean hasTimeout()
setTimeout
public void setTimeout(long timeout)
hasError
public boolean hasError()
- Is the client in an error state?
- Returns:
getError
public java.lang.Exception getError()
- Get the client's error - returns null if no error
- Returns:
checkReady
protected void checkReady()
onComplete
protected void onComplete()
- Called by delegate method when finished
onError
protected void onError(java.lang.Exception exception)
- Called by delegate method on error