LeviLamina
Loading...
Searching...
No Matches
EncryptedFileAccessStrategy.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/NonOwnerPointer.h"
7#include "mc/resources/DirectoryPackAccessStrategy.h"
8#include "mc/resources/PackAccessAssetGenerationResult.h"
9#include "mc/resources/PackAccessStrategyType.h"
10
11// auto generated forward declare list
12// clang-format off
13class ContentIdentity;
17namespace Core { class Path; }
18// clang-format on
19
21public:
22 // member variables
23 // NOLINTBEGIN
26 // NOLINTEND
27
28public:
29 // prevent constructor by default
33
34public:
35 // virtual functions
36 // NOLINTBEGIN
37 // vIndex: 15
38 virtual ::PackAccessAssetGenerationResult generateAssetSet() /*override*/;
39
40 // vIndex: 5
41 virtual bool isTrusted() const /*override*/;
42
43 // vIndex: 4
44 virtual bool isWritable() const /*override*/;
45
46 // vIndex: 6
47 virtual bool hasAsset(::Core::Path const& packRelativePath, bool trustedContentOnly, bool caseSensative) const
48 /*override*/;
49
50 // vIndex: 8
51 virtual bool getAsset(::Core::Path const& packRelativePath, ::std::string& result, bool trustedContentOnly) const
52 /*override*/;
53
54 // vIndex: 14
55 virtual ::std::unique_ptr<::PackAccessStrategy> createSubPack(::Core::Path const& subPath) const /*override*/;
56
57 // vIndex: 20
58 virtual bool isAssetExtractionViable() const /*override*/;
59
60 // vIndex: 11
61 virtual ::PackAccessStrategyType getStrategyType() const /*override*/;
62
63 // vIndex: 19
64 virtual ::ContentIdentity readContentIdentity() const /*override*/;
65
66 // vIndex: 22
67 virtual ::std::string _getContentsFile();
68
69 // vIndex: 23
70 virtual ::std::string _getEncryptedAssetStream(::Core::Path const& packRelativePath) const;
71
72 // vIndex: 0
73 virtual ~EncryptedFileAccessStrategy() /*override*/;
74 // NOLINTEND
75
76public:
77 // member functions
78 // NOLINTBEGIN
80 ::ResourceLocation const& resourceLocation,
81 ::ContentIdentity const& contentIdentity,
82 ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const> const& keyProvider,
83 bool canRecurse,
84 ::std::optional<::std::unordered_map<::Core::Path, ::std::string>> assetSet
85 );
86 // NOLINTEND
87
88public:
89 // static functions
90 // NOLINTBEGIN
91 MCNAPI static bool
92 _getContentIdentityFromEncryptedStream(::std::string& stream, ::ContentIdentity& contentIdentity);
93
94 MCNAPI static void _transformStream(::std::string& stream, ::std::string const& key, uint64 offset);
95
96 MCNAPI static bool isValidEncryptedPack(::Core::Path const& pathToPack, ::ContentIdentity& contentIdentity);
97 // NOLINTEND
98
99public:
100 // constructor thunks
101 // NOLINTBEGIN
102 MCNAPI void* $ctor(
103 ::ResourceLocation const& resourceLocation,
104 ::ContentIdentity const& contentIdentity,
105 ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const> const& keyProvider,
106 bool canRecurse,
107 ::std::optional<::std::unordered_map<::Core::Path, ::std::string>> assetSet
108 );
109 // NOLINTEND
110
111public:
112 // destructor thunk
113 // NOLINTBEGIN
114 MCNAPI void $dtor();
115 // NOLINTEND
116
117public:
118 // virtual function thunks
119 // NOLINTBEGIN
120 MCNAPI ::PackAccessAssetGenerationResult $generateAssetSet();
121
122 MCNAPI bool $isTrusted() const;
123
124 MCNAPI bool $isWritable() const;
125
126 MCNAPI bool $hasAsset(::Core::Path const& packRelativePath, bool trustedContentOnly, bool caseSensative) const;
127
128 MCNAPI bool $getAsset(::Core::Path const& packRelativePath, ::std::string& result, bool trustedContentOnly) const;
129
130 MCNAPI ::std::unique_ptr<::PackAccessStrategy> $createSubPack(::Core::Path const& subPath) const;
131
132 MCNAPI bool $isAssetExtractionViable() const;
133
134 MCNAPI ::PackAccessStrategyType $getStrategyType() const;
135
136 MCNAPI ::ContentIdentity $readContentIdentity() const;
137
138 MCNAPI ::std::string $_getContentsFile();
139
140 MCNAPI ::std::string $_getEncryptedAssetStream(::Core::Path const& packRelativePath) const;
141 // NOLINTEND
142
143public:
144 // vftables
145 // NOLINTBEGIN
146 MCNAPI static void** $vftable();
147 // NOLINTEND
148};
Definition ContentIdentity.h:8
Definition Path.h:17
Definition DirectoryPackAccessStrategy.h:17
Definition EncryptedFileAccessStrategy.h:20
MCAPI bool $isWritable() const
static MCAPI void _transformStream(::std::string &stream, ::std::string const &key, uint64 offset)
MCAPI bool $isAssetExtractionViable() const
MCAPI::std::string $_getContentsFile()
MCAPI bool $isTrusted() const
MCAPI::ContentIdentity $readContentIdentity() const
static MCAPI bool isValidEncryptedPack(::Core::Path const &pathToPack, ::ContentIdentity &contentIdentity)
MCAPI bool $hasAsset(::Core::Path const &packRelativePath, bool trustedContentOnly, bool caseSensative) const
static MCAPI bool _getContentIdentityFromEncryptedStream(::std::string &stream, ::ContentIdentity &contentIdentity)
MCAPI EncryptedFileAccessStrategy(::ResourceLocation const &resourceLocation, ::ContentIdentity const &contentIdentity, ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const > const &keyProvider, bool canRecurse, ::std::optional<::std::unordered_map<::Core::Path, ::std::string > > assetSet)
MCAPI::std::string $_getEncryptedAssetStream(::Core::Path const &packRelativePath) const
MCAPI ::std::unique_ptr<::PackAccessStrategy > $createSubPack(::Core::Path const &subPath) const
static MCAPI void ** $vftable()
MCAPI::PackAccessStrategyType $getStrategyType() const
MCAPI void * $ctor(::ResourceLocation const &resourceLocation, ::ContentIdentity const &contentIdentity, ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const > const &keyProvider, bool canRecurse, ::std::optional<::std::unordered_map<::Core::Path, ::std::string > > assetSet)
MCAPI::PackAccessAssetGenerationResult $generateAssetSet()
MCAPI bool $getAsset(::Core::Path const &packRelativePath, ::std::string &result, bool trustedContentOnly) const
Definition IContentKeyProvider.h:13
Definition PackAccessStrategy.h:20
Definition Path.h:16
Definition ResourceLocation.h:14
Definition Alias.h:14