CloseFuture, IoFuturepublic class DefaultCloseFuture extends DefaultIoFuture implements CloseFuture
CloseFuture.| Constructor | Description |
|---|---|
DefaultCloseFuture(IoSession session) |
Creates a new instance.
|
| Modifier and Type | Method | Description |
|---|---|---|
CloseFuture |
addListener(IoFutureListener<?> listener) |
Adds an event listener which is notified when
this future is completed.
|
CloseFuture |
await() |
Wait for the asynchronous operation to complete.
|
CloseFuture |
awaitUninterruptibly() |
Wait for the asynchronous operation to complete uninterruptibly.
|
boolean |
isClosed() |
|
CloseFuture |
removeListener(IoFutureListener<?> listener) |
Removes an existing event listener so it won't be notified when
the future is completed.
|
void |
setClosed() |
Marks this future as closed and notifies all threads waiting for this
future.
|
await, await, awaitUninterruptibly, awaitUninterruptibly, getSession, getValue, isDone, join, join, setValueawait, await, awaitUninterruptibly, awaitUninterruptibly, getSession, isDone, join, joinpublic DefaultCloseFuture(IoSession session)
session - The associated sessionpublic boolean isClosed()
isClosed in interface CloseFuturepublic void setClosed()
setClosed in interface CloseFuturepublic CloseFuture await() throws InterruptedException
await in interface CloseFutureawait in interface IoFutureawait in class DefaultIoFutureInterruptedException - If the thread is interrupted while waitingpublic CloseFuture awaitUninterruptibly()
awaitUninterruptibly in interface CloseFutureawaitUninterruptibly in interface IoFutureawaitUninterruptibly in class DefaultIoFuturepublic CloseFuture addListener(IoFutureListener<?> listener)
addListener in interface CloseFutureaddListener in interface IoFutureaddListener in class DefaultIoFuturelistener - The listener to addpublic CloseFuture removeListener(IoFutureListener<?> listener)
removeListener in interface CloseFutureremoveListener in interface IoFutureremoveListener in class DefaultIoFuturelistener - The listener to removeCopyright © 2004–2018 Apache MINA Project. All rights reserved.