Home | All Classes | Grouped Classes | Index | Search

Class CL_NetVariables

Easy serialization of a data structure. More...

Derived from: none
Derived by: none
Group: Network (NetObjects)

#include <ClanLib/network.h>

Construction:

CL_NetVariables

Construct a netvariables object.

Attributes:

is_different

Returns true if the variables have changed since last save.

Operations:

add_bool

Add booleans to the data structure.

add_int

Add integers to the data structure.

add_short

Add shorts to the data structure.

add_float

Add floats to the data structure.

add_double

Add doubles to the data structure.

add_vars

Add structures to the data structure.

save_all

Write all variables in the data structure to the output source.

load_all

Read all variables in the data structure from the input source.

save_diff

Write all variables that have changed since last save.

load_diff

Read a diff produced with save_diff from the input source.

Implementation:

impl

Detailed description:

!group=Network/NetObjects! !header=network.h!

The netvariables class is used to read a set of variables from an object, and write them structured, in network byte order, to an output source.

The Netvariables interface can also read the data again, and produce 'diff' packages where it only write variables that have changed since last write.



Questions or comments, write to the
ClanLib mailing list.