LeviLamina
Loading...
Searching...
No Matches
MinecraftServiceKeyManager.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/threading/Async.h"
7#include "mc/deps/core/utility/EnableNonOwnerReferences.h"
8#include "mc/platform/brstd/future.h"
9
10// auto generated forward declare list
11// clang-format off
13class TaskGroup;
16namespace Bedrock::Http { struct Url; }
17// clang-format on
18
19class MinecraftServiceKeyManager : public ::Bedrock::EnableNonOwnerReferences {
20public:
21 // MinecraftServiceKeyManager inner types declare
22 // clang-format off
24 // clang-format on
25
26 // MinecraftServiceKeyManager inner types define
27 struct BlockingInitRecursiveContext {
28 public:
29 // member variables
30 // NOLINTBEGIN
32 // NOLINTEND
33
34 public:
35 // prevent constructor by default
36 BlockingInitRecursiveContext& operator=(BlockingInitRecursiveContext const&);
37 BlockingInitRecursiveContext(BlockingInitRecursiveContext const&);
38 BlockingInitRecursiveContext();
39 };
40
41public:
42 // member variables
43 // NOLINTBEGIN
59 // NOLINTEND
60
61public:
62 // prevent constructor by default
63 MinecraftServiceKeyManager& operator=(MinecraftServiceKeyManager const&);
64 MinecraftServiceKeyManager(MinecraftServiceKeyManager const&);
65 MinecraftServiceKeyManager();
66
67public:
68 // virtual functions
69 // NOLINTBEGIN
70 virtual ~MinecraftServiceKeyManager() /*override*/;
71 // NOLINTEND
72
73public:
74 // member functions
75 // NOLINTBEGIN
77 ::std::unique_ptr<::IMinecraftServiceKeySource> keySource,
78 ::std::function<int64()> timeFn,
80 ::std::function<::Bedrock::Threading::Async<
81 ::std::optional<::MinecraftServiceKeysMetadata>>(::TaskGroup&, ::std::string const&, bool)> metadataFn,
82 ::std::function<::Bedrock::Threading::Async<::std::optional<
83 ::std::unordered_map<::std::string, ::std::string>>>(::TaskGroup&, ::std::string const&, bool)> keysFn
84 );
85
86#ifdef LL_PLAT_S
87 MCNAPI void _blockingInitRecursive(
88 ::MinecraftServiceKeyInfo keyFetchResult,
89 ::std::shared_ptr<::MinecraftServiceKeyManager::BlockingInitRecursiveContext> context
90 );
91#endif
92
93 MCNAPI ::Bedrock::Threading::Async<::MinecraftServiceKeyInfo> _fullFetch(bool highPriority);
94
95 MCNAPI bool _saveMetadata(::std::optional<::MinecraftServiceKeysMetadata> const& metadata);
96
97 MCNAPI void _updateTrustedKeys();
98
99#ifdef LL_PLAT_S
100 MCNAPI ::brstd::future<bool> blockingInit();
101#endif
102
103 MCNAPI ::std::string getKeyFromKeyId(::std::string const& kid) const;
104
105 MCNAPI ::MinecraftServiceKeyInfo getKeyInfo() const;
106
107 MCNAPI void setHostKey(::std::string const& hostKey);
108 // NOLINTEND
109
110public:
111 // constructor thunks
112 // NOLINTBEGIN
113 MCNAPI void* $ctor(
114 ::std::unique_ptr<::IMinecraftServiceKeySource> keySource,
115 ::std::function<int64()> timeFn,
117 ::std::function<::Bedrock::Threading::Async<
118 ::std::optional<::MinecraftServiceKeysMetadata>>(::TaskGroup&, ::std::string const&, bool)> metadataFn,
119 ::std::function<::Bedrock::Threading::Async<::std::optional<
120 ::std::unordered_map<::std::string, ::std::string>>>(::TaskGroup&, ::std::string const&, bool)> keysFn
121 );
122 // NOLINTEND
123
124public:
125 // destructor thunk
126 // NOLINTBEGIN
127 MCNAPI void $dtor();
128 // NOLINTEND
129
130public:
131 // vftables
132 // NOLINTBEGIN
133 MCNAPI static void** $vftable();
134 // NOLINTEND
135};
Definition EnableNonOwnerReferences.h:7
Definition Async.h:8
Definition IMinecraftServiceKeySource.h:14
MCAPI void setHostKey(::std::string const &hostKey)
MCAPI void _updateTrustedKeys()
MCAPI void * $ctor(::std::unique_ptr<::IMinecraftServiceKeySource > keySource, ::std::function< int64()> timeFn, ::std::function<::Bedrock::Threading::Async<::Bedrock::Http::Url >()> urlFn, ::std::function<::Bedrock::Threading::Async< ::std::optional<::MinecraftServiceKeysMetadata > >(::TaskGroup &, ::std::string const &, bool)> metadataFn, ::std::function<::Bedrock::Threading::Async<::std::optional< ::std::unordered_map<::std::string, ::std::string > > >(::TaskGroup &, ::std::string const &, bool)> keysFn)
MCAPI bool _saveMetadata(::std::optional<::MinecraftServiceKeysMetadata > const &metadata)
MCAPI MinecraftServiceKeyManager(::std::unique_ptr<::IMinecraftServiceKeySource > keySource, ::std::function< int64()> timeFn, ::std::function<::Bedrock::Threading::Async<::Bedrock::Http::Url >()> urlFn, ::std::function<::Bedrock::Threading::Async< ::std::optional<::MinecraftServiceKeysMetadata > >(::TaskGroup &, ::std::string const &, bool)> metadataFn, ::std::function<::Bedrock::Threading::Async<::std::optional< ::std::unordered_map<::std::string, ::std::string > > >(::TaskGroup &, ::std::string const &, bool)> keysFn)
MCAPI::MinecraftServiceKeyInfo getKeyInfo() const
static MCAPI void ** $vftable()
MCAPI ::Bedrock::Threading::Async<::MinecraftServiceKeyInfo > _fullFetch(bool highPriority)
MCAPI::std::string getKeyFromKeyId(::std::string const &kid) const
Definition TaskGroup.h:57
Definition Url.h:7
Definition MinecraftServiceKeyInfo.h:5
Definition MinecraftServiceKeyManager.h:27
Definition MinecraftServiceKeysMetadata.h:5
Definition context.h:5
Definition Alias.h:14