Module bincode::config[][src]

Expand description

The config module is used to change the behavior of bincode’s encoding and decoding logic.

Important make sure you use the same config for encoding and decoding, or else bincode will not work properly.

To use a config, first create a type of Configuration. This type will implement trait Config for use with bincode.

use bincode::config::{Config, Configuration};
let config = Configuration::standard()
    // pick one of:
    .with_big_endian()
    .with_little_endian()
    // pick one of:
    .with_variable_int_encoding()
    .with_fixed_int_encoding()
    // pick one of:
    .skip_fixed_array_length()
    .write_fixed_array_length();

See Config for more information on the configuration options.

Structs

The Configuration struct is used to build bincode configurations. The Config trait is implemented by this struct when a valid configuration has been constructed.

Traits

Indicates a type is valid for controlling the bincode configuration