LeviLamina
Loading...
Searching...
No Matches
User.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/social/RelationshipStatus.h"
7#include "mc/client/social/UserPlatformConnectionResult.h"
8#include "mc/client/social/UserPlatformConnectionState.h"
9#include "mc/common/GameUserType.h"
10#include "mc/deps/core/file/PathBuffer.h"
11#include "mc/deps/core/platform/BuildPlatform.h"
12#include "mc/deps/core/threading/Async.h"
13#include "mc/deps/core/utility/NonOwnerPointer.h"
14#include "mc/identity/IdentityEventResponse.h"
15#include "mc/identity/IdentityType.h"
16
17// auto generated forward declare list
18// clang-format off
19class CallbackToken;
21class IClientInstance;
22class IOptions;
23namespace Bedrock::PubSub { class Subscription; }
24namespace Core { class FileStorageArea; }
25namespace Core { class Path; }
26namespace Social { class IUserDataObject; }
27namespace Social { class Identity; }
28namespace Social { class PlatformImageService; }
29namespace Social { class ProfileImageOptions; }
30namespace Social { class UserData; }
31namespace Social { class UserManager; }
32namespace Social { class XboxLiveUser; }
33namespace Social { struct AuthToken; }
34namespace Social { struct MultiIdentitySigninResult; }
35namespace Social { struct PermissionCheckResult; }
36namespace Social { struct PlatformUserProfileData; }
37namespace Social { struct UserBanDetails; }
38namespace Social { struct UserSignInProperties; }
39namespace mce { struct Image; }
40// clang-format on
41
42namespace Social {
43
44class User : public ::std::enable_shared_from_this<::Social::User> {
45public:
46 // virtual functions
47 // NOLINTBEGIN
48 // vIndex: 0
49 virtual ~User() = default;
50
51 // vIndex: 1
52 virtual void initStorageAreas() = 0;
53
54 // vIndex: 2
55 virtual ::GameUserType getType() const = 0;
56
57 // vIndex: 3
58 virtual bool isPrimaryUser() const = 0;
59
60 // vIndex: 4
61 virtual bool isAnonymous() const = 0;
62
63 // vIndex: 5
64 virtual bool isConnected() const = 0;
65
66 // vIndex: 6
67 virtual bool isReady() const = 0;
68
69 // vIndex: 7
70 virtual bool needsPlatformReconnect() const = 0;
71
72 // vIndex: 8
73 virtual bool isSignedIn(::Social::IdentityType) const = 0;
74
75 // vIndex: 10
76 virtual bool isSignInInProgress(::Social::IdentityType) const = 0;
77
78 // vIndex: 9
79 virtual bool isSignInInProgress() const = 0;
80
81 // vIndex: 11
82 virtual bool signIn(::Social::UserSignInProperties const&) = 0;
83
84 // vIndex: 12
85 virtual void cancelSignIn(::Social::IdentityType) = 0;
86
87 // vIndex: 13
88 virtual void signOut(::Social::IdentityType, ::std::function<void(bool)>) = 0;
89
90 // vIndex: 14
91 virtual void clearCachedCredentials(::Social::IdentityType) = 0;
92
93 // vIndex: 15
94 virtual bool hasNetworkPrivileges() const = 0;
95
96 // vIndex: 16
97 virtual ::Bedrock::PubSub::Subscription registerIdentitySignInSubscriber(
98 ::Social::IdentityType,
99 ::std::function<void(uint, ::Social::IdentityType)>
100 ) = 0;
101
102 // vIndex: 17
103 virtual ::Bedrock::PubSub::Subscription registerIdentitySignOutSubscriber(
104 ::Social::IdentityType,
105 ::std::function<void(uint, ::Social::IdentityType)>
106 ) = 0;
107
108 // vIndex: 18
109 virtual ::CallbackToken connectAsync(::std::function<void(::Social::UserPlatformConnectionResult)>, bool) = 0;
110
111 // vIndex: 19
112 virtual void enterOfflineMode(::std::function<void(bool)>) = 0;
113
114 // vIndex: 20
115 virtual ::Social::UserPlatformConnectionState getPlatformConnectionState() const = 0;
116
117 // vIndex: 21
118 virtual uint getLocalUserId() const = 0;
119
120 // vIndex: 22
121 virtual ::std::string const& getId(::Social::IdentityType) const = 0;
122
123 // vIndex: 23
124 virtual ::std::string const& getMinecraftAccountID() const = 0;
125
126 // vIndex: 25
127 virtual void
128 getAuthToken(::Social::IdentityType, ::std::string const&, ::std::function<void(::Social::AuthToken)>) const = 0;
129
130 // vIndex: 24
131 virtual ::Bedrock::Threading::Async<::Social::AuthToken>
132 getAuthToken(::Social::IdentityType, ::std::string const&) const = 0;
133
134 // vIndex: 26
135 virtual ::std::string const& getPlayFabSessionTicket() const = 0;
136
137 // vIndex: 27
138 virtual ::std::string const& getPlayFabEntityToken() const = 0;
139
140 // vIndex: 29
141 virtual ::std::shared_ptr<::Social::Identity> getIdentity(::Social::IdentityType) = 0;
142
143 // vIndex: 28
144 virtual ::std::shared_ptr<::Social::Identity const> const getIdentity(::Social::IdentityType) const = 0;
145
146 // vIndex: 30
147 virtual bool hasIdentity(::Social::IdentityType) const = 0;
148
149 // vIndex: 31
150 virtual void setShouldTransferDeviceAccountToXboxLive(bool const) = 0;
151
152 // vIndex: 32
153 virtual bool shouldLinkPlayFabAndLiveAccounts() const = 0;
154
155 // vIndex: 33
156 virtual ::Bedrock::Threading::Async<bool> unlinkXboxLiveAccount() = 0;
157
158 // vIndex: 34
159 virtual void getUserDataObject(::Social::IUserDataObject&) const = 0;
160
161 // vIndex: 35
162 virtual void setUserDataObject(::Social::IUserDataObject const&) = 0;
163
164 // vIndex: 36
165 virtual ::Social::UserData const getUserData(::std::string const&) const = 0;
166
167 // vIndex: 37
168 virtual void setUserData(::std::string const&, ::Social::UserData const&) = 0;
169
170 // vIndex: 38
171 virtual void tick() = 0;
172
173 // vIndex: 39
174 virtual void finalize() = 0;
175
176 // vIndex: 40
177 virtual void disconnect() = 0;
178
179 // vIndex: 41
180 virtual void signOutFromPlatform() = 0;
181
182 // vIndex: 42
183 virtual bool isFinalized() const = 0;
184
185 // vIndex: 43
186 virtual ::CloudSaveSystemWrapper& getCloudSaveSystem() = 0;
187
188 // vIndex: 45
189 virtual ::std::string getDisplayName() const = 0;
190
191 // vIndex: 44
192 virtual ::std::string getDisplayName(::Social::IdentityType) const = 0;
193
194 // vIndex: 46
195 virtual ::Bedrock::PubSub::Subscription
196 registerDisplayNameChangedSubscriber(::std::function<void(::std::string const&)>) = 0;
197
198 // vIndex: 47
199 virtual ::std::shared_ptr<::Core::FileStorageArea> const getStorageArea() const = 0;
200
201 // vIndex: 48
202 virtual ::Core::Path getSettingsDirectoryPath() const = 0;
203
204 // vIndex: 49
205 virtual bool hasValidSettingsDirectoryPath() const = 0;
206
207 // vIndex: 50
208 virtual ::std::shared_ptr<::IOptions> const getOptions() const = 0;
209
210 // vIndex: 51
211 virtual ::Social::XboxLiveUser& getLiveUser() const = 0;
212
213 // vIndex: 52
214 virtual void
215 checkPrivilegeWithUIAsync(int, ::std::string const&, ::std::function<void(::Social::PermissionCheckResult)>) = 0;
216
217 // vIndex: 53
218 virtual ::RelationshipStatus mayChatWith(::std::string const&) = 0;
219
220 // vIndex: 54
221 virtual bool mayChatWithMe(::std::string const&) const = 0;
222
223 // vIndex: 55
224 virtual bool isMutedPlayer(::std::string const&) = 0;
225
226 // vIndex: 56
227 virtual ::Social::PermissionCheckResult multiplayerAllowed() const = 0;
228
229 // vIndex: 57
230 virtual ::Social::PermissionCheckResult chatAllowed() const = 0;
231
232 // vIndex: 58
233 virtual ::Social::PermissionCheckResult addFriendAllowed() const = 0;
234
235 // vIndex: 59
236 virtual ::Social::PermissionCheckResult userGeneratedContentAllowed() const = 0;
237
238 // vIndex: 60
239 virtual ::Social::PermissionCheckResult createAndJoinClubsAllowed() const = 0;
240
241 // vIndex: 61
242 virtual ::Social::PermissionCheckResult viewingProfilesAllowed() const = 0;
243
244 // vIndex: 62
245 virtual ::Social::PermissionCheckResult uploadCapturesAllowed() const = 0;
246
247 // vIndex: 63
248 virtual bool isRemotePlatformUser() const = 0;
249
250 // vIndex: 64
251 virtual bool shouldClearChatOnJoinGame() const = 0;
252
253 // vIndex: 65
254 virtual int getGameControllerId() const = 0;
255
256 // vIndex: 66
257 virtual void setGameControllerId(int) = 0;
258
259 // vIndex: 67
260 virtual ::std::string getPlatformID() const = 0;
261
262 // vIndex: 68
263 virtual bool hasPremiumPlatformAccess() const = 0;
264
265 // vIndex: 69
266 virtual void checkPremiumPlatformStatusAsync(::std::function<void(bool)>) = 0;
267
268 // vIndex: 70
269 virtual bool hasPlatformIcons() const = 0;
270
271 // vIndex: 71
272 virtual bool hasPlatformProfileCards() const = 0;
273
274 // vIndex: 72
275 virtual void
276 getLinkedXuids(::std::function<void(::std::string, ::std::string)>, ::std::vector<::std::string> const&) = 0;
277
278 // vIndex: 73
279 virtual void
280 getLinkedPlatformIds(::std::function<void(::std::string, ::std::string)>, ::std::vector<::std::string> const&) = 0;
281
282 // vIndex: 74
283 virtual ::Social::PlatformImageService& getPlatformFriendsImageService() = 0;
284
285 // vIndex: 75
286 virtual void
287 getPlatformProfile(::std::string const&, ::std::function<void(::Social::PlatformUserProfileData&)>) = 0;
288
289 // vIndex: 76
290 virtual void getPlatformProfiles(
291 ::std::vector<::std::string> const&,
292 ::std::function<void(::std::vector<::Social::PlatformUserProfileData>&&)>
293 ) = 0;
294
295 // vIndex: 77
296 virtual ::Social::ProfileImageOptions getDefaultProfileImageOptions() const = 0;
297
298 // vIndex: 78
299 virtual ::Bedrock::Threading::Async<::std::shared_ptr<::mce::Image>>
300 getProfileImage(::Social::ProfileImageOptions const&) = 0;
301
302 // vIndex: 79
303 virtual ::Bedrock::Threading::Async<::Core::PathBuffer<::std::string>>
304 getProfileImageFile(::Social::ProfileImageOptions const&) = 0;
305
306 // vIndex: 80
307 virtual bool canSignInToXBL() const = 0;
308
309 // vIndex: 81
310 virtual void setNeedsPlatformReconnect() = 0;
311
312 // vIndex: 82
313 virtual ::std::string getPlatformOfflineID() const = 0;
314
315 // vIndex: 83
316 virtual ::std::string getPlatformOnlineID() const = 0;
317
318 // vIndex: 84
319 virtual void associateClientInstance(::std::shared_ptr<::IClientInstance>) = 0;
320
321 // vIndex: 86
322 virtual ::std::weak_ptr<::IClientInstance> getAssociateClientInstance() = 0;
323
324 // vIndex: 85
325 virtual ::std::weak_ptr<::IClientInstance const> const getAssociateClientInstance() const = 0;
326
327 // vIndex: 87
328 virtual void setPresence(::std::string const&) = 0;
329
330 // vIndex: 88
331 virtual void clearPresence() = 0;
332
333 // vIndex: 89
334 virtual bool hasPlayedLegacyGame() const = 0;
335
336 // vIndex: 90
337 virtual bool getLegacyOptionsData(::std::vector<uchar>&) const = 0;
338
339 // vIndex: 91
340 virtual void onAppSuspend() = 0;
341
342 // vIndex: 92
343 virtual void onAppResumed() = 0;
344
345 // vIndex: 93
346 virtual ::std::optional<::Social::UserBanDetails> getBanInfo() const = 0;
347
348 // vIndex: 94
349 virtual void updateAppearanceDisplayName(::std::string const&) = 0;
350
351 // vIndex: 95
352 virtual void initIdentity() = 0;
353
354 // vIndex: 96
355 virtual void setUserManager(::Bedrock::NonOwnerPointer<::Social::UserManager>) = 0;
356
357 // vIndex: 97
358 virtual void _onSignOut(::Social::IdentityType) = 0;
359
360 // vIndex: 98
361 virtual void _notifyIdentitiesOfSignIn(
362 ::std::shared_ptr<::Social::Identity>,
363 ::std::function<bool(::Social::IdentityEventResponse, ::std::shared_ptr<::Social::Identity>)>
364 ) = 0;
365
366 // vIndex: 99
367 virtual void _notifyIdentitySignInEventSubscribers(::Social::IdentityType) = 0;
368
369 // vIndex: 100
370 virtual void _notifyIdentitySignOutEventSubscribers(::Social::IdentityType) = 0;
371
372 // vIndex: 101
373 virtual void setStorageArea(::std::shared_ptr<::Core::FileStorageArea>, ::BuildPlatform) = 0;
374
375 // vIndex: 102
376 virtual void _postSignInSteps(::Social::MultiIdentitySigninResult, ::std::vector<::Social::IdentityType>&) = 0;
377
378 // vIndex: 103
379 virtual void _finalizeSignIn(
381 ::std::vector<::Social::IdentityType>&&,
382 ::std::set<::Social::IdentityType>&&
383 ) = 0;
384 // NOLINTEND
385
386public:
387 // virtual function thunks
388 // NOLINTBEGIN
389
390 // NOLINTEND
391};
392
393} // namespace Social
Definition NonOwnerPointer.h:9
Definition CallbackToken.h:5
Definition CloudSaveSystemWrapper.h:5
Definition IClientInstance.h:186
Definition IOptions.h:38
Definition Path.h:16
Definition IUserDataObject.h:12
Definition ProfileImageOptions.h:7
Definition UserData.h:7
Definition User.h:44
Definition AuthToken.h:10
Definition MultiIdentitySigninResult.h:7
Definition PermissionCheckResult.h:7
Definition PlatformUserProfileData.h:7
Definition UserSignInProperties.h:7