Package org.apache.sshd.common.future
Class DefaultCloseFuture
java.lang.Object
org.apache.sshd.common.util.logging.AbstractLoggingBean
org.apache.sshd.common.future.AbstractSshFuture<CloseFuture>
org.apache.sshd.common.future.DefaultSshFuture<CloseFuture>
org.apache.sshd.common.future.DefaultCloseFuture
- All Implemented Interfaces:
CloseFuture,SshFuture<CloseFuture>,WaitableFuture
A default implementation of
CloseFuture.-
Field Summary
Fields inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
log -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.sshd.common.future.DefaultSshFuture
addListener, await0, createCancellation, getNumRegisteredListeners, getValue, isDone, notifyListeners, onValueSet, removeListener, setValue, toStringMethods inherited from class org.apache.sshd.common.future.AbstractSshFuture
asListener, asT, await, awaitUninterruptibly, formatExceptionMessage, getId, notifyListener, verifyResultMethods inherited from class org.apache.sshd.common.util.logging.AbstractLoggingBean
debug, debug, debug, debug, debug, error, error, error, error, error, getSimplifiedLogger, info, info, warn, warn, warn, warn, warn, warn, warn, warnMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.sshd.common.future.SshFuture
addListener, removeListenerMethods inherited from interface org.apache.sshd.common.future.WaitableFuture
await, await, await, await, awaitUninterruptibly, awaitUninterruptibly, awaitUninterruptibly, awaitUninterruptibly, getId, isDone
-
Constructor Details
-
DefaultCloseFuture
Create a new instance- Parameters:
id- Some identifier useful astoString()valuelock- A synchronization object for locking access - ifnullthen synchronization occurs onthisinstance
-
-
Method Details
-
isClosed
public boolean isClosed()- Specified by:
isClosedin interfaceCloseFuture- Returns:
- true if the close request is finished and the target is closed.
-
setClosed
public void setClosed()Description copied from interface:CloseFutureMarks this future as closed and notifies all threads waiting for this future. This method is invoked by SSHD internally. Please do not call this method directly.- Specified by:
setClosedin interfaceCloseFuture
-