Class BalancedClientFuture<V>

  • Type Parameters:
    V - The type that result from completion of this Future
    All Implemented Interfaces:
    java.util.concurrent.Future<V>, AsyncResult<V>

    public class BalancedClientFuture<V>
    extends ClientFuture<V>
    A more balanced implementation of a ClientFuture that works better on some platforms such as windows where the thread park and atomic operations used by a more aggressive implementation could result in poor performance.
    • Method Detail

      • get

        public V get​(long amount,
                     java.util.concurrent.TimeUnit unit)
              throws java.lang.InterruptedException,
                     java.util.concurrent.ExecutionException,
                     java.util.concurrent.TimeoutException
        Specified by:
        get in interface java.util.concurrent.Future<V>
        Specified by:
        get in class ClientFuture<V>
        Throws:
        java.lang.InterruptedException
        java.util.concurrent.ExecutionException
        java.util.concurrent.TimeoutException
      • get

        public V get()
              throws java.lang.InterruptedException,
                     java.util.concurrent.ExecutionException
        Specified by:
        get in interface java.util.concurrent.Future<V>
        Specified by:
        get in class ClientFuture<V>
        Throws:
        java.lang.InterruptedException
        java.util.concurrent.ExecutionException