public class WaarpFailedFuture extends WaarpCompletedFuture
Constructor and Description |
---|
WaarpFailedFuture(Throwable cause)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
Throwable |
getCause()
Returns the cause of the failed operation if the operation has failed.
|
boolean |
isSuccess()
Returns
true if and only if the operation was completed successfully. |
WaarpFuture |
rethrowIfFailed()
Rethrows the exception that caused this future fail if this future is complete and failed.
|
await, await, await, awaitUninterruptibly, awaitUninterruptibly, awaitUninterruptibly, cancel, isCancelled, isDone, setFailure, setSuccess
isFailed, reset
public WaarpFailedFuture(Throwable cause)
cause
- the cause of failurepublic Throwable getCause()
WaarpFuture
getCause
in class WaarpFuture
null
if succeeded or this future is not completed
yet.public boolean isSuccess()
WaarpFuture
true
if and only if the operation was completed successfully.isSuccess
in class WaarpFuture
public WaarpFuture rethrowIfFailed() throws Exception
WaarpFuture
rethrowIfFailed
in class WaarpFuture
Exception
Copyright © 2009–2019 Waarp. All rights reserved.