Struct hdk::prelude::VerifySignature[][src]

pub struct VerifySignature {
    pub key: HoloHash<Agent>,
    pub signature: Signature,
    pub data: Vec<u8, Global>,
}

Mirror struct for Sign that includes a signature to verify against a key and data.

Fields

key: HoloHash<Agent>

The public key associated with the private key that should be used to verify the signature.

signature: Signature

The signature being verified.

data: Vec<u8, Global>

The signed data

Implementations

impl VerifySignature[src]

pub fn as_data_ref(&self) -> &[u8]

Notable traits for &'_ [u8]

impl<'_> Read for &'_ [u8]impl<'_> Write for &'_ mut [u8]
[src]

Alias for as_ref for data.

pub fn as_signature_ref(&self) -> &Signature[src]

Alias for as_ref for signature.

pub fn as_key_ref(&self) -> &HoloHash<Agent>[src]

Alias for as_ref for agent key.

pub fn new<D>(
    key: HoloHash<Agent>,
    signature: Signature,
    data: D
) -> Result<VerifySignature, SerializedBytesError> where
    D: Serialize + Debug
[src]

construct a new VerifySignature struct.

pub fn new_raw(
    key: HoloHash<Agent>,
    signature: Signature,
    data: Vec<u8, Global>
) -> VerifySignature
[src]

construct a new Sign struct from raw bytes.

Trait Implementations

impl AsRef<HoloHash<Agent>> for VerifySignature[src]

impl AsRef<Signature> for VerifySignature[src]

impl Clone for VerifySignature[src]

impl Debug for VerifySignature[src]

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

impl PartialEq<VerifySignature> for VerifySignature[src]

impl Serialize for VerifySignature[src]

impl StructuralPartialEq for VerifySignature[src]

impl<'_> TryFrom<&'_ VerifySignature> for SerializedBytes[src]

type Error = SerializedBytesError

The type returned in the event of a conversion error.

impl TryFrom<SerializedBytes> for VerifySignature[src]

type Error = SerializedBytesError

The type returned in the event of a conversion error.

impl TryFrom<VerifySignature> for SerializedBytes[src]

type Error = SerializedBytesError

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> Instrument for T[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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>,