Trait TryFromBytes

Source
pub trait TryFromBytes: Sized {
    // Required method
    fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>;

    // Provided method
    fn try_from_bytes_hex(hex_string: &str) -> StdResult<Self> { ... }
}
Expand description

Traits for deserializing from bytes

Required Methods§

Source

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Try to convert from a bytes slice.

Provided Methods§

Source

fn try_from_bytes_hex(hex_string: &str) -> StdResult<Self>

Try to convert from hex string encoded bytes.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl TryFromBytes for AggregateVerificationKey<Blake2b<U32>>

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for AggregateSignature<Blake2b<U32>>

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for Parameters

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for Initializer

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for SingleSignature

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for SingleSignatureWithRegisteredParty

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for VerificationKeyProofOfPossession

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for VerificationKey

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for Signature

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for SigningKey

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for Sum6KesSig

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Source§

impl TryFromBytes for VerifyingKey

Source§

fn try_from_bytes(bytes: &[u8]) -> StdResult<Self>

Implementors§