read overloads
Declared in <folly/io/coro/Transport.h>
Reads up to buf.size() bytes into buf, waiting at most timeout.
virtual
Task<size_t>
read(
MutableByteRange buf,
std::chrono::milliseconds timeout) override;
» more...
Reads up to buflen bytes into buf, waiting at most timeout.
Task<size_t>
read(
void* buf,
size_t buflen,
std::chrono::milliseconds timeout);
» more...
Reads data into an IOBufQueue, waiting at most timeout.
virtual
Task<size_t>
read(
IOBufQueue& buf,
size_t minReadSize,
size_t newAllocationSize,
std::chrono::milliseconds timeout) override;
» more...
The number of bytes read.
| Name | Description |
|---|---|
| buf | Destination buffer for the read bytes. |
| timeout | Maximum time to wait for data. |
| buflen | Size of the destination buffer. |
| minReadSize | Minimum number of bytes to allocate for the read. |
| newAllocationSize | Size of newly allocated buffers. |