Represents a HTTP response body. More...
Public Attributes | |
std::optional< BString > | text |
A string containing the body of the HTTP request. | |
Represents a HTTP response body.
The HTTP response body is captured in this object. The body is either stored into a target, or into a text variable, depending on how you called the BHttpSession::Execute() method.
You will usually get a reference to this object through the BHttpResult::Body() method. If you want to keep the contents of the body beyond the lifetime of the BHttpResult object, you should move the data into owned objects of your own.
std::optional< BString > BPrivate::Network::BHttpBody::text |
A string containing the body of the HTTP request.
The value of this class variable is set to std::nullopt
if the target body was written to a specified target. Otherwise, the response body is stored in this string. If the response body was empty, then this will be an empty string.