[][src]Struct grin_keychain::Identifier

pub struct Identifier(_);

Methods

impl Identifier[src]

pub fn zero() -> Identifier[src]

pub fn from_path(path: &ExtKeychainPath) -> Identifier[src]

pub fn to_path(&self) -> ExtKeychainPath[src]

pub fn to_value_path(&self, value: u64) -> ValueExtKeychainPath[src]

pub fn serialize_path(&self) -> [u8; 16][src]

output the path itself, for insertion into bulletproof recovery processes can grind through possiblities to find the correct length if required

pub fn from_serialized_path(len: u8, p: &[u8]) -> Identifier[src]

restore from a serialized path

pub fn parent_path(&self) -> Identifier[src]

Return the parent path

pub fn from_bytes(bytes: &[u8]) -> Identifier[src]

pub fn to_bytes(&self) -> [u8; 17][src]

pub fn from_pubkey(secp: &Secp256k1, pubkey: &PublicKey) -> Identifier[src]

pub fn from_secret_key(
    secp: &Secp256k1,
    key: &SecretKey
) -> Result<Identifier, Error>
[src]

Return the identifier of the secret key which is the blake2b (10 byte) digest of the PublicKey corresponding to the secret key provided.

pub fn from_hex(hex: &str) -> Result<Identifier, Error>[src]

pub fn to_hex(&self) -> String[src]

pub fn to_bip_32_string(&self) -> String[src]

Trait Implementations

impl PartialOrd<Identifier> for Identifier[src]

impl PartialEq<Identifier> for Identifier[src]

impl AsRef<[u8]> for Identifier[src]

impl Clone for Identifier[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Ord for Identifier[src]

fn max(self, other: Self) -> Self
1.21.0
[src]

Compares and returns the maximum of two values. Read more

fn min(self, other: Self) -> Self
1.21.0
[src]

Compares and returns the minimum of two values. Read more

fn clamp(self, min: Self, max: Self) -> Self[src]

🔬 This is a nightly-only experimental API. (clamp)

Returns max if self is greater than max, and min if self is less than min. Otherwise this will return self. Panics if min > max. Read more

impl Eq for Identifier[src]

impl Display for Identifier[src]

impl Debug for Identifier[src]

impl Hash for Identifier[src]

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0
[src]

Feeds a slice of this type into the given [Hasher]. Read more

impl Serialize for Identifier[src]

impl<'de> Deserialize<'de> for Identifier[src]

Auto Trait Implementations

impl Send for Identifier

impl Sync for Identifier

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T> DebugAny for T where
    T: Any + Debug

impl<T> CloneAny for T where
    T: Clone + Any

impl<T> UnsafeAny for T where
    T: Any

impl<T> Erased for T

impl<T> Same for T

type Output = T

Should always be Self