15class FileDownloadManager :
public ::std::enable_shared_from_this<::FileDownloadManager> {
35 FileDownloadManager& operator=(FileDownloadManager
const&);
36 FileDownloadManager(FileDownloadManager
const&);
37 FileDownloadManager();
43 virtual ~FileDownloadManager() =
default;
45 virtual ~FileDownloadManager();
48 virtual void update();
50 virtual void cancelDownload();
52 virtual float getDownloadProgress()
const;
59 MCNAPI FileDownloadManager(
60 ::std::shared_ptr<::IFilePicker> filePicker,
61 ::std::shared_ptr<::IFileChunkDownloader> fileDownloader
64 MCNAPI
void _writeData(
65 ::std::vector<uchar> data,
69 ::std::function<
void(uint64,
bool)> writeComplete
72 MCNAPI
void downloadFile(
73 ::std::string
const& downloadId,
74 ::std::string
const& downloadUrl,
76 uint64 expectedFileSize,
77 uint64 fromByteOffset,
78 ::std::string
const& downloadVersion,
79 ::std::function<
void(
::Core::Path const&, ::DownloaderResult)> onCompleteCallback,
90 $ctor(::std::shared_ptr<::IFilePicker> filePicker, ::std::shared_ptr<::IFileChunkDownloader> fileDownloader);
104 MCNAPI
void $update();
106 MCNAPI
void $cancelDownload();
108 MCNAPI
float $getDownloadProgress()
const;