pub struct SplitDepth(/* private fields */);Expand description
Account split depth. Fixed-length 5-bit integer of range 1..=30
Implementations§
Source§impl SplitDepth
impl SplitDepth
Sourcepub const fn new(value: u8) -> Result<Self, Error>
pub const fn new(value: u8) -> Result<Self, Error>
Creates a new integer value from a primitive integer.
Sourcepub const fn from_bit_len(bit_len: u16) -> Result<Self, Error>
pub const fn from_bit_len(bit_len: u16) -> Result<Self, Error>
Creates a new integer value from bit len.
Sourcepub const fn into_bit_len(self) -> u16
pub const fn into_bit_len(self) -> u16
Converts split depths into the number of bits.
Trait Implementations§
Source§impl Clone for SplitDepth
impl Clone for SplitDepth
Source§fn clone(&self) -> SplitDepth
fn clone(&self) -> SplitDepth
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SplitDepth
impl Debug for SplitDepth
Source§impl<'de> Deserialize<'de> for SplitDepth
impl<'de> Deserialize<'de> for SplitDepth
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 ExactSize for SplitDepth
impl ExactSize for SplitDepth
Source§fn exact_size(&self) -> Size
fn exact_size(&self) -> Size
Exact size of the value when it is stored in a slice.
Source§impl From<SplitDepth> for BigInt
impl From<SplitDepth> for BigInt
Source§fn from(value: SplitDepth) -> Self
fn from(value: SplitDepth) -> Self
Converts to this type from the input type.
Source§impl From<SplitDepth> for BigUint
impl From<SplitDepth> for BigUint
Source§fn from(value: SplitDepth) -> Self
fn from(value: SplitDepth) -> Self
Converts to this type from the input type.
Source§impl Hash for SplitDepth
impl Hash for SplitDepth
Source§impl IntoAbi for SplitDepth
impl IntoAbi for SplitDepth
Source§impl IntoPlainAbi for SplitDepth
impl IntoPlainAbi for SplitDepth
Source§fn as_plain_abi(&self) -> PlainAbiValue
fn as_plain_abi(&self) -> PlainAbiValue
Returns a corresponding plain ABI value. Read more
Source§fn into_plain_abi(self) -> PlainAbiValuewhere
Self: Sized,
fn into_plain_abi(self) -> PlainAbiValuewhere
Self: Sized,
Converts into a corresponding plain ABI value.
Source§impl<'a> Load<'a> for SplitDepth
impl<'a> Load<'a> for SplitDepth
Source§impl Ord for SplitDepth
impl Ord for SplitDepth
Source§fn cmp(&self, other: &SplitDepth) -> Ordering
fn cmp(&self, other: &SplitDepth) -> 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 SplitDepth
impl PartialEq for SplitDepth
Source§impl PartialOrd for SplitDepth
impl PartialOrd for SplitDepth
Source§impl Serialize for SplitDepth
impl Serialize for SplitDepth
Source§impl Store for SplitDepth
impl Store for SplitDepth
Source§fn store_into(
&self,
builder: &mut CellBuilder,
_: &dyn CellContext,
) -> Result<(), Error>
fn store_into( &self, builder: &mut CellBuilder, _: &dyn CellContext, ) -> Result<(), Error>
Tries to store itself into the cell builder.
Source§impl WithAbiType for SplitDepth
impl WithAbiType for SplitDepth
Source§impl WithPlainAbiType for SplitDepth
impl WithPlainAbiType for SplitDepth
Source§fn plain_abi_type() -> PlainAbiType
fn plain_abi_type() -> PlainAbiType
Returns a corresponding plain ABI type.
impl Copy for SplitDepth
impl Eq for SplitDepth
impl StructuralPartialEq for SplitDepth
Auto Trait Implementations§
impl Freeze for SplitDepth
impl RefUnwindSafe for SplitDepth
impl Send for SplitDepth
impl Sync for SplitDepth
impl Unpin for SplitDepth
impl UnwindSafe for SplitDepth
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,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compares
self to key and returns true if they are equal.