Struct ordered_varint::Signed
source · pub struct Signed(_);
Expand description
A signed integer value.
This type encodes values in the range -2.pow(123)..2.pow(123)
by using the
first 5 bits to denote a signed byte length
. This length ranges from
-15..=15
. The number of bytes read is always absolute, but the sign of the
length is used to determine the overall sign of the encoded value. The
remaining 3 bits of the first byte and any additional bytes are then
used to store the integer in big-endian encoding.
Trait Implementations§
source§impl Ord for Signed
impl Ord for Signed
source§impl PartialOrd<Signed> for Signed
impl PartialOrd<Signed> for Signed
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read more