Removed MemoryAccessCommandPacket class and moved GDB memory offsets to GDB TargetDescriptor class

This commit is contained in:
Nav
2022-08-30 02:04:35 +01:00
parent fd68089214
commit 2ae3786130
16 changed files with 114 additions and 92 deletions

View File

@@ -2,6 +2,7 @@
#include <memory>
#include <unordered_map>
#include <set>
namespace Bloom
{
@@ -67,6 +68,26 @@ namespace Bloom
return this->map;
}
[[nodiscard]] std::set<TypeB> getKeys() const {
auto keys = std::set<TypeB>();
for (const auto& [key, value] : this->map) {
keys.insert(key);
}
return keys;
}
[[nodiscard]] std::set<TypeB> getValues() const {
auto values = std::set<TypeB>();
for (const auto& [key, value] : this->map) {
values.insert(value);
}
return values;
}
void insert(const std::pair<TypeA, TypeB>& pair) {
auto insertResultPair = this->map.insert(pair);
this->flippedMap.insert(std::pair<TypeB, TypeA>(pair.second, pair.first));