eu.xtreemos.xosd.localallocmgr.frontend.wrapper
Class MigrationsHandler

java.lang.Object
  extended by eu.xtreemos.xosd.localallocmgr.frontend.wrapper.MigrationsHandler

public class MigrationsHandler
extends java.lang.Object

holds info about the ids of the reservations and state of the time machine, so that one is able to redo everything until some reservation ...

Author:
uros

Field Summary
(package private)  java.util.Hashtable<java.lang.String,java.util.Stack<java.lang.Long>> info
           
 
Constructor Summary
MigrationsHandler()
           
 
Method Summary
 void addCheckpointFor(java.lang.String reservationID)
          remembers the state of the TimeMachine befor the reservation is dene.
 void removeCheckpointFor(java.lang.String reservationID)
          removes the top info about the state of the TimeMachine
 boolean roolbackFor(java.lang.String reservationID)
          removes every change since the change made by reservationID (including the named reservation).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

info

java.util.Hashtable<java.lang.String,java.util.Stack<java.lang.Long>> info
Constructor Detail

MigrationsHandler

public MigrationsHandler()
Method Detail

addCheckpointFor

public void addCheckpointFor(java.lang.String reservationID)
remembers the state of the TimeMachine befor the reservation is dene. This call should be made before manipulation of the timetables...

Parameters:
reservationID -

removeCheckpointFor

public void removeCheckpointFor(java.lang.String reservationID)
removes the top info about the state of the TimeMachine

Parameters:
reservationID -

roolbackFor

public boolean roolbackFor(java.lang.String reservationID)
                    throws AttributeConformanceException
removes every change since the change made by reservationID (including the named reservation). Returns true, if rollback was possible, false, if something went wrong.

Parameters:
reservationID -
Returns:
Throws:
AttributeConformanceException