galois.runtime
Class Iteration

java.lang.Object
  extended by galois.runtime.Iteration

public class Iteration
extends Object

Represents data accessed during an iteration.


Constructor Summary
Iteration(int id)
           
 
Method Summary
 void acquire(Lockable lockable)
          Acquires an abstract lock on the given object.
static Iteration acquire(Lockable lockable, byte flags)
          Acquires an abstract lock on the given object if flags contains MethodFlag.CHECK_CONFLICT.
protected  int clearLogs(boolean releaseLocks)
          Clears undo logs, commit logs, conflict logs
static Iteration getCurrentIteration()
          Returns the currently executing iteration or null if no iteration is currently being executed.
 int getId()
           
protected  void reset()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Iteration

public Iteration(int id)
Method Detail

reset

protected void reset()

getCurrentIteration

public static Iteration getCurrentIteration()
Returns the currently executing iteration or null if no iteration is currently being executed.

Returns:
the current iteration

acquire

public static Iteration acquire(Lockable lockable,
                                byte flags)
Acquires an abstract lock on the given object if flags contains MethodFlag.CHECK_CONFLICT. Returns the current iteration if flags contains MethodFlag.CHECK_CONFLICT.

Parameters:
lockable - the object to lock
flags - method flags
Returns:
the current iteration if flags contains MethodFlag.CHECK_CONFLICT
See Also:
acquire(Lockable)

acquire

public void acquire(Lockable lockable)
Acquires an abstract lock on the given object.

Parameters:
lockable - object to acquire an abstract lock on

clearLogs

protected int clearLogs(boolean releaseLocks)
Clears undo logs, commit logs, conflict logs


getId

public int getId()