|
wowlib 0.0.0
Read & write World of Warcraft client files — a C++26 core
|
An unparsed chunk payload, preserved verbatim for round-trip. More...
#include <wowlib/formats/common/chunked_file.hpp>
Public Member Functions | |
| Result< void > | read (std::span< const std::byte > payload) |
| Replace the payload with payload (the serializer's read hook). | |
| Result< void > | write (FileBuffer &out) const |
| Append the payload to out (the serializer's write hook). | |
| bool | empty () const |
| Whether the payload holds any bytes. | |
| std::size_t | size () const |
| The payload size in bytes. | |
| bool | operator== (const ChunkBlob &) const =default |
Public Attributes | |
| std::vector< std::byte > | bytes |
An unparsed chunk payload, preserved verbatim for round-trip.
Backs chunks wowlib keeps opaque — offset-based (MOTA, MDDL) or undocumented (MPVD, MOMX).
Definition at line 115 of file chunked_file.hpp.
|
inlinenodiscard |
Whether the payload holds any bytes.
Definition at line 136 of file chunked_file.hpp.
References bytes.
|
default |
|
inline |
Replace the payload with payload (the serializer's read hook).
| payload | the chunk payload bytes. |
Definition at line 121 of file chunked_file.hpp.
References bytes.
|
inline |
|
inline |
Append the payload to out (the serializer's write hook).
| out | the destination buffer (appended, not cleared). |
Definition at line 129 of file chunked_file.hpp.
References bytes.
| std::vector<std::byte> wowlib::formats::ChunkBlob::bytes |
Definition at line 116 of file chunked_file.hpp.
Referenced by empty(), read(), size(), write(), and wowlib::formats::m2::detail::Skeleton< V >::write().