feisty meow concerns codebase  2.140
object_packers.h File Reference
Include dependency graph for object_packers.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 structures
 A dynamic container class that holds any kind of object via pointers.
 

Functions

void structures::attach (basis::byte_array &packed_form, bool to_attach)
 Packs a bool "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, bool &to_detach)
 Unpacks a bool "to_detach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, basis::abyte to_attach)
 Packs a byte "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, basis::abyte &to_detach)
 Unpacks a byte "to_detach" from "packed_form". More...
 
int structures::packed_size (const basis::byte_array &packed_form)
 Reports the size required to pack a byte array into a byte array. More...
 
void structures::attach (basis::byte_array &packed_form, const basis::byte_array &to_attach)
 Packs a byte_array "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, basis::byte_array &to_detach)
 Unpacks a byte_array "to_detach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, char to_attach)
 Packs a char "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, char &to_detach)
 Unpacks a char "to_detach" from "packed_form". More...
 
int structures::packed_size (double to_pack)
 Reports how large the "to_pack" will be as a stream of bytes. More...
 
void structures::attach (basis::byte_array &packed_form, double to_pack)
 Packs a double precision floating point "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, double &to_unpack)
 Unpacks a double precision floating point "to_attach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, float to_pack)
 Packs a floating point "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, float &to_unpack)
 Unpacks a floating point "to_attach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, int to_attach)
 Packs an integer "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, int &to_detach)
 Unpacks an integer "to_attach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, long int to_attach)
 Packs an integer "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, long int &to_detach)
 Unpacks an integer "to_attach" from "packed_form". More...
 
void structures::obscure_attach (basis::byte_array &packed_form, basis::un_int to_attach)
 like the normal attach but shifts in some recognizable sentinel data. More...
 
bool structures::obscure_detach (basis::byte_array &packed_form, basis::un_int &to_detach)
 shifts the number back and checks validity, false returned if corrupted. More...
 
void structures::attach (basis::byte_array &packed_form, short to_attach)
 Packs a short integer "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, short &to_detach)
 Unpacks a short integer "to_attach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, basis::un_int to_attach)
 Packs an unsigned integer "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, basis::un_int &to_detach)
 Unpacks an unsigned integer "to_attach" from "packed_form". More...
 
void structures::attach (basis::byte_array &packed_form, basis::un_short to_attach)
 Packs an unsigned short integer "to_attach" into "packed_form". More...
 
bool structures::detach (basis::byte_array &packed_form, basis::un_short &to_detach)
 Unpacks an unsigned short integer "to_attach" from "packed_form". More...
 
template<class contents >
void structures::pack_array (basis::byte_array &packed_form, const basis::array< contents > &to_pack)
 provides a way to pack any array that stores packable objects. More...
 
template<class contents >
bool structures::unpack_array (basis::byte_array &packed_form, basis::array< contents > &to_unpack)
 provides a way to unpack any array that stores packable objects. More...
 
template<class contents >
int structures::packed_size_array (const basis::array< contents > &to_pack)
 provides space estimation for the objects to be packed. More...
 
template<class contents >
void structures::pack_simple (basis::byte_array &packed_form, const basis::array< contents > &to_pack)
 Packs flat objects into an array of bytes. More...
 
template<class contents >
bool structures::unpack_simple (basis::byte_array &packed_form, basis::array< contents > &to_unpack)
 Unpacks flat objects from an array of bytes. More...
 

Variables

const int structures::PACKED_SIZE_BYTE = 1
 
const int structures::PACKED_SIZE_INT16 = 2
 
const int structures::PACKED_SIZE_INT32 = 4
 
const int structures::PACKED_SIZE_INT64 = 8