52 enum class ExportType :
int {
56 PlayableEditorLevel = 3,
58 PackagedLevelOnly = 5,
61 enum class ShowToast :
int {
66 enum class State :
int {
72 struct CopyWorldResult {
76 ::ll::TypedStorage<4, 4, ::FileArchiverOutcome> outcome;
77 ::ll::TypedStorage<8, 32, ::std::string> copiedLevelId;
78 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> copiedLevelPath;
85 CopyWorldResult& operator=(CopyWorldResult
const&);
95 MCAPI ~CopyWorldResult();
120 ::ll::TypedStorage<1, 1, bool> isCloudImport;
121 ::ll::TypedStorage<1, 1, bool> allowMultiplayer;
122 ::ll::TypedStorage<8, 32, ::std::string> educationOid;
123 ::ll::TypedStorage<8, 32, ::std::string> cTag;
124 ::ll::TypedStorage<8, 32, ::std::string> name;
140 ::ll::TypedStorage<4, 4, ::FileArchiverOutcome> outcome;
141 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> path;
148 ::ll::TypedStorage<4, 4, ::FileArchiverOutcome> outcome;
149 ::ll::TypedStorage<8, 24, ::std::vector<::FileArchiver::ImportWorldsResult::ImportWorldResult>> worlds;
157 ::ll::TypedStorage<8, 80, ::Bedrock::Threading::Mutex> mProgressLock;
158 ::ll::TypedStorage<8, 32, ::std::string> mProgressTitle;
159 ::ll::TypedStorage<8, 32, ::std::string> mProgressMessage;
167 virtual void clear() ;
174 MCAPI ::std::string getProgressMessage();
176 MCAPI ::std::string getProgressTitle();
179 MCAPI
void setProgressMessage(::std::string
const& message);
195 ::ll::TypedStorage<4, 4, ::FileArchiverOutcome> outcome;
196 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> fileName;
197 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> levelId;
198 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> originalLevelId;
203 Result& operator=(Result
const&);
231 ::ll::TypedStorage<4, 4, ::FileArchiver::ExportType> mExportType;
232 ::ll::TypedStorage<8, 32, ::std::string> mLevelId;
233 ::ll::TypedStorage<8, 8, uint64> mTotalFileCount;
234 ::ll::TypedStorage<8, 104, ::FileArchiver::Result> mResult;
235 ::ll::TypedStorage<8, 16, ::Bedrock::UniqueOwnerPointer<::LevelStorage>> mLevelStorage;
236 ::ll::TypedStorage<8, 8, ::LevelData*> mLevelData;
237 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::LevelData>> mOwnedLevelData;
238 ::ll::TypedStorage<8, 32, ::Core::PathBuffer<::std::string>> mWorldPath;
246 ::ll::TypedStorage<1, 2, ::std::optional<bool>> mKeepPlayerData;
256 virtual void enqueueConvertImportingWorldTasks(
257 ::std::shared_ptr<::FileArchiver::Result>& sharedResult,
258 ::Bedrock::NotNullNonOwnerPtr<::FileArchiver::ProgressReporter> progress,
262 virtual bool shouldCopyWorldForConversion(::std::string
const& levelId)
const = 0;
264 virtual void enqueueConvertExportingWorldTasks(
265 ::std::shared_ptr<::FileArchiver::ExportData>& exportData,
266 ::Bedrock::NotNullNonOwnerPtr<::FileArchiver::ProgressReporter> progress,
268 ::gsl::not_null<::std::shared_ptr<::FileArchiver::InterventionPublishers>> interventionPublishers,
269 ::std::optional<::FileArchiver::WorldConverterExportSettings>
const exportSetting
272 virtual bool prepareEditorProjectForSaveSnapshot(
279 struct InterventionPublishers {
282 using BeginSignature = void(::FileArchiver::ExportType, ::std::string
const&,
::Core::Path const&);
284 using CleanupSignature = void(::FileArchiver::ExportType);
286 using CopyCompleteSignature =
289 using LevelDataFinalizeSignature = void(::FileArchiver::ExportType,
::LevelData&);
291 using LevelDataMutationSignature = void(::FileArchiver::ExportType,
::LevelData&);
293 using PreFileRemovalSignature =
296 using PrePackageSignature =
306 void(::FileArchiver::ExportType, ::std::string
const&,
::Core::Path const&),
361 MCAPI InterventionPublishers();
376 ::ll::TypedStorage<8, 192, ::FileArchiver::ProgressReporter> mProgress;
377 ::ll::TypedStorage<8, 80, ::Bedrock::Threading::Mutex> mStateLock;
378 ::ll::TypedStorage<4, 4, ::FileArchiver::State> mCurrentState;
379 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::Core::FilePathManager>> mFilePathManager;
380 ::ll::TypedStorage<8, 64, ::std::function<void(::std::string
const&)>> mDisplayMessageCallback;
381 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::IResourcePackRepository>> mResourcePackRepository;
382 ::ll::TypedStorage<8, 8, ::ILevelListCache&> mLevelListCache;
383 ::ll::TypedStorage<8, 8, ::LevelStorageSource&> mLevelStorageSource;
384 ::ll::TypedStorage<8, 24, ::std::vector<::Core::PathBuffer<::std::string>>> mSuccessfullyFiledArchives;
385 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::TaskGroup>> mIOTaskGroup;
386 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::FileArchiver::IWorldConverter>> mWorldConverter;
387 ::ll::TypedStorage<1, 1, bool> mIsEditorModeEnabled;
388 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const>> mKeyProvider;
389 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::LevelDbEnv>> mLevelDbEnv;
390 ::ll::TypedStorage<8, 64, ::std::unordered_map<::std::string, ::FileArchiver::EduCloudImportInfo>>
396 FileArchiver& operator=(FileArchiver
const&);
397 FileArchiver(FileArchiver
const&);
403 virtual ~FileArchiver() =
default;
405 virtual ::std::shared_ptr<::FilePickerSettings>
406 generateFilePickerSettings(::std::vector<::FileArchiver::ExportType>
const& types, ::std::string
const&)
const;
416 ::Bedrock::NotNullNonOwnerPtr<::Core::FilePathManager>
const& pathManager,
417 ::Bedrock::NotNullNonOwnerPtr<::IResourcePackRepository>
const& resourcePackRepository,
418 bool isEditorModeEnabled,
419 ::std::unique_ptr<::FileArchiver::IWorldConverter> worldConverter,
420 ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const> keyProvider,
421 ::Bedrock::NotNullNonOwnerPtr<::LevelDbEnv> levelDbEnv,
422 ::std::function<
void(::std::string
const&)> displayMessageFunction
425 MCAPI
void _clearArchiverState();
430 MCAPI ::Bedrock::Threading::Async<::FileArchiver::Result> _enqueueExportWorldTasks(
432 ::std::string
const& worldId,
434 ::FileArchiver::ExportType exportType,
435 ::FileArchiver::ShowToast
const showToast,
437 ::gsl::not_null<::std::shared_ptr<::FileArchiver::InterventionPublishers>> interventionPublishers,
439 ::std::optional<::FileArchiver::WorldConverterExportSettings>
const exportSetting,
443 MCAPI
void _exportLevelFiles(
446 ::std::shared_ptr<::FileArchiver::ExportData> exportData,
451 MCAPI
bool _importWorld(
454 ::std::string
const& importLevelId
461 MCAPI
void _printLevelStartMessage();
464 MCAPI
void _printMessage(::std::string
const& message);
466 MCAPI ::FileArchiver::Result _tryBeginExportLevel(
467 ::std::string
const& levelId,
469 ::FileArchiver::ShowToast
const showToast
472 MCAPI
bool _validatePremiumUpgradePacks(
::Core::Path const& filePath);
475 MCAPI ::std::string copyLevel(::std::string
const& worldId,
::Core::Path const& targetFolder);
477 MCAPI ::Bedrock::Threading::Async<::FileArchiver::CopyWorldResult> copyLevelAsync(::std::string
const& worldId);
480 MCAPI ::Bedrock::Threading::Async<::FileArchiver::Result> exportCurrentEditorLevel(
483 ::gsl::not_null<::std::shared_ptr<::FileArchiver::InterventionPublishers>> interventionPublishers,
484 ::std::optional<::FileArchiver::WorldConverterExportSettings> exportSetting,
485 ::FileArchiver::ExportType exportType,
486 ::FileArchiver::ShowToast toast
489 MCAPI
void exportCurrentLevel(
492 ::FileArchiver::ExportType exportType,
495 ::gsl::not_null<::std::shared_ptr<::FileArchiver::InterventionPublishers>> interventionPublishers
499 MCAPI
void exportLevel(
500 ::std::string
const& worldId,
502 ::FileArchiver::ExportType exportType,
505 ::FileArchiver::ShowToast showToast,
506 ::gsl::not_null<::std::shared_ptr<::FileArchiver::InterventionPublishers>> interventionPublishers
510 MCAPI
void exportPack(
517 MCAPI ::Bedrock::Threading::Async<::FileArchiver::Result> importLevel(
519 bool suppressStartMessage,
520 bool suppressEndMessage,
521 ::std::string
const& levelId
524 MCAPI
void importLevel(
527 bool suppressStartMessage,
528 bool suppressEndMessage,
529 ::std::string
const& levelId
532 MCAPI
void setEduCloudImportInfo(
533 ::std::string
const& worldId,
534 ::std::string
const& cTag,
535 ::std::string
const& name,
536 ::std::string
const& oid,
537 bool allowMultiplayer
545 MCAPI
static void _revertPremiumUpgradePacks(
::Core::Path const& filePath);
548 MCAPI
static void _sanitizeWorld(
::Core::Path const& newWorldPath);
556 MCAPI static ::std::string
const& EXTENSION_ADDON();
559 MCAPI static ::std::string
const& EXTENSION_PROJECT();
561 MCAPI static ::std::string
const& EXTENSION_RESOURCEPACK();
563 MCAPI static ::std::string
const& EXTENSION_TEMPLATE();
565 MCAPI static ::std::string
const& EXTENSION_VANILLA();
567 MCAPI static ::std::string
const& IMPORT_LOCK_FILE();
577 ::Bedrock::NotNullNonOwnerPtr<::Core::FilePathManager>
const& pathManager,
578 ::Bedrock::NotNullNonOwnerPtr<::IResourcePackRepository>
const& resourcePackRepository,
579 bool isEditorModeEnabled,
580 ::std::unique_ptr<::FileArchiver::IWorldConverter> worldConverter,
581 ::Bedrock::NotNullNonOwnerPtr<::IContentKeyProvider const> keyProvider,
582 ::Bedrock::NotNullNonOwnerPtr<::LevelDbEnv> levelDbEnv,
583 ::std::function<
void(::std::string
const&)> displayMessageFunction
590 MCAPI ::std::shared_ptr<::FilePickerSettings>
591 $generateFilePickerSettings(::std::vector<::FileArchiver::ExportType>
const& types, ::std::string
const&)
const;
Definition IContentKeyProvider.h:13