diff options
| author | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2017-07-09 23:48:06 +0200 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2017-07-09 23:48:06 +0200 |
| commit | c94d0c347fdbd8acc774df4ac17617a3f63e4507 (patch) | |
| tree | 4b825dc642cb6eb9a060e54bf8d69288fbee4904 /Simulator/include/simulation/history/History.h | |
| parent | bc4c41e21a64b444bdbab3b6d1d407fd5d919419 (diff) | |
Delete old codebase
This change removes version 1 of the OpenDC simulator codebase as it
will be replaced by a complete rewrite in the Kotlin language.
Diffstat (limited to 'Simulator/include/simulation/history/History.h')
| -rw-r--r-- | Simulator/include/simulation/history/History.h | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/Simulator/include/simulation/history/History.h b/Simulator/include/simulation/history/History.h deleted file mode 100644 index f1d826eb..00000000 --- a/Simulator/include/simulation/history/History.h +++ /dev/null @@ -1,43 +0,0 @@ -#pragma once -#include <stdint.h> -#include <map> - -namespace Simulation { - template<typename Type> - class History { - public: - void addSnapshotAtTick(uint32_t tick, Type snapshot) - { - history.insert(std::make_pair(tick, snapshot)); - } - - const auto& snapshotsAtTick(uint32_t tick) - { - return history.equal_range(tick); - } - - typename std::unordered_map<uint32_t, Type>::const_iterator begin() - { - return history.begin(); - } - - typename std::unordered_map<uint32_t, Type>::const_iterator end() - { - return history.end(); - } - - void clear() - { - history.clear(); - } - - size_t size() - { - return history.size(); - } - - private: - // Maps ticks to histories of workloads - std::unordered_multimap<uint32_t, Type> history; - }; -}
\ No newline at end of file |
