[][src]Struct wagyu_zcash::address::ZcashAddress

pub struct ZcashAddress<N: ZcashNetwork> { /* fields omitted */ }

Represents a Zcash address

Methods

impl<N: ZcashNetwork> ZcashAddress<N>[src]

pub fn p2pkh(public_key: &P2PKHViewingKey) -> Self[src]

Returns a transparent address from a given Zcash public key.

pub fn p2sh() -> Self[src]

Returns a P2SH address.

pub fn sprout(public_key: &SproutViewingKey) -> Result<Self, AddressError>[src]

Returns a shielded address from a given Zcash public key.

pub fn sapling(
    public_key: &SaplingFullViewingKey<N>,
    format: &ZcashFormat
) -> Result<Self, AddressError>
[src]

Returns a shielded address from a given Zcash public key.

pub fn to_diversifier(&self) -> Option<String>[src]

Returns the diversifier of a Zcash Sapling address.

pub fn get_diversifier(address: &str) -> Result<[u8; 11], AddressError>[src]

Returns the diversifier of a specified Zcash Sapling address.

pub fn to_diversified_transmission_key(&self) -> Result<[u8; 32], AddressError>[src]

Returns the diversified transmission key of the Zcash Sapling address.

pub fn format(&self) -> ZcashFormat[src]

Returns the format of the Zcash address.

Trait Implementations

impl<N: ZcashNetwork> Address for ZcashAddress<N>[src]

type Format = ZcashFormat

type PrivateKey = ZcashPrivateKey<N>

type PublicKey = ZcashPublicKey<N>

fn from_private_key(
    private_key: &Self::PrivateKey,
    format: &Self::Format
) -> Result<Self, AddressError>
[src]

Returns the address corresponding to the given Zcash private key.

fn from_public_key(
    public_key: &Self::PublicKey,
    format: &Self::Format
) -> Result<Self, AddressError>
[src]

Returns the address corresponding to the given Zcash public key.

impl<N: Clone + ZcashNetwork> Clone for ZcashAddress<N>[src]

impl<N: Debug + ZcashNetwork> Debug for ZcashAddress<N>[src]

impl<N: ZcashNetwork> Display for ZcashAddress<N>[src]

impl<N: Eq + ZcashNetwork> Eq for ZcashAddress<N>[src]

impl<N: ZcashNetwork> FromStr for ZcashAddress<N>[src]

type Err = AddressError

The associated error which can be returned from parsing.

impl<N: Hash + ZcashNetwork> Hash for ZcashAddress<N>[src]

impl<N: Ord + ZcashNetwork> Ord for ZcashAddress<N>[src]

impl<N: PartialEq + ZcashNetwork> PartialEq<ZcashAddress<N>> for ZcashAddress<N>[src]

impl<N: PartialOrd + ZcashNetwork> PartialOrd<ZcashAddress<N>> for ZcashAddress<N>[src]

impl<N: ZcashNetwork> StructuralEq for ZcashAddress<N>[src]

impl<N: ZcashNetwork> StructuralPartialEq for ZcashAddress<N>[src]

impl<'a, N: ZcashNetwork> TryFrom<&'a str> for ZcashAddress<N>[src]

type Error = AddressError

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<N> RefUnwindSafe for ZcashAddress<N> where
    N: RefUnwindSafe

impl<N> Send for ZcashAddress<N>

impl<N> Sync for ZcashAddress<N>

impl<N> Unpin for ZcashAddress<N> where
    N: Unpin

impl<N> UnwindSafe for ZcashAddress<N> where
    N: UnwindSafe

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

impl<T> Same<T> for T

type Output = T

Should always be Self

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

type Owned = T

The resulting type after obtaining ownership.

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

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

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> 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<V, T> VZip<V> for T where
    V: MultiLane<T>,