Struct monero::util::key::PublicKey[][src]

pub struct PublicKey {
    pub point: CompressedEdwardsY,
}

A public key, a valid edward point on the curve.

Fields

point: CompressedEdwardsY

The actual Ed25519 point.

Implementations

impl PublicKey[src]

pub fn as_bytes(&self) -> &[u8][src]

Serialize a public key as bytes.

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

Serialize a public key to bytes.

pub fn from_slice(data: &[u8]) -> Result<PublicKey, Error>[src]

Deserialize a public key from a slice.

pub fn from_private_key(privkey: &PrivateKey) -> PublicKey[src]

Generate a public key from the private key.

Trait Implementations

impl<'a, 'b> Add<&'b PublicKey> for &'a PublicKey[src]

type Output = PublicKey

The resulting type after applying the + operator.

impl<'b> Add<&'b PublicKey> for PublicKey[src]

type Output = PublicKey

The resulting type after applying the + operator.

impl<'a> Add<PublicKey> for &'a PublicKey[src]

type Output = PublicKey

The resulting type after applying the + operator.

impl Add<PublicKey> for PublicKey[src]

type Output = PublicKey

The resulting type after applying the + operator.

impl Clone for PublicKey[src]

impl Copy for PublicKey[src]

impl Debug for PublicKey[src]

impl Decodable for PublicKey[src]

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

impl Display for PublicKey[src]

impl Encodable for PublicKey[src]

impl Eq for PublicKey[src]

impl FromStr for PublicKey[src]

type Err = Error

The associated error which can be returned from parsing.

impl Hash for PublicKey[src]

impl Hashable for PublicKey[src]

impl Index<RangeFull> for PublicKey[src]

type Output = [u8]

The returned type after indexing.

impl<'b> Mul<&'b PrivateKey> for PublicKey[src]

type Output = PublicKey

The resulting type after applying the * operator.

impl<'b> Mul<&'b PublicKey> for PrivateKey[src]

type Output = PublicKey

The resulting type after applying the * operator.

impl<'a, 'b> Mul<&'b PublicKey> for &'a PrivateKey[src]

type Output = PublicKey

The resulting type after applying the * operator.

impl PartialEq<PublicKey> for PublicKey[src]

impl Serialize for PublicKey[src]

impl StrictDecode for PublicKey[src]

This is supported on crate feature strict_encoding_support only.

impl StrictEncode for PublicKey[src]

This is supported on crate feature strict_encoding_support only.

impl StructuralEq for PublicKey[src]

impl StructuralPartialEq for PublicKey[src]

impl<'a, 'b> Sub<&'b PublicKey> for &'a PublicKey[src]

type Output = PublicKey

The resulting type after applying the - operator.

impl<'b> Sub<&'b PublicKey> for PublicKey[src]

type Output = PublicKey

The resulting type after applying the - operator.

impl<'a> Sub<PublicKey> for &'a PublicKey[src]

type Output = PublicKey

The resulting type after applying the - operator.

impl Sub<PublicKey> for PublicKey[src]

type Output = PublicKey

The resulting type after applying the - operator.

impl TryFrom<&'_ [u8]> for PublicKey[src]

type Error = Error

The type returned in the event of a conversion error.

impl TryFrom<[u8; 32]> for PublicKey[src]

type Error = Error

The type returned in the event of a conversion error.

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> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[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.