[−][src]Struct hdpath::StandardHDPath
Standard HD Path for BIP-44,
BIP-49, BIP-84
and similar. For path as m/purpose'/coin_type'/account'/change/address_index
, like m/44'/0'/0'/0/0
.
Create new
use hdpath::{StandardHDPath, Purpose}; //creates path m/84'/0'/0'/0/0 let hdpath = StandardHDPath::new(Purpose::Witness, 0, 0, 0, 0);
Parse string
use hdpath::{StandardHDPath, Purpose}; //creates path m/84'/0'/0'/0/0 let hdpath = StandardHDPath::try_from("m/84'/0'/0'/0/0");
Methods
impl StandardHDPath
[src]
pub fn new(
purpose: Purpose,
coin_type: u32,
account: u32,
change: u32,
index: u32
) -> StandardHDPath
[src]
purpose: Purpose,
coin_type: u32,
account: u32,
change: u32,
index: u32
) -> StandardHDPath
pub fn purpose(&self) -> &Purpose
[src]
pub fn coin_type(&self) -> u32
[src]
pub fn account(&self) -> u32
[src]
pub fn change(&self) -> u32
[src]
pub fn index(&self) -> u32
[src]
Trait Implementations
impl Clone for StandardHDPath
[src]
fn clone(&self) -> StandardHDPath
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for StandardHDPath
[src]
impl Default for StandardHDPath
[src]
impl Eq for StandardHDPath
[src]
impl From<StandardHDPath> for CustomHDPath
[src]
fn from(value: StandardHDPath) -> Self
[src]
impl Ord for StandardHDPath
[src]
fn cmp(&self, other: &StandardHDPath) -> Ordering
[src]
#[must_use]fn max(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn min(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<StandardHDPath> for StandardHDPath
[src]
fn eq(&self, other: &StandardHDPath) -> bool
[src]
fn ne(&self, other: &StandardHDPath) -> bool
[src]
impl PartialOrd<StandardHDPath> for StandardHDPath
[src]
fn partial_cmp(&self, other: &StandardHDPath) -> Option<Ordering>
[src]
fn lt(&self, other: &StandardHDPath) -> bool
[src]
fn le(&self, other: &StandardHDPath) -> bool
[src]
fn gt(&self, other: &StandardHDPath) -> bool
[src]
fn ge(&self, other: &StandardHDPath) -> bool
[src]
impl StructuralEq for StandardHDPath
[src]
impl StructuralPartialEq for StandardHDPath
[src]
impl ToString for StandardHDPath
[src]
impl<'_> TryFrom<&'_ str> for StandardHDPath
[src]
type Error = Error
The type returned in the event of a conversion error.
fn try_from(value: &str) -> Result<Self, Self::Error>
[src]
impl TryFrom<CustomHDPath> for StandardHDPath
[src]
Auto Trait Implementations
impl RefUnwindSafe for StandardHDPath
impl Send for StandardHDPath
impl Sync for StandardHDPath
impl Unpin for StandardHDPath
impl UnwindSafe for StandardHDPath
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,