00001
00002
00003 #ifndef TESTCHECKPOINTMANAGER_H
00004 #define TESTCHECKPOINTMANAGER_H
00005
00006 #include <iostream>
00007 #include <ctime>
00008
00009 #include "TestSaveManager.h"
00010 #include "CheckpointManager.h"
00011
00014 class TestCheckpointManager : public CheckpointManager
00015 {
00016 public:
00017
00019 TestCheckpointManager(TestSaveManager &tsm);
00020
00022 ~TestCheckpointManager();
00023
00025 void checkpoint(std::ostream &out);
00026
00028 void setInterval(uint64 iterations);
00029
00031 void setTimer(time_t seconds);
00032
00034 void setCheckpointNow();
00035
00036 private:
00037 TestSaveManager *tsm;
00038
00039
00040 bool itr_on;
00041 uint64 itr_interval;
00042 uint64 itr_count;
00043
00044
00045 bool timer_on;
00046 time_t timer_interval;
00047 time_t timer_deadline;
00048
00049
00050 bool now;
00051 };
00052 #endif