Class AsyncWebResponse

#include <Geode/utils/web.hpp>
classAsyncWebResponse{ ... }
No description provided
Examples0
Public static methods0
Public member functions5
geode::utils::web::AsyncWebResult<std::monostate>into()

Download into a stream. Make sure the stream lives for the entire duration of the request. If you want to download a file, use the ghc::filesystem::path overload of into instead

Parameters

stream

Stream to download into. Make sure it lives long enough, otherwise the web request will crash
Return value
AsyncWebResult, where you can specify the `then` action for after the download is finished. The result has a `std::monostate` template parameter, as it can be assumed you know what you passed into `into`
geode::utils::web::AsyncWebResult<std::monostate>into()

Download into a file

Parameters

path

File to download into. If it already exists, it will be overwritten.
Return value
AsyncWebResult, where you can specify the `then` action for after the download is finished. The result has a `std::monostate` template parameter, as it can be assumed you know what you passed into `into`
geode::utils::web::AsyncWebResult<std::string>text()

Download into memory as a string

Return value
AsyncWebResult, where you can specify the `then` action for after the download is finished
intbytes()

Download into memory as a byte array

Return value
AsyncWebResult, where you can specify the `then` action for after the download is finished
geode::utils::web::AsyncWebResult<matjson::Value>json()

Download into memory as JSON

Return value
AsyncWebResult, where you can specify the `then` action for after the download is finished
Fields0
Protected member functions0
Protected fields0