LeviLamina
Loading...
Searching...
No Matches
WorldResourcePackDownloader.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/world/IWorldResourcePackDownloader.h"
7#include "mc/client/world/PackDownloadError.h"
8#include "mc/deps/core/utility/NonOwnerPointer.h"
9
10// auto generated forward declare list
11// clang-format off
12class IClientInstance;
14class IDlcBatchModel;
15class IDlcBatcher;
16class IDlcValidation;
17class IEntitlementManager;
18class ILevelListCache;
19class IStoreCatalogRepository;
21struct PackIdVersion;
22namespace World { struct PackCheckResult; }
23namespace World { struct PackDownloadProgressInfo; }
24// clang-format on
25
26namespace World {
27
28class WorldResourcePackDownloader : public ::World::IWorldResourcePackDownloader {
29public:
30 // member variables
31 // NOLINTBEGIN
32 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::IDlcBatcher>> mDlcBatcher;
33 ::ll::TypedStorage<8, 8, ::IDlcValidation&> mDlcValidation;
34 ::ll::TypedStorage<8, 8, ::IContentAcquisition&> mContentAcquisition;
35 ::ll::TypedStorage<8, 8, ::IStoreCatalogRepository&> mStoreCatalogRepository;
36 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::IEntitlementManager>> mEntitlementManager;
37 ::ll::TypedStorage<8, 8, ::IClientInstance&> mClientInstance;
38 ::ll::TypedStorage<8, 8, ::ILevelListCache&> mLevelListCache;
39 ::ll::TypedStorage<8, 8, ::IDlcBatchModel*> mDlcBatchModel;
40 ::ll::TypedStorage<8, 8, uint64> mDlcSizeToDownload;
41 ::ll::TypedStorage<8, 8, uint64> mDlcIdsToDownload;
42 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::DlcValidationState>> mDlcState;
43 ::ll::TypedStorage<8, 16, ::std::shared_ptr<bool>> mExistenceTracker;
44 ::ll::TypedStorage<8, 64, ::std::function<void(::std::optional<::World::PackDownloadError>)>> mOnCheckPackComplete;
45 ::ll::TypedStorage<8, 64, ::std::function<void()>> mOnDownloadCompleteCallback;
46 ::ll::TypedStorage<8, 64, ::std::function<void(uint64)>> mOnGetPackSizeCompleteCallback;
47 // NOLINTEND
48
49public:
50 // prevent constructor by default
51 WorldResourcePackDownloader& operator=(WorldResourcePackDownloader const&);
52 WorldResourcePackDownloader(WorldResourcePackDownloader const&);
53 WorldResourcePackDownloader();
54
55public:
56 // virtual functions
57 // NOLINTBEGIN
58 virtual void downloadPacks(
59 ::std::vector<::std::string> const& productIds,
60 ::std::function<void()> onCompleteCallback,
61 ::std::function<void(::World::PackDownloadError)> onErrorCallback
62 ) /*override*/;
63
64 virtual ::World::PackDownloadProgressInfo getProgress() /*override*/;
65
66 virtual void
67 getDownloadingPackTitles(::std::function<void(::std::vector<::std::string>)> packTitlesCallback) /*override*/;
68
69 virtual void cancelDownloadPack() /*override*/;
70
71 virtual void getPackSizes(
72 ::std::vector<::std::string> const& productIds,
73 ::std::function<void(uint64)> onCompleteCallback
74 ) /*override*/;
75
76 virtual ::World::PackCheckResult
77 checkDlc(::std::string const& levelId, ::PackIdVersion const& packIdVersion, bool const isForRealms) const
78 /*override*/;
79
80 virtual ~WorldResourcePackDownloader() /*override*/;
81 // NOLINTEND
82
83public:
84 // member functions
85 // NOLINTBEGIN
86 MCAPI WorldResourcePackDownloader(
87 ::IDlcValidation& dlcValidation,
88 ::IContentAcquisition& contentAcquisition,
89 ::IStoreCatalogRepository& storeCatalogRepository,
90 ::Bedrock::NotNullNonOwnerPtr<::IEntitlementManager> entitlementManager,
91 ::IClientInstance& clientInstance,
92 ::ILevelListCache& levelListCache
93 );
94
95 MCAPI void _checkPacks();
96
97 MCFOLD bool
98 _hasExpiredRealmsPlusSubscription(::Bedrock::NotNullNonOwnerPtr<::IEntitlementManager> entitlementManager) const;
99 // NOLINTEND
100
101public:
102 // constructor thunks
103 // NOLINTBEGIN
104 MCAPI void* $ctor(
105 ::IDlcValidation& dlcValidation,
106 ::IContentAcquisition& contentAcquisition,
107 ::IStoreCatalogRepository& storeCatalogRepository,
108 ::Bedrock::NotNullNonOwnerPtr<::IEntitlementManager> entitlementManager,
109 ::IClientInstance& clientInstance,
110 ::ILevelListCache& levelListCache
111 );
112 // NOLINTEND
113
114public:
115 // destructor thunk
116 // NOLINTBEGIN
117 MCAPI void $dtor();
118 // NOLINTEND
119
120public:
121 // virtual function thunks
122 // NOLINTBEGIN
123 MCAPI void $downloadPacks(
124 ::std::vector<::std::string> const& productIds,
125 ::std::function<void()> onCompleteCallback,
126 ::std::function<void(::World::PackDownloadError)> onErrorCallback
127 );
128
129 MCAPI ::World::PackDownloadProgressInfo $getProgress();
130
131 MCAPI void $getDownloadingPackTitles(::std::function<void(::std::vector<::std::string>)> packTitlesCallback);
132
133 MCAPI void $cancelDownloadPack();
134
135 MCAPI void
136 $getPackSizes(::std::vector<::std::string> const& productIds, ::std::function<void(uint64)> onCompleteCallback);
137
138 MCAPI ::World::PackCheckResult
139 $checkDlc(::std::string const& levelId, ::PackIdVersion const& packIdVersion, bool const isForRealms) const;
140 // NOLINTEND
141
142public:
143 // vftables
144 // NOLINTBEGIN
145 MCNAPI static void** $vftable();
146 // NOLINTEND
147};
148
149} // namespace World
Definition IClientInstance.h:5
Definition IContentAcquisition.h:5
Definition IDlcBatchModel.h:5
Definition IDlcBatcher.h:5
Definition IDlcValidation.h:5
Definition ILevelListCache.h:27
Definition WorldResourcePackDownloader.h:7
static MCAPI void ** $vftable()
Definition DlcValidationState.h:5
Definition PackIdVersion.h:10
Definition PackCheckResult.h:7
Definition PackDownloadProgressInfo.h:7