pub struct FlattenedLength(pub u32);Expand description
Represents the total number of fields required to represent the entirety of an array or vector.
For example in the array [(u8, u16, [u32; 4]); 8] the flattened length is 48: 8 * (1 + 1 + 4).
Tuple Fields§
§0: u32Implementations§
Trait Implementations§
Source§impl Add for FlattenedLength
impl Add for FlattenedLength
Source§impl AddAssign for FlattenedLength
impl AddAssign for FlattenedLength
Source§fn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
Performs the
+= operation. Read moreSource§impl Clone for FlattenedLength
impl Clone for FlattenedLength
Source§fn clone(&self) -> FlattenedLength
fn clone(&self) -> FlattenedLength
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FlattenedLength
impl Debug for FlattenedLength
Source§impl<'de> Deserialize<'de> for FlattenedLength
impl<'de> Deserialize<'de> for FlattenedLength
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for FlattenedLength
impl Display for FlattenedLength
Source§impl Div<ElementsFlattenedLength> for FlattenedLength
impl Div<ElementsFlattenedLength> for FlattenedLength
Source§type Output = SemanticLength
type Output = SemanticLength
The resulting type after applying the
/ operator.Source§impl From<FlattenedLength> for ElementsFlattenedLength
impl From<FlattenedLength> for ElementsFlattenedLength
Source§fn from(flattened_length: FlattenedLength) -> Self
fn from(flattened_length: FlattenedLength) -> Self
Assumes this flattened length represents a single entry in an array or vector,
Source§impl Hash for FlattenedLength
impl Hash for FlattenedLength
Source§impl Ord for FlattenedLength
impl Ord for FlattenedLength
Source§fn cmp(&self, other: &FlattenedLength) -> Ordering
fn cmp(&self, other: &FlattenedLength) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for FlattenedLength
impl PartialEq for FlattenedLength
Source§impl PartialOrd for FlattenedLength
impl PartialOrd for FlattenedLength
Source§impl Serialize for FlattenedLength
impl Serialize for FlattenedLength
Source§impl Sum for FlattenedLength
impl Sum for FlattenedLength
impl Copy for FlattenedLength
impl Eq for FlattenedLength
impl StructuralPartialEq for FlattenedLength
Auto Trait Implementations§
impl Freeze for FlattenedLength
impl RefUnwindSafe for FlattenedLength
impl Send for FlattenedLength
impl Sync for FlattenedLength
impl Unpin for FlattenedLength
impl UnwindSafe for FlattenedLength
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more