Top Description Fields Constructors Methods
org.apache.sshd.common.future

public final Enum CancelOption

extends Enum<CancelOption>
Class Inheritance

A CancelOption defines whether a Cancellable future that is waited upon shall be cancelled if waiting times out or is interrupted.
See Also
VerifiableFuture, WaitableFuture

Field Summary

Modifier and TypeField and Description
public static final CancelOption
CANCEL_ON_INTERRUPT

Indicates that when waiting on a future is interrupted, the future shall be canceled.

public static final CancelOption
CANCEL_ON_TIMEOUT

Indicates that when waiting on a future times out, the future shall be canceled.

public static final CancelOption
NO_CANCELLATION

Indicates that even if waiting on a future times out or is interrupted, it shall not be canceled.

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static CancelOption
public static CancelOption[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

CANCEL_ON_INTERRUPTback to summary
public static final CancelOption CANCEL_ON_INTERRUPT

Indicates that when waiting on a future is interrupted, the future shall be canceled.

CANCEL_ON_TIMEOUTback to summary
public static final CancelOption CANCEL_ON_TIMEOUT

Indicates that when waiting on a future times out, the future shall be canceled.

NO_CANCELLATIONback to summary
public static final CancelOption NO_CANCELLATION

Indicates that even if waiting on a future times out or is interrupted, it shall not be canceled.

CANCEL_ON_TIMEOUT and CANCEL_ON_INTERRUPT take precedence over this flag. The main purpose of this flag is to be able to call verify(timeout, NO_CANCELLATION) to suppress cancelling a future on time-outs or interrupts altogether. By default, verify(timeout) will cancel the future on both time-outs and interrupts.

Constructor Detail

CancelOptionback to summary
private CancelOption()

Method Detail

valueOfback to summary
public static CancelOption valueOf(String name)
valuesback to summary
public static CancelOption[] values()