|
|
| TransferSource (curlFileTransfer &parent, const std::string &uri, const Headers &headers, std::optional< std::string > data, bool noBody) |
| |
|
auto | withRetries (auto &&initial, auto &&retry) -> decltype(initial()) |
| |
|
FileTransferResultWithEncoding | startTransfer (const std::string &uri, curl_off_t offset=0) |
| |
|
void | throwChangedTarget (std::string_view what, std::string_view from, std::string_view to) |
| |
|
void | prepareRetry (const std::string &context) |
| |
|
void | restartTransfer () |
| |
|
bool | awaitData () |
| |
| size_t | read (char *data, size_t len) override |
| |
| void | operator() (char *data, size_t len) |
| |
|
virtual bool | good () |
| |
|
void | drainInto (Sink &sink) |
| |
|
std::string | drain () |
| |
|
|
curlFileTransfer & | parent |
| |
|
std::string | uri |
| |
|
Headers | headers |
| |
|
std::optional< std::string > | data |
| |
|
bool | noBody |
| |
|
ActivityId | parentAct = getCurActivity() |
| |
|
std::shared_ptr< TransferItem > | transfer |
| |
|
FileTransferResultWithEncoding | metadata |
| |
|
std::string | chunk |
| |
|
std::string_view | buffered |
| |
|
unsigned int | attempt = 0 |
| |
|
const size_t | tries = fileTransferSettings.tries |
| |
|
curl_off_t | totalReceived = 0 |
| |
◆ read()
| size_t nix::curlFileTransfer::TransferSource::read |
( |
char * | data, |
|
|
size_t | len ) |
|
inlineoverridevirtual |
Store up to ‘len’ in the buffer pointed to by ‘data’, and return the number of bytes stored. It blocks until at least one byte is available.
Should not return 0 (generally you want to throw EndOfFile), but nothing stops that.
- Exceptions
-
| EndOfFile | if there is no more data. |
Implements nix::Source.
The documentation for this struct was generated from the following file:
- lix/libstore/filetransfer.cc