Defined in:Represents an output serialization stream.
||Writes arbitrary data to the output stream.|
||Writes an array of objects to the output stream.|
||Begins measuring the size of a section of the output stream.|
||Ends measuring the size of a section of the output stream.|
||Writes a chunk type and begins measuring the size of a chunk in the output stream.|
||Ends measuring the size of a chunk in the output stream.|
||A pointer to the package that receives the packed data.|
Packerobject is passed to the
Packable::Packfunction when the engine needs to serialize data stored in an object. The
Packerobject encapsulates an output serialization stream, and the
<<operator is typically used to write data to it.
||Writes the data given by the |
||Writes the boolean value given by the |
||Writes the string given by the |
DescriptionIn order to maintain four-byte alignment,
int16types should not be serialized directly with the
<<operator. Instead, such values should first be copied or cast to a 32-bit type.
booltype can safely be serialized directly because it is given special handling by the
<<operator that forces it to always occupy four bytes.
machinetype should never be serialized directly because it can be a different size on different platforms, and this difference can appear between 32-bit and 64-bit versions of the same operating system.