Enum bitcoin::util::bip32::ChildNumber [−][src]
A child number for a derived key
Variants
Non-hardened key
Show fields
Fields of Normal
index: u32
Key index, within [0, 2^31 - 1]
Hardened key
Show fields
Fields of Hardened
index: u32
Key index, within [0, 2^31 - 1]
Implementations
impl ChildNumber
[src]
impl ChildNumber
[src]pub fn from_normal_idx(index: u32) -> Result<Self, Error>
[src]
Create a Normal
from an index, returns an error if the index is not within
[0, 2^31 - 1].
pub fn from_hardened_idx(index: u32) -> Result<Self, Error>
[src]
Create a Hardened
from an index, returns an error if the index is not within
[0, 2^31 - 1].
pub fn is_normal(&self) -> bool
[src]
Returns true
if the child number is a Normal
value.
pub fn is_hardened(&self) -> bool
[src]
Returns true
if the child number is a Hardened
value.
pub fn increment(self) -> Result<ChildNumber, Error>
[src]
Returns the child number that is a single increment from this one.
Trait Implementations
impl Clone for ChildNumber
[src]
impl Clone for ChildNumber
[src]fn clone(&self) -> ChildNumber
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<'de> Deserialize<'de> for ChildNumber
[src]
impl<'de> Deserialize<'de> for ChildNumber
[src]fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
impl From<ChildNumber> for u32
[src]
impl From<ChildNumber> for u32
[src]fn from(cnum: ChildNumber) -> Self
[src]
impl FromIterator<ChildNumber> for DerivationPath
[src]
impl FromIterator<ChildNumber> for DerivationPath
[src]fn from_iter<T>(iter: T) -> Self where
T: IntoIterator<Item = ChildNumber>,
[src]
T: IntoIterator<Item = ChildNumber>,
impl FromStr for ChildNumber
[src]
impl FromStr for ChildNumber
[src]impl Hash for ChildNumber
[src]
impl Hash for ChildNumber
[src]impl Ord for ChildNumber
[src]
impl Ord for ChildNumber
[src]impl PartialEq<ChildNumber> for ChildNumber
[src]
impl PartialEq<ChildNumber> for ChildNumber
[src]fn eq(&self, other: &ChildNumber) -> bool
[src]
fn ne(&self, other: &ChildNumber) -> bool
[src]
impl PartialOrd<ChildNumber> for ChildNumber
[src]
impl PartialOrd<ChildNumber> for ChildNumber
[src]impl Serialize for ChildNumber
[src]
impl Serialize for ChildNumber
[src]