Modern, Header-Only Key-Value Store for C++.
PolyKV C++ provides a clean, standardized interface for persisting data in desktop applications. No external libraries required* (*uses standard STL).
One API, Everywhere. This library is part of the PolyKV ecosystem. Use the same consistent API across 12+ languages.
-
⚡️ Header-Only Easy integration. Just drop it in your include path and go. No complex linking required.
-
🖥 Cross-Platform Uses
std::filesystemto handle paths gracefully across macOS, Windows, and Linux. -
🛠 Standard API Follows the same
setString/getMapnaming convention as the high-level SDKs, simplifying porting.
add_subdirectory(sdk/cpp)
target_link_libraries(your_app PRIVATE polykv)#include "polykv.hpp"
#include <iostream>
int main() {
polykv::PolyKV kv("MyApp");
// 1. Save
kv.set_string("mode", "dark");
kv.set_number("width", 1920);
// 2. Read
std::cout << "Mode: " << kv.get_string("mode") << std::endl;
// 3. Update
kv.set_string("mode", "light");
// 4. Delete
kv.remove("width");
// 5. Clear All
kv.clear();
return 0;
}| Language | Verified Runtime (✅) | Build Only (🛠) |
|---|---|---|
| TypeScript | CLI (Node.js), Browser, React Native (iOS/Android) | - |
| Dart | Flutter (iOS/Android/macOS), CLI | - |
| Go | macOS, Linux, Windows, iOS, Android, CLI | - |
| Rust | macOS, iOS, Android, CLI | Linux, Windows |
| Swift | iOS, macOS, CLI | - |
| C++ | macOS, iOS, Android, CLI | - |
| Python | CLI, Web, Android | - |
| Kotlin | CLI, Web, Android | - |
| C# | CLI | Android, Windows |
| Java | CLI, Android | - |
| Ruby | CLI | - |
| PHP | CLI | - |
✅ Runtime Verified: Full CRUD operations verified via automated tests on actual devices/simulators.
MIT