public class DefaultOpenFuture extends DefaultSshFuture<OpenFuture> implements OpenFuture
OpenFuture.log| Constructor and Description |
|---|
DefaultOpenFuture(Object lock) |
| Modifier and Type | Method and Description |
|---|---|
Throwable |
getException()
Returns the cause of the connection failure.
|
boolean |
isOpened() |
void |
setException(Throwable exception)
Sets the exception caught due to connection failure and notifies all
threads waiting for this future.
|
void |
setOpened()
Sets the newly connected session and notifies all threads waiting for
this future.
|
void |
verify()
Wait and verify that the channel has been successfully opened.
|
void |
verify(long timeoutMillis)
Wait and verify that the channel has been successfully opened.
|
void |
verify(long timeout,
TimeUnit unit)
Wait and verify that the channel has been successfully opened.
|
addListener, await, await, await, await0, awaitUninterruptibly, awaitUninterruptibly, awaitUninterruptibly, cancel, getValue, isCanceled, isDone, removeListener, setValue, verifyResultclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcancel, isCanceledaddListener, await, await, await, awaitUninterruptibly, awaitUninterruptibly, awaitUninterruptibly, isDone, removeListenerpublic DefaultOpenFuture(Object lock)
public void verify()
throws IOException
OpenFutureverify in interface OpenFutureIOException - if the action failed for any reasonpublic void verify(long timeout,
TimeUnit unit)
throws IOException
OpenFutureverify in interface OpenFuturetimeout - The number of time units to waitunit - The wait TimeUnitIOException - If failed to verify successfully on timepublic void verify(long timeoutMillis)
throws IOException
OpenFutureverify in interface OpenFuturetimeoutMillis - Wait timeout in millisecondsIOException - If failed to verify successfully on timepublic Throwable getException()
OpenFuturegetException in interface OpenFuturenull if the connect operation is not finished yet,
or if the connection attempt is successful.public boolean isOpened()
isOpened in interface OpenFuturetrue if the connect operation is finished successfully.public void setOpened()
OpenFuturesetOpened in interface OpenFuturepublic void setException(Throwable exception)
OpenFuturesetException in interface OpenFutureexception - The caught ThrowableCopyright © 2008–2015 The Apache Software Foundation. All rights reserved.