LeviLamina
Loading...
Searching...
No Matches
PackSettingsFactory.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/cereal/ReflectionCtx.h"
7#include "mc/deps/core/file/PathBuffer.h"
8#include "mc/deps/core/utility/pub_sub/Publisher.h"
9#include "mc/deps/puv/SlicedLoader.h"
10
11// auto generated forward declare list
12// clang-format off
13class PackManifest;
14class PackSettings;
15namespace Bedrock::PubSub::ThreadModel { struct MultiThreaded; }
16namespace Core { class Path; }
17namespace Core { class PathView; }
18namespace SharedTypes::v1_21_100::PackSettingsDefinition { struct Document; }
19namespace mce { class UUID; }
20// clang-format on
21
23public:
24 // PackSettingsFactory inner types declare
25 // clang-format off
26 struct Stats;
27 // clang-format on
28
29 // PackSettingsFactory inner types define
30 struct Stats {
31 public:
32 // member variables
33 // NOLINTBEGIN
38 // NOLINTEND
39
40 public:
41 // prevent constructor by default
42 Stats& operator=(Stats const&);
43 Stats(Stats const&);
44 Stats();
45 };
46
47 using PackIdToSettingsMap = ::std::unordered_map<::mce::UUID, ::std::unique_ptr<::PackSettings>>;
48
49public:
50 // member variables
51 // NOLINTBEGIN
52 ::ll::TypedStorage<8, 8, uint64 const> mMaxGlobalPackSettingEntriesPerFile;
53 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> mGlobalPackSettingsPath;
54 ::ll::TypedStorage<4, 16, ::PackSettingsFactory::Stats> mStats;
55 ::ll::TypedStorage<8, 120, ::cereal::ReflectionCtx> mReflectionCtx;
56 ::ll::TypedStorage<
57 8,
58 192,
60 mLoader;
61 ::ll::TypedStorage<
62 8,
63 16,
64 ::std::shared_ptr<::Bedrock::PubSub::Publisher<
65 void(::mce::UUID const&, ::std::string const&, ::std::variant<float, bool, ::std::string> const&),
67 0>>>
68 mOnChangePublisher;
69 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::std::unordered_map<::mce::UUID, ::std::unique_ptr<::PackSettings>>>>
70 mGlobalPackSettings;
71 ::ll::TypedStorage<
72 8,
73 64,
74 ::std::unordered_map<::std::string, ::std::unordered_map<::mce::UUID, ::std::unique_ptr<::PackSettings>>>>
75 mWorldPackSettings;
76 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::SharedTypes::v1_21_100::PackSettingsDefinition::Document>>
77 mGlobalUserOverrides;
78 ::ll::TypedStorage<
79 8,
80 64,
81 ::std::
82 unordered_map<::std::string, ::std::unique_ptr<::SharedTypes::v1_21_100::PackSettingsDefinition::Document>>>
83 mPerWorldUserOverrides;
84 // NOLINTEND
85
86public:
87 // prevent constructor by default
89
90public:
91 // virtual functions
92 // NOLINTBEGIN
93 // vIndex: 0
94 virtual ~PackSettingsFactory();
95
96 // vIndex: 1
97 virtual uint64 getAccessTimestamp() const;
98 // NOLINTEND
99
100public:
101 // member functions
102 // NOLINTBEGIN
103 MCAPI
104 PackSettingsFactory(uint64 maxGlobalPackSettingEntriesPerFile, ::std::optional<::Core::PathView> globalPathRoot);
105
106 MCAPI ::PackSettings* _getGlobalPackSettings(::PackManifest const& manifest);
107
108 MCAPI ::PackSettings* _getWorldPackSettings(::PackManifest const& manifest, ::std::optional<::std::string> worldId);
109
110 MCAPI ::std::unique_ptr<::SharedTypes::v1_21_100::PackSettingsDefinition::Document>
111 _loadUserOverridesFromFile(::Core::Path const& path) const;
112
113 MCAPI ::PackSettings* getPackSettings(::PackManifest const& manifest, ::std::optional<::std::string> worldId);
114
115 MCAPI bool loadPerWorldUserOverrides(::std::string const& worldId, ::Core::Path const& worldPath);
116 // NOLINTEND
117
118public:
119 // static variables
120 // NOLINTBEGIN
121 MCAPI static ::std::string_view const& GLOBAL_RESOURCE_PACK_SETTINGS_FILENAME();
122
123 MCAPI static ::std::string_view const& WORLD_BEHAVIOR_PACK_SETTINGS_FILENAME();
124 // NOLINTEND
125
126public:
127 // constructor thunks
128 // NOLINTBEGIN
129 MCAPI void* $ctor(uint64 maxGlobalPackSettingEntriesPerFile, ::std::optional<::Core::PathView> globalPathRoot);
130 // NOLINTEND
131
132public:
133 // destructor thunk
134 // NOLINTBEGIN
135 MCAPI void $dtor();
136 // NOLINTEND
137
138public:
139 // virtual function thunks
140 // NOLINTBEGIN
141 MCAPI uint64 $getAccessTimestamp() const;
142 // NOLINTEND
143
144public:
145 // vftables
146 // NOLINTBEGIN
147 MCNAPI static void** $vftable();
148 // NOLINTEND
149};
Definition Publisher.h:8
Definition Path.h:11
Definition PackManifest.h:36
Definition PackSettingsFactory.h:22
static MCAPI void ** $vftable()
Definition PackSettings.h:19
Definition Path.h:16
Definition SlicedLoader.h:8
Definition UUID.h:7
Definition PackSettingsFactory.h:30
Definition Alias.h:14