[][src]Struct grin_wallet_libwallet::SlatepackAddress

pub struct SlatepackAddress {
    pub hrp: String,
    pub pub_key: edDalekPublicKey,
}

Definition of a Slatepack address

Fields

hrp: String

Human-readable prefix

pub_key: edDalekPublicKey

ed25519 Public key, to be bech32 encoded, interpreted as tor address or converted to an X25519 public key for encrypting slatepacks

Implementations

impl SlatepackAddress[src]

pub fn new(pub_key: &edDalekPublicKey) -> Self[src]

new with default hrp

pub fn random() -> Self[src]

new with a random key

pub fn encoded_len(&self) -> Result<usize, Error>[src]

calculate encoded length

Trait Implementations

impl Clone for SlatepackAddress[src]

impl Debug for SlatepackAddress[src]

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

Deserialize from a bech32 string

impl Display for SlatepackAddress[src]

impl Eq for SlatepackAddress[src]

impl PartialEq<SlatepackAddress> for SlatepackAddress[src]

impl Readable for SlatepackAddress[src]

impl Serialize for SlatepackAddress[src]

Serializes a SlatepackAddress to a bech32 string

impl StructuralEq for SlatepackAddress[src]

impl StructuralPartialEq for SlatepackAddress[src]

impl TryFrom<&'_ SecretKey> for SlatepackAddress[src]

type Error = Error

The type returned in the event of a conversion error.

impl TryFrom<&'_ str> for SlatepackAddress[src]

type Error = Error

The type returned in the event of a conversion error.

impl TryFrom<OnionV3Address> for SlatepackAddress[src]

type Error = Error

The type returned in the event of a conversion error.

impl Writeable for SlatepackAddress[src]

write binary trait

Auto Trait Implementations

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> CloneAny for T where
    T: Clone + Any

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

impl<'a, T> DefaultFeatures<'a> for T where
    T: 'a + Clone + Send + Sync

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

impl<Q, K> Equivalent<K> for Q where
    K: Borrow<Q> + ?Sized,
    Q: Eq + ?Sized
[src]

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

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

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

impl<'a, T> NonSyncFeatures<'a> for T where
    T: 'a + Clone

impl<T> SafeBorrow<T> for T where
    T: ?Sized

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<T> UnsafeAny for T where
    T: Any

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,