Struct BufferState#
Defined in File BufferState.h
Struct Documentation#
-
struct BufferState#
-
Public Functions
-
auto operator<=>(const BufferState&) const = default#
-
template<std::endian endianness = default_endian>
inline void endian(void)# Handle swapping bytes for endian conversion (native).
- Template Parameters:
endianness – Byte order for encoding elements.
-
template<std::endian endianness = default_endian>
inline void endian(void) Handle swapping bytes for endian conversion (swap required).
- Template Parameters:
endianness – Byte order for encoding elements.
-
template<std::endian endianness = default_endian>
inline std::size_t encode(Buffer *buffer) const# Encode this instance to a buffer.
- Template Parameters:
endianness – Byte order for encoding elements.
- Parameters:
buffer – [out] Buffer to write.
- Returns:
The number of bytes encoded.
-
template<std::endian endianness = default_endian>
inline std::size_t decode(const Buffer *buffer)# Update this instance from a buffer.
- Template Parameters:
endianness – Byte order from decoding elements.
- Parameters:
buffer – [in] Buffer to read.
- Returns:
The number of bytes decoded.
Public Members
-
uint32_t write_cursor#
-
uint32_t read_cursor#
-
uint32_t read_count#
-
uint32_t write_count#
Public Static Attributes
-
static constexpr struct_id_t id = 1#
BufferState’s identifier.
-
static constexpr std::size_t size = 16#
BufferState’s size in bytes.
-
auto operator<=>(const BufferState&) const = default#