Classes |
Public Types |
Public Member Functions |
Protected Member Functions |
Protected Attributes |
List of all members
giga::core::FileTransferer Class Referenceabstract
#include <FileTransferer.h>
Inheritance diagram for giga::core::FileTransferer:
Classes | |
struct | Progress |
Public Types | |
enum | State { pending, started, paused, canceled, error } |
Public Member Functions | |
FileTransferer (pplx::cancellation_token_source cts) | |
FileTransferer (FileTransferer &&other) | |
FileTransferer (const FileTransferer &)=delete | |
FileTransferer & | operator= (const FileTransferer &)=delete |
FileTransferer & | operator= (FileTransferer &&)=delete |
void | start () |
Start a transfer. | |
void | pause () |
Pause the current transfer (see resume() ) | |
void | resume () |
Resume the current transfer (see pause() ) | |
void | cancel () |
Cancel a started upload. The task managing the transfer will most probably throw an exception. | |
void | setError (const std::string &error) |
State | state () const |
void | limitRate (uint64_t rate) |
Limit the rate of the transfer. More... | |
virtual FileTransferer::Progress | progress () const =0 |
virtual const boost::filesystem::path & | filename () const =0 |
Protected Member Functions | |
virtual void | doStart ()=0 |
Protected Attributes | |
State | _state |
std::unique_ptr < details::CurlProgress > | _progress |
std::mutex | _mut |
pplx::cancellation_token_source | _cts |
utility::string_t | _error |
Detailed Description
The FileTransferer can be a FileDownload or a FileUpload.
Member Function Documentation
void giga::core::FileTransferer::limitRate | ( | uint64_t | rate | ) |
Limit the rate of the transfer.
- Parameters
-
rate in Byte/s
The documentation for this class was generated from the following files:
- /home/thomas/code/GiGaSdk/src/giga/core/FileTransferer.h
- /home/thomas/code/GiGaSdk/src/giga/core/FileTransferer.cpp