Class ReadyFuture<T>

java.lang.Object
com.axemble.vdoc.sdk.viewer.ReadyFuture<T>
Type Parameters:
T - the result type to hold
All Implemented Interfaces:
Future<T>

public class ReadyFuture<T> extends Object implements Future<T>
A ready future who hold the result
  • Constructor Details

    • ReadyFuture

      public ReadyFuture(T result)
      create a future with it's result
      Parameters:
      result - the result
  • Method Details

    • cancel

      public boolean cancel(boolean mayInterruptIfRunning)
      Specified by:
      cancel in interface Future<T>
    • isCancelled

      public boolean isCancelled()
      Specified by:
      isCancelled in interface Future<T>
    • isDone

      public boolean isDone()
      Specified by:
      isDone in interface Future<T>
    • get

      public T get()
      Specified by:
      get in interface Future<T>
    • get

      public T get(long timeout, TimeUnit unit)
      Specified by:
      get in interface Future<T>