Read some packets, and when do use that data as initial load filter.
More...
|
std::vector< byte * > | blocks |
| Buffer with blocks of allocated memory.
|
|
byte * | buf |
| Buffer we're going to write to/read from.
|
|
byte * | bufe |
| End of the buffer we write to/read from.
|
|
byte ** | block |
| The block we're reading from/writing to.
|
|
size_t | written_bytes |
| The total number of bytes we've written.
|
|
size_t | read_bytes |
| The total number of read bytes.
|
|
LoadFilter * | chain |
| Chained to the (savegame) filters. More...
|
|
|
static const size_t | CHUNK = 32 * 1024 |
| 32 KiB chunks of memory.
|
|
Read some packets, and when do use that data as initial load filter.
Definition at line 40 of file network_client.cpp.
◆ PacketReader()
PacketReader::PacketReader |
( |
| ) |
|
|
inline |
◆ AddPacket()
void PacketReader::AddPacket |
( |
const Packet * |
p | ) |
|
|
inline |
◆ Read()
size_t PacketReader::Read |
( |
byte * |
buf, |
|
|
size_t |
len |
|
) |
| |
|
inlineoverridevirtual |
Read a given number of bytes from the savegame.
- Parameters
-
buf | The bytes to read. |
len | The number of bytes to read. |
- Returns
- The number of actually read bytes.
Implements LoadFilter.
Definition at line 93 of file network_client.cpp.
References CHUNK, and min().
The documentation for this struct was generated from the following file: