# BodyDecoder.hpp
This File On Github
Ask A Question
API: latest
module: oatpp-curl
#include "oatpp-curl/io/BodyDecoder.hpp"
# BodyDecoder
Custom BodyDecoder for oatpp::curl::RequestExecutor. Extends oatpp::web::protocol::http::incoming::BodyDecoder.
namespace oatpp { namespace curl { namespace io {
class BodyDecoder : public oatpp::web::protocol::http::incoming::BodyDecoder {}
}}}
# Typedefs
Type | Name | Summary |
---|---|---|
oatpp::data::share::LazyStringMultimap<oatpp::data::share::StringKeyLabelCI> | Headers | Typedef for headers map. Headers map key is case-insensitive. For more info see oatpp::data::share::LazyStringMultimap. |
# Methods
Return Type | Name | Summary |
---|---|---|
void | decode | Just transfer everything we have in bodyStream to toStream as-is |
oatpp::async::CoroutineStarter | decodeAsync | Just transfer everything we have in bodyStream to toStream as-is |
# BodyDecoder::Headers
Typedef for headers map. Headers map key is case-insensitive. For more info see oatpp::data::share::LazyStringMultimap.
typedef oatpp::data::share::LazyStringMultimap<oatpp::data::share::StringKeyLabelCI> Headers
# BodyDecoder::decode
Just transfer everything we have in bodyStream to toStream as-is Curl already did all decoding.
- @param headers - Headers map. oatpp::web::protocol::http::Headers.
- @param bodyStream - pointer to oatpp::data::stream::InputStream.
- @param writeCallback - oatpp::data::stream::WriteCallback.
- @param connection
virtual void decode(const Headers& headers, data::stream::InputStream* bodyStream,
data::stream::WriteCallback* writeCallback,
data::stream::IOStream* connection) const override
# BodyDecoder::decodeAsync
Just transfer everything we have in bodyStream to toStream as-is Curl already did all decoding.
- @param headers - Headers map. oatpp::web::protocol::http::Headers.
- @param bodyStream -
std::shared_ptr
to oatpp::data::stream::InputStream. - @param writeCallback -
std::shared_ptr
to oatpp::data::stream::WriteCallback. - @param connection
- @return - oatpp::async::CoroutineStarter.
virtual oatpp::async::CoroutineStarter decodeAsync(const Headers& headers,
const std::shared_ptr<data::stream::InputStream>& bodyStream,
const std::shared_ptr<data::stream::WriteCallback>& writeCallback,
const std::shared_ptr<data::stream::IOStream>& connection) const override