net.spy.memcached.internal
Class GetFuture<T>

java.lang.Object
  extended by net.spy.memcached.internal.GetFuture<T>
Type Parameters:
T - Type of object returned from the get
All Implemented Interfaces:
java.util.concurrent.Future<T>

public class GetFuture<T>
extends java.lang.Object
implements java.util.concurrent.Future<T>

Future returned for GET operations. Not intended for general use.


Constructor Summary
GetFuture(java.util.concurrent.CountDownLatch l, long opTimeout)
           
 
Method Summary
 boolean cancel(boolean ign)
           
 T get()
           
 T get(long duration, java.util.concurrent.TimeUnit units)
           
 boolean isCancelled()
           
 boolean isDone()
           
 void set(java.util.concurrent.Future<T> d)
           
 void setOperation(Operation to)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GetFuture

public GetFuture(java.util.concurrent.CountDownLatch l,
                 long opTimeout)
Method Detail

cancel

public boolean cancel(boolean ign)
Specified by:
cancel in interface java.util.concurrent.Future<T>

get

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

get

public T get(long duration,
             java.util.concurrent.TimeUnit units)
      throws java.lang.InterruptedException,
             java.util.concurrent.TimeoutException,
             java.util.concurrent.ExecutionException
Specified by:
get in interface java.util.concurrent.Future<T>
Throws:
java.lang.InterruptedException
java.util.concurrent.TimeoutException
java.util.concurrent.ExecutionException

set

public void set(java.util.concurrent.Future<T> d)

setOperation

public void setOperation(Operation to)

isCancelled

public boolean isCancelled()
Specified by:
isCancelled in interface java.util.concurrent.Future<T>

isDone

public boolean isDone()
Specified by:
isDone in interface java.util.concurrent.Future<T>