com.hazelcast.core
Class MultiTask<V>

java.lang.Object
  extended by java.util.concurrent.FutureTask<V>
      extended by com.hazelcast.core.DistributedTask
          extended by com.hazelcast.core.MultiTask<V>
All Implemented Interfaces:
java.lang.Runnable, java.util.concurrent.Future, java.util.concurrent.RunnableFuture

public class MultiTask<V>
extends DistributedTask


Nested Class Summary
 
Nested classes/interfaces inherited from class com.hazelcast.core.DistributedTask
DistributedTask.DistributedRunnableAdapterImpl<V>, DistributedTask.Inner
 
Field Summary
protected  java.util.Collection<V> results
           
 
Constructor Summary
MultiTask(java.util.concurrent.Callable<V> callable, java.util.Set<Member> members)
           
 
Method Summary
 java.util.Collection<V> get()
           
 java.util.Collection<V> get(long timeout, java.util.concurrent.TimeUnit unit)
           
 void onResult(java.lang.Object result)
           
 
Methods inherited from class com.hazelcast.core.DistributedTask
callable, cancel, getExecutionCallback, getInner, isCancelled, isDone, set, setExecutionCallback, setMemberLeft
 
Methods inherited from class java.util.concurrent.FutureTask
done, run, runAndReset, setException
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

results

protected java.util.Collection<V> results
Constructor Detail

MultiTask

public MultiTask(java.util.concurrent.Callable<V> callable,
                 java.util.Set<Member> members)
Method Detail

onResult

public void onResult(java.lang.Object result)
Overrides:
onResult in class DistributedTask

get

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

get

public java.util.Collection<V> get(long timeout,
                                   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
Overrides:
get in class DistributedTask
Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
java.util.concurrent.TimeoutException


Copyright .9.4.5; 2008-2011 Hazel Ltd. All Rights Reserved.