Enum DisabledFuture
- java.lang.Object
-
- java.lang.Enum<DisabledFuture>
-
- com.github.benmanes.caffeine.cache.DisabledFuture
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<DisabledFuture>
,java.util.concurrent.Future<java.lang.Void>
enum DisabledFuture extends java.lang.Enum<DisabledFuture> implements java.util.concurrent.Future<java.lang.Void>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description INSTANCE
-
Constructor Summary
Constructors Modifier Constructor Description private
DisabledFuture()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
cancel(boolean mayInterruptIfRunning)
java.lang.Void
get()
java.lang.Void
get(long timeout, java.util.concurrent.TimeUnit unit)
boolean
isCancelled()
boolean
isDone()
static DisabledFuture
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static DisabledFuture[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
INSTANCE
public static final DisabledFuture INSTANCE
-
-
Method Detail
-
values
public static DisabledFuture[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (DisabledFuture c : DisabledFuture.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static DisabledFuture valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
isDone
public boolean isDone()
- Specified by:
isDone
in interfacejava.util.concurrent.Future<java.lang.Void>
-
isCancelled
public boolean isCancelled()
- Specified by:
isCancelled
in interfacejava.util.concurrent.Future<java.lang.Void>
-
cancel
public boolean cancel(boolean mayInterruptIfRunning)
- Specified by:
cancel
in interfacejava.util.concurrent.Future<java.lang.Void>
-
get
public java.lang.Void get() throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
- Specified by:
get
in interfacejava.util.concurrent.Future<java.lang.Void>
- Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
-
get
public java.lang.Void get(long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException, java.util.concurrent.TimeoutException
- Specified by:
get
in interfacejava.util.concurrent.Future<java.lang.Void>
- Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
java.util.concurrent.TimeoutException
-
-