203 virtual void addStorageObserver(::std::unique_ptr<::LevelStorageObserver> observer) ;
206 virtual bool loadedSuccessfully() const ;
209 virtual ::Core::LevelStorageResult getState() const ;
213 createChunkStorage(::
std::unique_ptr<::
ChunkSource>, ::StorageVersion) ;
216 virtual ::Core::PathBuffer<::
std::
string> const& getFullPath() const ;
220 getCompoundTag(::
std::
string const& key, ::DBHelpers::Category category) ;
223 virtual
bool hasKey(::
std::string_view key, ::DBHelpers::Category category) const ;
226 virtual
bool loadLevelData(::
LevelData& data) ;
229 virtual
void saveLevelData(::
LevelData const& levelData) ;
232 virtual ::
std::shared_ptr<::Bedrock::Threading::IAsyncResult<
void>>
233 saveData(::
std::
string const& key, ::
std::
string&& data, ::DBHelpers::Category category) ;
240 virtual ::
std::shared_ptr<::Bedrock::Threading::IAsyncResult<
void>>
241 deleteData(::
std::
string const& key, ::DBHelpers::Category category) ;
244 virtual
bool loadData(::
std::string_view key, ::
std::
string&
buffer, ::DBHelpers::Category category) const
248 virtual
void forEachKeyWithPrefix(
249 ::
std::string_view prefix,
250 ::DBHelpers::Category category,
251 ::
std::function<
void(::
std::string_view, ::
std::string_view)> const& callback
255 virtual ::Core::LevelStorageResult getLevelStorageState() const ;
258 virtual
void startShutdown() ;
261 virtual
bool isShuttingDown() const ;
264 virtual
bool checkShutdownDone() ;
267 virtual
void getStatistics(::
std::
string& outStats, ::
LevelStorage::StatsType statsType) const ;
271 createSnapshot(::
std::
string const& filePrefix,
bool flushWriteCache) ;
274 virtual
void releaseSnapshot() ;
277 virtual ::
std::shared_ptr<::Bedrock::Threading::IAsyncResult<
void>> compactStorage() ;
280 virtual
void syncAndSuspendStorage() ;
283 virtual
void resumeStorage() ;
286 virtual
void setFlushAllowed(
bool flushAllowed) ;
289 virtual
void flushToPermanentStorage() ;
292 virtual
void freeCaches() ;
295 virtual
void setCompactionCallback(::
std::function<
void(::CompactionStatus)> callback) ;
298 virtual
void setCriticalSyncSaveCallback(::
std::function<
void()> callback) ;
306 MCAPI ::
TaskResult _flushWriteCacheToLevelDB();
310 MCAPI ::
std::
string _getTelemetryMessage(::leveldb::Status const& status) const;
312 MCAPI
void _handleErrorStatus(::leveldb::Status const& status);
314 MCAPI
void _markAsCorrupted(::
std::string_view message) const;
318 MCAPI
void _mergeIntoWriteCache(::
std::
string const& key, ::
std::
string&& data, ::DBHelpers::Category category);
320 MCAPI
void _queueSaveCallback(
bool invokeImmediately);
323 ::
std::string_view prefix,
324 ::DBHelpers::Category category,
325 ::
std::function<
void(::
std::string_view, ::
std::string_view)> const& callback
329 _readPendingWrite(::
std::
string const& key, ::DBHelpers::Category category) const;
331 MCAPI
void _scheduleNextAutoCompaction();
334 _suspendAndPerformSaveAction(::brstd::move_only_function<::
TaskResult()> action, ::
std::function<
void()> callback);
336 MCAPI
bool tryRepair(::Core::
Path const& path) const;
356 MCAPI
bool $loadedSuccessfully() const;
358 MCFOLD ::Core::LevelStorageResult $getState() const;
360 MCAPI ::Core::PathBuffer<::
std::
string> const& $getFullPath() const;
362 MCAPI ::
std::unique_ptr<::
CompoundTag> $getCompoundTag(::
std::
string const& key, ::DBHelpers::Category category);
364 MCAPI
bool $hasKey(::
std::string_view key, ::DBHelpers::Category category) const;
366 MCAPI
bool $loadLevelData(::
LevelData& data);
368 MCAPI
void $saveLevelData(::
LevelData const& levelData);
370 MCAPI ::
std::shared_ptr<::Bedrock::Threading::IAsyncResult<
void>>
371 $saveData(::
std::
string const& key, ::
std::
string&& data, ::DBHelpers::Category category);
375 MCAPI ::
std::shared_ptr<::Bedrock::Threading::IAsyncResult<
void>>
376 $deleteData(::
std::
string const& key, ::DBHelpers::Category category);
378 MCAPI
bool $loadData(::
std::string_view key, ::
std::
string&
buffer, ::DBHelpers::Category category) const;
380 MCAPI
void $forEachKeyWithPrefix(
381 ::
std::string_view prefix,
382 ::DBHelpers::Category category,
383 ::
std::function<
void(::
std::string_view, ::
std::string_view)> const& callback
386 MCFOLD ::Core::LevelStorageResult $getLevelStorageState() const;
388 MCAPI
void $startShutdown();
390 MCAPI
bool $isShuttingDown() const;
392 MCAPI
bool $checkShutdownDone();
394 MCAPI
void $getStatistics(::
std::
string& outStats, ::
LevelStorage::StatsType statsType) const;
397 $createSnapshot(::
std::
string const& filePrefix,
bool flushWriteCache);
399 MCAPI
void $releaseSnapshot();
401 MCAPI ::
std::shared_ptr<::Bedrock::Threading::IAsyncResult<
void>> $compactStorage();
403 MCAPI
void $syncAndSuspendStorage();
405 MCAPI
void $resumeStorage();
407 MCAPI
void $setFlushAllowed(
bool flushAllowed);
409 MCAPI
void $flushToPermanentStorage();
411 MCAPI
void $freeCaches();
413 MCAPI
void $setCompactionCallback(::
std::function<
void(::CompactionStatus)> callback);
415 MCAPI
void $setCriticalSyncSaveCallback(::
std::function<
void()> callback);
421 MCAPI static
void** $vftable();