org.objectweb.proactive.core.body.future
Class FuturePool

java.lang.Object
  |
  +--org.objectweb.proactive.core.body.future.FuturePool
All Implemented Interfaces:
java.io.Serializable

public class FuturePool
extends java.lang.Object
implements java.io.Serializable

See Also:
Serialized Form

Field Summary
protected  boolean newState
           
 
Constructor Summary
FuturePool()
           
 
Method Summary
 void addAutomaticContinuation(long id, UniqueID creatorID, UniversalBody bodyDest)
          To add an automatic contiunation, ie a destination body, for a particular future.
 void disableAC()
          To disable the automatic continuation behaviour for all futures in this FuturePool
 void enableAC()
          To enable the automatic continuation behaviour for all futures in this FuturePool
static UniversalBody getBodyDestination()
           
static java.util.ArrayList getIncomingFutures()
           
 UniqueID getOwnerBody()
          Getter of the ID of the body corresonding to this FuturePool
 void receiveFuture(Future futureObject)
          To put a future in the FutureMap
 void receiveFutureValue(long id, UniqueID creatorID, java.lang.Object result)
          Method called when a reply is recevied, ie a value is available for a future.
static void registerBodyDestination(UniversalBody dest)
           
 void registerDestination(UniversalBody dest)
          To register a destination before sending a reques or a reply Registration key is the calling thread.
static void registerIncomingFuture(Future f)
           
static void removeBodyDestination()
           
 void removeDestination()
          To clear registred destination for the calling thread.
static void removeIncomingFutures()
           
 void setMigrationTag()
           
 void setOwnerBody(UniqueID i)
          Setter of the ID of the body corresonding to this FuturePool
 void unsetMigrationTag()
           
 void waitForReply()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

newState

protected boolean newState
Constructor Detail

FuturePool

public FuturePool()
Method Detail

registerBodyDestination

public static void registerBodyDestination(UniversalBody dest)

removeBodyDestination

public static void removeBodyDestination()

getBodyDestination

public static UniversalBody getBodyDestination()

registerIncomingFuture

public static void registerIncomingFuture(Future f)

removeIncomingFutures

public static void removeIncomingFutures()

getIncomingFutures

public static java.util.ArrayList getIncomingFutures()

setOwnerBody

public void setOwnerBody(UniqueID i)
Setter of the ID of the body corresonding to this FuturePool

Parameters:
i - ID of the owner body.

getOwnerBody

public UniqueID getOwnerBody()
Getter of the ID of the body corresonding to this FuturePool


enableAC

public void enableAC()
To enable the automatic continuation behaviour for all futures in this FuturePool


disableAC

public void disableAC()
To disable the automatic continuation behaviour for all futures in this FuturePool


receiveFutureValue

public void receiveFutureValue(long id,
                               UniqueID creatorID,
                               java.lang.Object result)
                        throws java.io.IOException
Method called when a reply is recevied, ie a value is available for a future. This method perform local futures update, and put an ACService in the activeACqueue.

Parameters:
id - sequence id of the future to update
creatorID - ID of the body creator of the future to update
result - value to update with the futures
java.io.IOException

receiveFuture

public void receiveFuture(Future futureObject)
To put a future in the FutureMap

Parameters:
futureObject - future to register

addAutomaticContinuation

public void addAutomaticContinuation(long id,
                                     UniqueID creatorID,
                                     UniversalBody bodyDest)
To add an automatic contiunation, ie a destination body, for a particular future.

Parameters:
id - sequence id of the corresponding future
creatorID - UniqueID of the body which creates futureObject
bodyDest - body destination of this continuation

waitForReply

public void waitForReply()

registerDestination

public void registerDestination(UniversalBody dest)
To register a destination before sending a reques or a reply Registration key is the calling thread.


removeDestination

public void removeDestination()
To clear registred destination for the calling thread.


setMigrationTag

public void setMigrationTag()

unsetMigrationTag

public void unsetMigrationTag()


Copyright © April 2004 INRIA All Rights Reserved.