Crate scale_bits
source · [−]Expand description
This crate provides the Bits
type; a drop-in, SCALE-compatible replacement for
BitVec<u8, Lsb0>
which can also be encoded-to and decoded-from various store and
order types at runtime (Lsb0
and Msb0
orderings, and u8
, u16
and u32
store
types), allowing for dynamic encoding and decoding based on scale-info
metadata.
Modules
Ths module allows Bits
to be dynamically encoded and decoded into/from a given
Format
. The Format
can either be provided manually, or extracted from
scale_info
type information.
Macros
Structs
This represents a sequence of boolean values, packed into bits.
Returned from calling into_iter
on Bits
via the
std::iter::IntoIterator
trait. Allows iteration over
each stored bit.
Returned from calling Bits::iter()
. Allows iteration
over each stored bit.