|
| Chunk (const Offset &o, std::array< Byte, SmallBufferSize > d, const Size &n) |
|
| Chunk (const Offset &o, Vector &&d) |
|
| Chunk (const Offset &o, const View &d) |
|
| Chunk (const Offset &o, const std::string &s) |
|
template<int N> |
| Chunk (Offset o, std::array< Byte, N > d) |
|
| Chunk (const Offset &o, const char *d, const Size &n) |
|
| Chunk (const Offset &o, size_t len) |
|
| Chunk (const Chunk &other) |
|
| Chunk (Chunk &&other) noexcept |
|
Chunk & | operator= (const Chunk &other)=delete |
|
Chunk & | operator= (Chunk &&other) noexcept |
|
Offset | offset () const |
|
Offset | endOffset () const |
|
bool | isGap () const |
|
bool | inRange (const Offset &offset) const |
|
const Byte * | data () const |
|
const Byte * | data (const Offset &offset) const |
|
const Byte * | endData () const |
|
Size | size () const |
|
bool | isLast () const |
|
const Chunk * | next () const |
|
auto | last () const |
|
auto | last () |
|
void | debugPrint (std::ostream &out) const |
|
Represents one block of continuous data inside a stream instance. A stream's Chain links multiple of these chunks to represent all of its content.
A chunk internally employs small-buffer optimization for very small amounts of data, storing it directly inside the instance instead of using heap-allocated memory.
All public methods of Chunk are constant. Modifications can be done only be through the owning Chain (so that we can track changes there).