roar
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Roar::Curl::Source Class Referenceabstract

Sublass this source class to provide your own Source. A source provides data to upload to servers. More...

#include <source.hpp>

Collaboration diagram for Roar::Curl::Source:

Public Member Functions

virtual std::size_t fetch (char *buffer, std::size_t amount)=0
 
virtual std::size_t size ()=0
 
virtual bool isChunked () const
 
 Source ()=default
 
virtual ~Source ()=default
 
 Source (Source const &)=default
 
 Source (Source &&)=default
 
Sourceoperator= (Source const &)=default
 
Sourceoperator= (Source &&)=default
 

Detailed Description

Sublass this source class to provide your own Source. A source provides data to upload to servers.

Constructor & Destructor Documentation

◆ Source() [1/3]

Roar::Curl::Source::Source ( )
default

◆ ~Source()

virtual Roar::Curl::Source::~Source ( )
virtualdefault

◆ Source() [2/3]

Roar::Curl::Source::Source ( Source const &  )
default

◆ Source() [3/3]

Roar::Curl::Source::Source ( Source &&  )
default

Member Function Documentation

◆ fetch()

virtual std::size_t Roar::Curl::Source::fetch ( char buffer,
std::size_t  amount 
)
pure virtual

This function gets called when the upload requests more data.

Implemented in Roar::Curl::FileSource, and Roar::Curl::StringSource.

◆ isChunked()

virtual bool Roar::Curl::Source::isChunked ( ) const
inlinevirtual

Is chunked encoding?

◆ operator=() [1/2]

Source & Roar::Curl::Source::operator= ( Source &&  )
default

◆ operator=() [2/2]

Source & Roar::Curl::Source::operator= ( Source const &  )
default

◆ size()

virtual std::size_t Roar::Curl::Source::size ( )
pure virtual

Returns the total size to upload. This function is unused if chunked encoding is used.

Implemented in Roar::Curl::FileSource, and Roar::Curl::StringSource.


The documentation for this class was generated from the following file: