Trait MaybeReadable

Source
pub trait MaybeReadable
where Self: Sized,
{ // Required method fn read<R: Read>(reader: &mut R) -> Result<Option<Self>, DecodeError>; }
Expand description

A trait that various LDK types implement allowing them to (maybe) be read in from a Read.

This is not exported to bindings users as we only export serialization to/from byte arrays instead

Required Methods§

Source

fn read<R: Read>(reader: &mut R) -> Result<Option<Self>, DecodeError>

Reads a Self in from the given Read.

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.

Implementors§