Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Downloader: Asynchronous downloading to memory, apply to release checker #3038

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

Vankata453
Copy link
Member

@Vankata453 Vankata453 commented Aug 8, 2024

Transfer is now a base class for two new derived classes: FileTransfer and StringTransfer. FileTransfer has the same functionality which Transfer had before - it writes received data to a file. StringTransfer, however, appends received data to a referenced string. These additions are also supported by WASM (NOTE: Needs to be tested).

A StringTransfer, which is requested by calling Downloader::request_string_download(), is now used for downloading the "supertux-versioninfo" file, used by the in-game release checker.

Additionally:

  • WASM now supports downloaders, other than the AddonManager one, by providing a pointer to the current Downloader (NOTE: Needs to be tested).
  • Support for parent TransferStatusLists has been added to all Downloader functions.
  • ReaderDocument now contains the from_string() static function, which is a convenience wrapper around from_stream(), where a stream, which only has the given string in its buffer, is provided.

Closes #2627.

@Vankata453 Vankata453 added type:feature category:code status:needs-review Work needs to be reviewed by other people labels Aug 8, 2024
@Vankata453 Vankata453 added this to the 0.7.0 milestone Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:code status:needs-review Work needs to be reviewed by other people type:feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Accessing downloaded files without saving locally
1 participant