aboutsummaryrefslogtreecommitdiff
path: root/src/dbwrapper.cpp
diff options
context:
space:
mode:
authorTheCharlatan <seb.kung@gmail.com>2023-07-14 11:30:52 +0200
committerTheCharlatan <seb.kung@gmail.com>2023-08-05 10:42:51 +0200
commitef941ff1281e76308c3e746e592375bec023e9e4 (patch)
treec47d288c3c2aa819139af440f21d7cc374804fee /src/dbwrapper.cpp
parentb7a1ab5cb4e60230f62c94efb3a10d07c9af4883 (diff)
refactor: Split dbwrapper CDBIterator::GetValue implementation
Keep the generic serialization in the header, while moving leveldb-specifics to the implementation file. The context of this commit is an effort to decouple the dbwrapper header file from leveldb includes. To this end, the includes are moved to the dbwrapper implementation file. This is done as part of the kernel project to reduce the number of required includes for users of the kernel.
Diffstat (limited to 'src/dbwrapper.cpp')
-rw-r--r--src/dbwrapper.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/dbwrapper.cpp b/src/dbwrapper.cpp
index dbf1d18de2..2f0b9a5ff3 100644
--- a/src/dbwrapper.cpp
+++ b/src/dbwrapper.cpp
@@ -317,6 +317,11 @@ Span<const std::byte> CDBIterator::GetKeyImpl() const
return MakeByteSpan(piter->key());
}
+Span<const std::byte> CDBIterator::GetValueImpl() const
+{
+ return MakeByteSpan(piter->value());
+}
+
CDBIterator::~CDBIterator() { delete piter; }
bool CDBIterator::Valid() const { return piter->Valid(); }
void CDBIterator::SeekToFirst() { piter->SeekToFirst(); }