59 ::ll::TypedStorage<8, 8, ::ResourcePackRepository&> mRepository;
64 RepositoryLoaderImpl& operator=(RepositoryLoaderImpl
const&);
65 RepositoryLoaderImpl(RepositoryLoaderImpl
const&);
66 RepositoryLoaderImpl();
71 virtual ::std::shared_ptr<::RepositoryLoading::AllRefreshTaskData>
76 virtual ::std::shared_ptr<::RepositoryPacks const> getPacks()
const ;
78 virtual ~RepositoryLoaderImpl() =
default;
84 MCNAPI ::std::shared_ptr<::RepositoryLoading::AllRefreshTaskData>
89 MCNAPI ::std::shared_ptr<::RepositoryPacks const>
$getPacks()
const;
104 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::Core::FilePathManager>> mFilePathManager;
105 ::ll::TypedStorage<8, 16, ::gsl::not_null<::std::shared_ptr<::RepositoryPacks>>> mAllResourcePacks;
106 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::InvalidPacks>>> mInvalidPacks;
107 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::IRepositoryFactory>>> mFactory;
108 ::ll::TypedStorage<8, 16, ::gsl::not_null<::std::shared_ptr<::RepositorySources>>> mSources;
109 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::PackSourceReport>> mPackSourceReport;
110 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::RepositoryLoading::VanillaPacks>>> mVanillaPacks;
111 ::ll::TypedStorage<8, 24, ::std::vector<::PackIdVersion>> mServicePacks;
112 ::ll::TypedStorage<8, 8, ::PackManifestFactory&> mManifestFactory;
113 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::IContentAccessibilityProvider>> mContentAccessibility;
114 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> mCurrentWorldPath;
115 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> mCurrentPremiumWorldTemplatePath;
116 ::ll::TypedStorage<8, 64, ::std::unordered_map<::ContentIdentity, ::std::string>> mTempCacheContentKeys;
117 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::PackSettingsFactory>> mPackSettingsFactory;
118 ::ll::TypedStorage<8, 8, ::PackSourceFactory&> mPackSourceFactory;
119 ::ll::TypedStorage<8, 24, ::Bedrock::NonOwnerPointer<::PackCommand::IPackCommandPipeline>> mCommands;
120 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::TaskGroup>>> mTaskGroup;
121 ::ll::TypedStorage<8, 24, ::ContentIdentity> mCurrentPremiumWorldTemplateIdentity;
122 ::ll::TypedStorage<8, 8, ::gsl::not_null<::std::unique_ptr<::ResourcePackRepositoryRefreshQueue>>> mRefresher;
126 LLAPI
void addCustomResourcePackPath(std::filesystem::path
const& path, PackType type);
130 ResourcePackRepository& operator=(ResourcePackRepository
const&);
131 ResourcePackRepository(ResourcePackRepository
const&);
132 ResourcePackRepository();
137 virtual ~ResourcePackRepository() ;
139 virtual void getResourcePacksByPackId(
140 ::std::vector<::PackInstanceId>
const& packInstanceIds,
141 ::std::vector<::PackInstance>& result
144 virtual ::std::shared_ptr<::ResourcePack> getResourcePackForPackId(
::PackIdVersion const& idAndVersion)
const
147 virtual ::ResourcePack* getResourcePackOfDifferentVersionForPackId(
::PackIdVersion const& idAndVersion)
const
150 virtual ::ResourcePack*
154 virtual ::ResourcePack* getResourcePackByUUID(
::mce::UUID const&
id)
const ;
156 virtual ::ResourcePack* getResourcePackForPackIdOwned(
::PackIdVersion const& idAndVersion)
const ;
158 virtual ::std::shared_ptr<::ResourcePack>
159 getResourcePackSatisfiesPackId(
::PackIdVersion const& idAndVersion,
bool requireOwnership)
const ;
161 virtual ::ResourcePack* getResourcePackContainingModule(
::PackIdVersion const& idAndVersion)
const ;
163 virtual ::Bedrock::Threading::Async<::std::shared_ptr<::ResourcePack>>
166 virtual bool isResourcePackLoaded(
::PackIdVersion const& identity, ::PackOrigin
const& location) ;
168 virtual ::PackSourceReport
const* getPackLoadingReport() const ;
174 virtual
bool setServicePacks(::
std::vector<::
PackIdVersion> servicePackIds) ;
176 virtual
bool hasServicePacks(::
std::vector<::
PackIdVersion> const& servicePacksIds) const ;
183 addCachedResourcePacks(::
std::unordered_map<::
ContentIdentity, ::
std::
string> const* tempCacheKeys) ;
185 virtual
void addWorldResourcePacks(::Core::
Path const& levelPath) ;
187 virtual
void addPremiumWorldTemplateResourcePacks(
188 ::Core::
Path const& worldTemplatePath,
192 virtual
void addTempWorldTemplateResourcePacks(::mce::UUID const& worldTemplateUUID) ;
194 virtual
void addWorldPackSource(::Core::
Path const& levelPath) ;
196 virtual
void addPremiumWorldTemplatePackSource(
197 ::Core::
Path const& worldTemplatePath,
201 virtual
void removePacksLoadedFromCache() ;
203 virtual
void removePacksLoadedFromWorld() ;
205 virtual ::Core::PathBuffer<::
std::
string> const getResourcePacksPath() const ;
207 virtual ::Core::PathBuffer<::
std::
string> const getBehaviorPacksPath() const ;
209 virtual ::Core::PathBuffer<::
std::
string> const getSkinPacksPath() const ;
211 virtual ::Core::PathBuffer<::
std::
string> const getDevelopmentResourcePacksPath() const ;
213 virtual ::Core::PathBuffer<::
std::
string> const getDevelopmentBehaviorPacksPath() const ;
215 virtual ::Core::PathBuffer<::
std::
string> const getDevelopmentSkinPacksPath() const ;
217 virtual ::Core::PathBuffer<::
std::
string> const getTreatmentPacksPath() const ;
219 virtual
void refreshPacks() ;
221 virtual ::Bedrock::Threading::Async<
void> refreshPacksAsync() ;
223 virtual
void requestReloadUserPacks() ;
225 virtual ::Bedrock::NotNullNonOwnerPtr<::
IContentKeyProvider const> getKeyProvider() const ;
233 virtual ::
std::vector<::
ResourcePack*> getPacksByResourceLocation(::PackOrigin type) const ;
235 virtual ::
std::vector<::
ResourcePack*> getPacksByType(::PackType type) const ;
238 getPacksByCategory(::PackCategory category) const ;
240 virtual
void forEachPack(::
std::function<
void(::
ResourcePack const&)> const& callback) const ;
255 virtual
bool isInitialized() const ;
265 MCAPI ResourcePackRepository(
269 ::Bedrock::NotNullNonOwnerPtr<::Core::FilePathManager> const& pathManager,
270 ::Bedrock::NonOwnerPointer<::PackCommand::IPackCommandPipeline> commands,
284 ::Bedrock::NotNullNonOwnerPtr<::Core::FilePathManager> const& pathManager,
285 ::Bedrock::NonOwnerPointer<::PackCommand::IPackCommandPipeline> commands,
301 MCAPI
void $getResourcePacksByPackId(
311 $getResourcePackForPackIdInPath(::
PackIdVersion const& idAndVersion, ::Core::
Path const& fullPath) const;
313 MCAPI ::
ResourcePack* $getResourcePackByUUID(::mce::UUID const&
id) const;
318 $getResourcePackSatisfiesPackId(::
PackIdVersion const& idAndVersion,
bool requireOwnership) const;
323 $getResourcePackInPath(::Core::
Path const& path) const;
325 MCAPI
bool $isResourcePackLoaded(::
PackIdVersion const& identity, ::PackOrigin const& location);
335 MCAPI
bool $hasServicePacks(::
std::vector<::
PackIdVersion> const& servicePacksIds) const;
341 MCAPI
void $addCachedResourcePacks(::
std::unordered_map<::
ContentIdentity, ::
std::
string> const* tempCacheKeys);
343 MCAPI
void $addWorldResourcePacks(::Core::
Path const& levelPath);
345 MCAPI
void $addPremiumWorldTemplateResourcePacks(
346 ::Core::
Path const& worldTemplatePath,
350 MCAPI
void $addTempWorldTemplateResourcePacks(::mce::UUID const& worldTemplateUUID);
352 MCAPI
void $addWorldPackSource(::Core::
Path const& levelPath);
354 MCAPI
void $addPremiumWorldTemplatePackSource(
355 ::Core::
Path const& worldTemplatePath,
359 MCAPI
void $removePacksLoadedFromCache();
361 MCAPI
void $removePacksLoadedFromWorld();
363 MCAPI ::Core::PathBuffer<::
std::
string> const $getResourcePacksPath() const;
365 MCAPI ::Core::PathBuffer<::
std::
string> const $getBehaviorPacksPath() const;
367 MCAPI ::Core::PathBuffer<::
std::
string> const $getSkinPacksPath() const;
369 MCAPI ::Core::PathBuffer<::
std::
string> const $getDevelopmentResourcePacksPath() const;
371 MCAPI ::Core::PathBuffer<::
std::
string> const $getDevelopmentBehaviorPacksPath() const;
373 MCAPI ::Core::PathBuffer<::
std::
string> const $getDevelopmentSkinPacksPath() const;
375 MCAPI ::Core::PathBuffer<::
std::
string> const $getTreatmentPacksPath() const;
377 MCAPI
void $refreshPacks();
379 MCAPI ::Bedrock::Threading::Async<
void> $refreshPacksAsync();
381 MCAPI
void $requestReloadUserPacks();
391 MCAPI ::
std::vector<::
ResourcePack*> $getPacksByResourceLocation(::PackOrigin type) const;
393 MCAPI ::
std::vector<::
ResourcePack*> $getPacksByType(::PackType type) const;
396 $getPacksByCategory(::PackCategory category) const;
398 MCAPI
void $forEachPack(::
std::function<
void(::
ResourcePack const&)> const& callback) const;
412 MCAPI
bool $isInitialized() const;