BodyInputStream.hpp

This File On Github
Ask A Question

API: latest
module: oatpp-curl
#include "oatpp-curl/io/BodyInputStream.hpp"

BodyInputStream

Wrapper over oatpp::curl::io::CurlBodyReader providing oatpp::data::stream::InputStream interface.

namespace oatpp { namespace curl { namespace io { 
  class BodyInputStream : public oatpp::data::stream::InputStream {}
}}}

Methods

Return Type Name Summary
[none] BodyInputStream Constructor.
data::v_io_size read Read data from stream. Implementation of oatpp::data::stream::InputStream::read() method.
oatpp::async::Action suggestInputStreamAction Implementation of InputStream must suggest async actions for I/O results.
void setInputStreamIOMode Set stream I/O mode.
oatpp::data::stream::IOMode getInputStreamIOMode Get stream I/O mode.

BodyInputStream::BodyInputStream

Constructor.

  • @param reader
  • @param ioMode

BodyInputStream(const std::shared_ptr<CurlBodyReader> reader, oatpp::data::stream::IOMode ioMode)

BodyInputStream::read

Read data from stream. Implementation of oatpp::data::stream::InputStream::read() method.

data::v_io_size read(void *data, data::v_io_size count) override

BodyInputStream::suggestInputStreamAction

Implementation of InputStream must suggest async actions for I/O results. Suggested Action is used for scheduling coroutines in async::Executor.

oatpp::async::Action suggestInputStreamAction(data::v_io_size ioResult) override

BodyInputStream::setInputStreamIOMode

Set stream I/O mode.

  • @throws

void setInputStreamIOMode(oatpp::data::stream::IOMode ioMode) override

BodyInputStream::getInputStreamIOMode

Get stream I/O mode.

  • @return

oatpp::data::stream::IOMode getInputStreamIOMode() override