|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.atmosphere.wasync.util.FutureProxy<T>
public class FutureProxy<T extends java.util.concurrent.Future>
| Constructor Summary | |
|---|---|
FutureProxy(Socket socket,
T proxyiedFuture)
|
|
| Method Summary | |
|---|---|
boolean |
cancel(boolean mayInterruptIfRunning)
|
void |
close()
Close the underlying Socket |
void |
done()
Mark this instance as done. |
Future |
finishOrThrowException()
Mark the future done. |
Future |
fire(java.lang.Object data)
Send data to the remote Server. |
Socket |
get()
|
Socket |
get(long timeout,
java.util.concurrent.TimeUnit unit)
|
Future |
ioException(java.io.IOException t)
If an exception occurs, the Transport will set it using this method. |
boolean |
isCancelled()
|
boolean |
isDone()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FutureProxy(Socket socket,
T proxyiedFuture)
| Method Detail |
|---|
public Future fire(java.lang.Object data)
throws java.io.IOException
Future
data - the message to fire
Future
java.io.IOException
public Future finishOrThrowException()
throws java.io.IOException
Future
Future
java.io.IOExceptionpublic Future ioException(java.io.IOException t)
FutureTransport will set it using this method. An application can also
use that method to interrupt a blocking Socket.open(Request) operation. This operation
must unlock the current blocked thread.
t - a IOException
Futurepublic void done()
Future
public boolean cancel(boolean mayInterruptIfRunning)
cancel in interface java.util.concurrent.Future<Socket>public boolean isCancelled()
isCancelled in interface java.util.concurrent.Future<Socket>public boolean isDone()
isDone in interface java.util.concurrent.Future<Socket>
public Socket get()
throws java.lang.InterruptedException,
java.util.concurrent.ExecutionException
get in interface java.util.concurrent.Future<Socket>java.lang.InterruptedException
java.util.concurrent.ExecutionException
public Socket get(long timeout,
java.util.concurrent.TimeUnit unit)
throws java.lang.InterruptedException,
java.util.concurrent.ExecutionException,
java.util.concurrent.TimeoutException
get in interface java.util.concurrent.Future<Socket>java.lang.InterruptedException
java.util.concurrent.ExecutionException
java.util.concurrent.TimeoutExceptionpublic void close()
FutureSocket
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||