[][src]Crate elrond_codec

Modules

test_util

Enums

DecodeError
EncodeError

Traits

Decode

Trait that allows zero-copy read of value-references from slices in LE format.

Encode

Trait that allows zero-copy write of value-references to slices in LE format.

Input

Trait that allows reading of data into a slice.

Output

Trait that allows writing of data.

Functions

bytes_to_number

Handles both signed and unsigned of any length. No generics here, because we want the executable binary as small as possible.

decode_from_byte_slice

Convenience method, to avoid having to specify type when calling top_decode. Especially useful in the macros.

using_encoded_number

Adds number to output buffer. No argument generics here, because we want the executable binary as small as possible. Smaller types need to be converted to u64 before using this function. TODO: there might be a quicker version of this using transmute + reverse bytes.