LeviLamina
Loading...
Searching...
No Matches
MockLevelStorage.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/common/CompactionStatus.h"
7#include "mc/deps/core/file/PathBuffer.h"
8#include "mc/deps/core/threading/Async.h"
9#include "mc/world/level/storage/LevelStorage.h"
10#include "mc/world/level/storage/StorageVersion.h"
11#include "mc/world/level/storage/db_helpers/Category.h"
12
13// auto generated forward declare list
14// clang-format off
15class ChunkSource;
16class CompoundTag;
17class ContentIdentity;
18class LevelData;
22namespace Core { struct LevelStorageResult; }
23// clang-format on
24
26public:
27 // virtual functions
28 // NOLINTBEGIN
29 virtual ~MockLevelStorage() /*override*/ = default;
30
31 virtual void addStorageObserver(::std::unique_ptr<::LevelStorageObserver>) /*override*/;
32
33 virtual ::std::unique_ptr<::CompoundTag> getCompoundTag(::std::string const&, ::DBHelpers::Category) /*override*/;
34
35 virtual bool hasKey(::std::string_view, ::DBHelpers::Category) const /*override*/;
36
37 virtual void forEachKeyWithPrefix(
38 ::std::string_view,
39 ::DBHelpers::Category,
40 ::std::function<void(::std::string_view, ::std::string_view)> const&
41 ) const /*override*/;
42
43 virtual bool loadLevelData(::LevelData&) /*override*/;
44
45 virtual ::std::unique_ptr<::ChunkSource>
46 createChunkStorage(::std::unique_ptr<::ChunkSource>, ::StorageVersion) /*override*/;
47
48 virtual void saveLevelData(::LevelData const&) /*override*/;
49
50 virtual ::Core::PathBuffer<::std::string> const& getFullPath() const /*override*/;
51
52 virtual ::Bedrock::Threading::Async<void>
53 saveData(::std::string const&, ::std::string&&, ::DBHelpers::Category) /*override*/;
54
55 virtual ::Bedrock::Threading::Async<void> saveData(::LevelStorageWriteBatch const&) /*override*/;
56
57 virtual ::Bedrock::Threading::Async<void> deleteData(::std::string const&, ::DBHelpers::Category) /*override*/;
58
59 virtual void getStatistics(::std::string&, ::LevelStorage::StatsType) const /*override*/;
60
61 virtual ::Core::LevelStorageResult getLevelStorageState() const /*override*/;
62
63 virtual ::ContentIdentity const* getContentIdentity() const /*override*/;
64
65 virtual void startShutdown() /*override*/;
66
67 virtual bool isShuttingDown() const /*override*/;
68
69 virtual bool checkShutdownDone() /*override*/;
70
71 virtual ::Core::LevelStorageResult getState() const /*override*/;
72
73 virtual ::std::vector<::SnapshotFilenameAndLength> createSnapshot(::std::string const&, bool) /*override*/;
74
75 virtual void releaseSnapshot() /*override*/;
76
77 virtual ::Bedrock::Threading::Async<void> compactStorage() /*override*/;
78
79 virtual void syncAndSuspendStorage() /*override*/;
80
81 virtual void resumeStorage() /*override*/;
82
83 virtual void setFlushAllowed(bool) /*override*/;
84
85 virtual void flushToPermanentStorage() /*override*/;
86
87 virtual void setCompactionCallback(::std::function<void(::CompactionStatus)>) /*override*/;
88
89 virtual void setCriticalSyncSaveCallback(::std::function<void()>) /*override*/;
90 // NOLINTEND
91
92public:
93 // virtual function thunks
94 // NOLINTBEGIN
95
96 // NOLINTEND
97};
Definition ChunkSource.h:37
Definition CompoundTag.h:23
Definition ContentIdentity.h:8
Definition LevelData.h:50
Definition LevelStorageObserver.h:5
Definition LevelStorageWriteBatch.h:14
Definition LevelStorage.h:25
Definition MockLevelStorage.h:25
Definition LevelStorageResult.h:7
Definition SnapshotFilenameAndLength.h:5