pub struct TableWriter { /* private fields */ }
Expand description

An object that manages a collection of serialized tables.

This handles deduplicating objects and tracking offsets.

Implementations§

Write raw bytes into this table.

The caller is responsible for ensuring bytes are in big-endian order.

Create an offset to another table.

The width argument is the size in bytes of the offset, e.g. 2 for an Offset16, and 4 for an Offset32.

The provided table will be serialized immediately, and the position of the offset within the current table will be recorded. Offsets are resolved when the root table object is serialized, at which point we overwrite each recorded offset position with the final offset of the appropriate table.

Trait Implementations§

Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Convert this type into T, using the provided data to resolve any offsets.
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.