org.infinispan.util.concurrent
Class AggregatingNotifyingFutureImpl

java.lang.Object
  extended by org.infinispan.util.concurrent.NotifyingFutureImpl
      extended by org.infinispan.util.concurrent.AggregatingNotifyingFutureImpl
All Implemented Interfaces:
Future<Object>, NotifyingFuture<Object>, NotifyingNotifiableFuture<Object>

public class AggregatingNotifyingFutureImpl
extends NotifyingFutureImpl

For use with > 1 underlying network future

Since:
4.0
Author:
Manik Surtani

Constructor Summary
AggregatingNotifyingFutureImpl(Object actualReturnValue, int maxFutures)
           
 
Method Summary
 boolean cancel(boolean mayInterruptIfRunning)
           
 Object get()
           
 Object get(long timeout, TimeUnit unit)
           
 boolean isCancelled()
           
 boolean isDone()
           
 void notifyDone()
           
 void setNetworkFuture(Future<Object> future)
           
 
Methods inherited from class org.infinispan.util.concurrent.NotifyingFutureImpl
attachListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AggregatingNotifyingFutureImpl

public AggregatingNotifyingFutureImpl(Object actualReturnValue,
                                      int maxFutures)
Method Detail

setNetworkFuture

public void setNetworkFuture(Future<Object> future)
Specified by:
setNetworkFuture in interface NotifyingNotifiableFuture<Object>
Overrides:
setNetworkFuture in class NotifyingFutureImpl

cancel

public boolean cancel(boolean mayInterruptIfRunning)
Specified by:
cancel in interface Future<Object>
Overrides:
cancel in class NotifyingFutureImpl

isCancelled

public boolean isCancelled()
Specified by:
isCancelled in interface Future<Object>
Overrides:
isCancelled in class NotifyingFutureImpl

isDone

public boolean isDone()
Specified by:
isDone in interface Future<Object>
Overrides:
isDone in class NotifyingFutureImpl

get

public Object get()
           throws InterruptedException,
                  ExecutionException
Specified by:
get in interface Future<Object>
Overrides:
get in class NotifyingFutureImpl
Throws:
InterruptedException
ExecutionException

get

public Object get(long timeout,
                  TimeUnit unit)
           throws InterruptedException,
                  ExecutionException,
                  TimeoutException
Specified by:
get in interface Future<Object>
Overrides:
get in class NotifyingFutureImpl
Throws:
InterruptedException
ExecutionException
TimeoutException

notifyDone

public void notifyDone()
Specified by:
notifyDone in interface NotifyingNotifiableFuture<Object>
Overrides:
notifyDone in class NotifyingFutureImpl

-->

Copyright © 2012 JBoss, a division of Red Hat. All Rights Reserved.