| 48 | }; |
| 49 | |
| 50 | KeyValueDB::KeyValueDB(std::filesystem::path const& path, bool createIfMiss, bool fixIfError, int bloomFilterBit) { |
| 51 | if (createIfMiss) { |
| 52 | std::error_code ec; |
| 53 | std::filesystem::create_directories(path, ec); |
| 54 | } |
| 55 | impl = std::make_unique<KeyValueDBImpl>( |
| 56 | string_utils::wstr2str(path.wstring()), |
| 57 | createIfMiss, |
| 58 | fixIfError, |
| 59 | bloomFilterBit |
| 60 | ); |
| 61 | } |
| 62 | |
| 63 | KeyValueDB::KeyValueDB(std::filesystem::path const& path) : KeyValueDB(path, true, true, 0) {} |
| 64 |
nothing calls this directly
no test coverage detected