pub trait Readablewhere
    Self: Sized,{
    // Required method
    fn read(reader: &mut dyn Reader) -> Result<Self, Error>;
}
Expand description

Trait that every type that can be deserialized from binary must implement. Reads directly to a Reader, a utility type thinly wrapping an underlying Read implementation.

Required Methods§

source

fn read(reader: &mut dyn Reader) -> Result<Self, Error>

Reads the data necessary to this Readable from the provided reader

Implementations on Foreign Types§

source§

impl Readable for u16

source§

fn read(reader: &mut dyn Reader) -> Result<u16, Error>

source§

impl<T> Readable for Vec<T>where T: Readable,

source§

fn read(reader: &mut dyn Reader) -> Result<Vec<T>, Error>

source§

impl Readable for i64

source§

fn read(reader: &mut dyn Reader) -> Result<i64, Error>

source§

impl Readable for RangeProof

source§

fn read(reader: &mut dyn Reader) -> Result<RangeProof, Error>

source§

impl Readable for Identifier

source§

fn read(reader: &mut dyn Reader) -> Result<Identifier, Error>

source§

impl Readable for BlindingFactor

source§

fn read(reader: &mut dyn Reader) -> Result<BlindingFactor, Error>

source§

impl Readable for Signature

source§

fn read(reader: &mut dyn Reader) -> Result<Signature, Error>

source§

impl Readable for u64

source§

fn read(reader: &mut dyn Reader) -> Result<u64, Error>

source§

impl<A: Readable, B: Readable, C: Readable> Readable for (A, B, C)

source§

fn read(reader: &mut dyn Reader) -> Result<(A, B, C), Error>

source§

impl<A: Readable, B: Readable, C: Readable, D: Readable> Readable for (A, B, C, D)

source§

fn read(reader: &mut dyn Reader) -> Result<(A, B, C, D), Error>

source§

impl Readable for u8

source§

fn read(reader: &mut dyn Reader) -> Result<u8, Error>

source§

impl Readable for PublicKey

source§

fn read(reader: &mut dyn Reader) -> Result<Self, Error>

source§

impl Readable for Commitment

source§

fn read(reader: &mut dyn Reader) -> Result<Commitment, Error>

source§

impl Readable for i32

source§

fn read(reader: &mut dyn Reader) -> Result<i32, Error>

source§

impl Readable for u32

source§

fn read(reader: &mut dyn Reader) -> Result<u32, Error>

source§

impl<A: Readable, B: Readable> Readable for (A, B)

source§

fn read(reader: &mut dyn Reader) -> Result<(A, B), Error>

Implementors§

source§

impl Readable for KernelFeatures

source§

impl Readable for OutputFeatures

source§

impl Readable for Proof

source§

impl Readable for Block

Implementation of Readable for a block, defines how to read a full block from a binary stream.

source§

impl Readable for BlockHeader

Deserialization of a block header

source§

impl Readable for HeaderEntry

source§

impl Readable for HeaderVersion

source§

impl Readable for UntrustedBlock

Deserialization of an untrusted block header

source§

impl Readable for UntrustedBlockHeader

Deserialization of an untrusted block header

source§

impl Readable for BlockSums

source§

impl Readable for CompactBlock

Implementation of Readable for a compact block, defines how to read a compact block from a binary stream.

source§

impl Readable for CompactBlockBody

source§

impl Readable for UntrustedCompactBlock

Implementation of Readable for an untrusted compact block, defines how to read a compact block from a binary stream.

source§

impl Readable for Hash

source§

impl Readable for ShortId

source§

impl Readable for MerkleProof

source§

impl Readable for Input

Implementation of Readable for a transaction Input, defines how to read an Input from a binary stream.

source§

impl Readable for Output

Implementation of Readable for a transaction Output, defines how to read an Output from a binary stream.

source§

impl Readable for OutputIdentifier

source§

impl Readable for Transaction

Implementation of Readable for a transaction, defines how to read a full transaction from a binary stream.

source§

impl Readable for TransactionBody

Implementation of Readable for a body, defines how to read a body from a binary stream.

source§

impl Readable for TxKernel

source§

impl Readable for Difficulty

source§

impl Readable for ProofOfWork

source§

impl Readable for ProtocolVersion

source§

impl Readable for Policy