Skip to main content

Readable

Trait Readable 

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

A trait that various LDK types implement allowing them to 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>(reader: &mut R) -> Result<Self, DecodeError>
where R: Read,

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.

Implementations on Foreign Types§

Source§

impl Readable for Option<Vec<Option<(usize, Signature)>>>

Source§

fn read<R>( reader: &mut R, ) -> Result<Option<Vec<Option<(usize, Signature)>>>, DecodeError>
where R: Read,

Source§

impl Readable for Option<RAAMonitorUpdateBlockingAction>

Source§

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

Source§

impl Readable for Result<SocketAddress, u8>

Source§

impl Readable for ContractDescriptor

Source§

impl Readable for ContractInfo

Source§

impl Readable for PayoutCurvePiece

Source§

impl Readable for NegotiationFields

Source§

impl Readable for OracleInfo

Source§

impl Readable for bool

Source§

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

Source§

impl Readable for i8

Source§

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

Source§

impl Readable for i16

Source§

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

Source§

impl Readable for i32

Source§

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

Source§

impl Readable for i64

Source§

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

Source§

impl Readable for u8

Source§

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

Source§

impl Readable for u16

Source§

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

Source§

impl Readable for u32

Source§

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

Source§

impl Readable for u64

Source§

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

Source§

impl Readable for u128

Source§

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

Source§

impl Readable for ()

Source§

fn read<R>(_r: &mut R) -> Result<(), DecodeError>
where R: Read,

Source§

impl Readable for VecDeque<(Event, Option<EventCompletionAction>)>

Source§

fn read<R>( reader: &mut R, ) -> Result<VecDeque<(Event, Option<EventCompletionAction>)>, DecodeError>
where R: Read,

Source§

impl Readable for String

Source§

impl Readable for Vec<SocketAddress>

Source§

impl Readable for Vec<u8>

Source§

fn read<R>(r: &mut R) -> Result<Vec<u8>, DecodeError>
where R: Read,

Source§

impl Readable for Vec<Witness>

Source§

impl Readable for Vec<ChannelMonitorUpdate>

Source§

impl Readable for Vec<UpdateAddHTLC>

Source§

impl Readable for Vec<BlindedTail>

Source§

impl Readable for Vec<Signature>

Source§

impl Readable for Vec<MonitorUpdateCompletionAction>

Source§

fn read<R>(r: &mut R) -> Result<Vec<MonitorUpdateCompletionAction>, DecodeError>
where R: Read,

Source§

impl Readable for Vec<PaymentClaimDetails>

Source§

fn read<R>(r: &mut R) -> Result<Vec<PaymentClaimDetails>, DecodeError>
where R: Read,

Source§

impl Readable for Duration

This is not exported to bindings users as Durations are simply mapped as ints.

Source§

impl Readable for Amount

Source§

impl Readable for BlockHash

Source§

impl Readable for ChainHash

Source§

impl Readable for ScriptBuf

Source§

impl Readable for OutPoint

Source§

impl Readable for Transaction

Source§

impl Readable for TxOut

Source§

impl Readable for Txid

Source§

fn read<R>(r: &mut R) -> Result<Txid, DecodeError>
where R: Read,

Source§

impl Readable for Witness

Source§

impl Readable for Hmac<Hash>

Source§

impl Readable for Hash

Source§

fn read<R>(r: &mut R) -> Result<Hash, DecodeError>
where R: Read,

Source§

impl Readable for AcceptChannel

Source§

impl Readable for CollaborativeCloseOffer

Source§

impl Readable for OfferChannel

Source§

impl Readable for Reject

Source§

impl Readable for RenewAccept

Source§

impl Readable for RenewConfirm

Source§

impl Readable for RenewFinalize

Source§

impl Readable for RenewOffer

Source§

impl Readable for RenewRevoke

Source§

impl Readable for SettleAccept

Source§

impl Readable for SettleConfirm

Source§

impl Readable for SettleFinalize

Source§

impl Readable for SettleOffer

Source§

impl Readable for SignChannel

Source§

impl Readable for ContractInfoInner

Source§

impl Readable for ContractOutcome

Source§

impl Readable for DisjointContractInfo

Source§

impl Readable for EnumeratedContractDescriptor

Source§

impl Readable for HyperbolaPayoutCurvePiece

Source§

impl Readable for NumericOutcomeContractDescriptor

Source§

impl Readable for PayoutFunction

Source§

impl Readable for PayoutFunctionPiece

Source§

impl Readable for PayoutPoint

Source§

impl Readable for PolynomialPayoutCurvePiece

Source§

impl Readable for RoundingInterval

Source§

impl Readable for RoundingIntervals

Source§

impl Readable for SingleContractInfo

Source§

impl Readable for MultiOracleInfo

Source§

impl Readable for OracleParams

Source§

impl Readable for SingleOracleInfo

Source§

impl Readable for SegmentChunk

Source§

impl Readable for SegmentStart

Source§

impl Readable for BigSize

Source§

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

Source§

impl Readable for AcceptDlc

Source§

impl Readable for CetAdaptorSignature

Source§

impl Readable for CetAdaptorSignatures

Source§

impl Readable for CloseDlc

Source§

impl Readable for DisjointNegotiationFields

Source§

impl Readable for DlcInput

Source§

impl Readable for FundingInput

Source§

impl Readable for FundingSignature

Source§

impl Readable for FundingSignatures

Source§

impl Readable for OfferDlc

Source§

impl Readable for SignDlc

Source§

impl Readable for SingleNegotiationFields

Source§

impl Readable for WitnessElement

Source§

impl Readable for Features<BlindedHopContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<BlindedHopContext>, DecodeError>
where R: Read,

Source§

impl Readable for Features<Bolt11InvoiceContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<Bolt11InvoiceContext>, DecodeError>
where R: Read,

Source§

impl Readable for Features<Bolt12InvoiceContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<Bolt12InvoiceContext>, DecodeError>
where R: Read,

Source§

impl Readable for Features<ChannelContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<ChannelContext>, DecodeError>
where R: Read,

Source§

impl Readable for Features<ChannelTypeContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<ChannelTypeContext>, DecodeError>
where R: Read,

Source§

impl Readable for Features<InitContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<InitContext>, DecodeError>
where R: Read,

Source§

impl Readable for Features<NodeContext>

Source§

fn read<R>(r: &mut R) -> Result<Features<NodeContext>, DecodeError>
where R: Read,

Source§

impl Readable for PaymentHash

Source§

impl Readable for PaymentPreimage

Source§

impl Readable for PaymentSecret

Source§

impl Readable for RouteHint

Source§

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

Source§

impl Readable for RouteHintHop

Source§

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

Source§

impl Readable for RoutingFees

Source§

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

Source§

impl Readable for UntrustedString

Source§

impl Readable for Signature

Source§

impl Readable for PublicKey

Source§

impl Readable for SecretKey

Source§

impl Readable for [u8; 3]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 3], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 4]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 4], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 12]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 12], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 16]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 16], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 32]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 32], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 33]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 33], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 64]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 64], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 66]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 66], DecodeError>
where R: Read,

Source§

impl Readable for [u8; 1300]

Source§

fn read<R>(r: &mut R) -> Result<[u8; 1300], DecodeError>
where R: Read,

Source§

impl Readable for [u16; 8]

Source§

fn read<R>(r: &mut R) -> Result<[u16; 8], DecodeError>
where R: Read,

Source§

impl Readable for [u16; 32]

Source§

fn read<R>(r: &mut R) -> Result<[u16; 32], DecodeError>
where R: Read,

Source§

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

Source§

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

Source§

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

Source§

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

Source§

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

Source§

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

Source§

impl<A, B, C, D, E, F, G> Readable for (A, B, C, D, E, F, G)
where A: Readable, B: Readable, C: Readable, D: Readable, E: Readable, F: Readable, G: Readable,

Source§

impl<K, V> Readable for BTreeMap<K, V>
where K: Readable + Eq + Ord, V: MaybeReadable,

Source§

fn read<R>(r: &mut R) -> Result<BTreeMap<K, V>, DecodeError>
where R: Read,

Source§

impl<K, V> Readable for HashMap<K, V, RandomState>
where K: Readable + Eq + Hash, V: MaybeReadable,

Source§

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

Source§

fn read<R>(r: &mut R) -> Result<Option<T>, DecodeError>
where R: Read,

Source§

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

Source§

fn read<R>(r: &mut R) -> Result<Box<T>, DecodeError>
where R: Read,

Source§

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

Source§

fn read<R>(r: &mut R) -> Result<Mutex<T>, DecodeError>
where R: Read,

Source§

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

Source§

fn read<R>(r: &mut R) -> Result<RwLock<T>, DecodeError>
where R: Read,

Source§

impl<T> Readable for HashSet<T, RandomState>
where T: Readable + Eq + Hash,

Implementors§

Source§

impl Readable for EventDescriptor

Source§

impl Readable for AsyncPaymentsContext

Source§

impl Readable for MessageContext

Source§

impl Readable for OffersContext

Source§

impl Readable for PaymentContext

Source§

impl Readable for FundingInfo

Source§

impl Readable for PaymentPurpose

Source§

impl Readable for ChannelShutdownState

Source§

impl Readable for BlindedFailure

Source§

impl Readable for PendingHTLCRouting

Source§

impl Readable for SocketAddress

Source§

impl Readable for Retry

Source§

impl Readable for NodeAnnouncementInfo

Source§

impl Readable for SpendableOutputDescriptor

Source§

impl Readable for MaxDustHTLCExposure

Source§

impl Readable for OutputSpendStatus

Source§

impl Readable for BlindedMessagePath

Source§

impl Readable for DNSResolverContext

Source§

impl Readable for BlindedPayInfo

Source§

impl Readable for Bolt12OfferContext

Source§

impl Readable for Bolt12RefundContext

Source§

impl Readable for PaymentConstraints

Source§

impl Readable for PaymentRelay

Source§

impl Readable for BlindedHop

Source§

impl Readable for ChannelMonitorUpdate

Source§

impl Readable for HTLCUpdate

Source§

impl Readable for BestBlock

Source§

impl Readable for ClaimId

Source§

impl Readable for lightning::chain::transaction::OutPoint

Source§

impl Readable for ClaimedHTLC

Source§

impl Readable for BuiltCommitmentTransaction

Source§

impl Readable for ChannelPublicKeys

Source§

impl Readable for ChannelTransactionParameters

Source§

impl Readable for CommitmentTransaction

Source§

impl Readable for CounterpartyChannelTransactionParameters

Source§

impl Readable for CounterpartyCommitmentSecrets

Source§

impl Readable for HTLCOutputInCommitment

Source§

impl Readable for HolderCommitmentTransaction

Source§

impl Readable for TxCreationKeys

Source§

impl Readable for DelayedPaymentBasepoint

Source§

impl Readable for DelayedPaymentKey

Source§

impl Readable for HtlcBasepoint

Source§

impl Readable for HtlcKey

Source§

impl Readable for RevocationBasepoint

Source§

impl Readable for RevocationKey

Source§

impl Readable for ChannelCounterparty

Source§

impl Readable for ChannelDetails

Source§

impl Readable for CounterpartyForwardingInfo

Source§

impl Readable for InboundHTLCDetails

Source§

impl Readable for OutboundHTLCDetails

Source§

impl Readable for BlindedForward

Source§

impl Readable for InterceptId

Source§

impl Readable for PaymentId

Source§

impl Readable for PendingHTLCInfo

Source§

impl Readable for PhantomRouteHints

Source§

impl Readable for lightning::ln::msgs::AcceptChannel

Source§

impl Readable for AcceptChannelV2

Source§

impl Readable for AnnouncementSignatures

Source§

impl Readable for ChannelAnnouncement

Source§

impl Readable for ChannelReady

Source§

impl Readable for ChannelReestablish

Source§

impl Readable for ChannelUpdate

Source§

impl Readable for ClosingSigned

Source§

impl Readable for ClosingSignedFeeRange

Source§

impl Readable for CommitmentSigned

Source§

impl Readable for CommitmentSignedBatch

Source§

impl Readable for ErrorMessage

Source§

impl Readable for FinalOnionHopData

Source§

impl Readable for FundingCreated

Source§

impl Readable for FundingSigned

Source§

impl Readable for GossipTimestampFilter

Source§

impl Readable for Init

Source§

impl Readable for NodeAnnouncement

Source§

impl Readable for OnionMessage

Source§

impl Readable for OnionPacket

Source§

impl Readable for OpenChannel

Source§

impl Readable for OpenChannelV2

Source§

impl Readable for Ping

Source§

impl Readable for Pong

Source§

impl Readable for QueryChannelRange

Source§

impl Readable for QueryShortChannelIds

Source§

impl Readable for ReplyChannelRange

Source§

impl Readable for ReplyShortChannelIdsEnd

Source§

impl Readable for RevokeAndACK

Source§

impl Readable for Shutdown

Source§

impl Readable for SpliceAck

Source§

impl Readable for SpliceInit

Source§

impl Readable for SpliceLocked

Source§

impl Readable for Stfu

Source§

impl Readable for TxAbort

Source§

impl Readable for TxAckRbf

Source§

impl Readable for TxAddInput

Source§

impl Readable for TxAddOutput

Source§

impl Readable for TxComplete

Source§

impl Readable for TxInitRbf

Source§

impl Readable for TxRemoveInput

Source§

impl Readable for TxRemoveOutput

Source§

impl Readable for TxSignatures

Source§

impl Readable for UnsignedChannelAnnouncement

Source§

impl Readable for UnsignedChannelUpdate

Source§

impl Readable for UnsignedNodeAnnouncement

Source§

impl Readable for UpdateAddHTLC

Source§

impl Readable for UpdateFailHTLC

Source§

impl Readable for UpdateFailMalformedHTLC

Source§

impl Readable for UpdateFee

Source§

impl Readable for UpdateFulfillHTLC

Source§

impl Readable for WarningMessage

Source§

impl Readable for RecipientOnionFields

Source§

impl Readable for ShutdownScript

Source§

impl Readable for ChannelId

Source§

impl Readable for Bolt12Invoice

Source§

impl Readable for InvoiceError

Source§

impl Readable for InvoiceRequest

Source§

impl Readable for InvoiceRequestFields

Source§

impl Readable for Nonce

Source§

impl Readable for Offer

Source§

impl Readable for OfferId

Source§

impl Readable for Refund

Source§

impl Readable for HeldHtlcAvailable

Source§

impl Readable for ReleaseHeldHtlc

Source§

impl Readable for HumanReadableName

Source§

impl Readable for Responder

Source§

impl Readable for ChannelInfo

Source§

impl Readable for ChannelUpdateInfo

Source§

impl Readable for NodeAlias

Source§

impl Readable for NodeId

Source§

impl Readable for NodeInfo

Source§

impl Readable for BlindedTail

Source§

impl Readable for InFlightHtlcs

Source§

impl Readable for Route

Source§

impl Readable for RouteHop

Source§

impl Readable for RouteParameters

Source§

impl Readable for ChannelDerivationParameters

Source§

impl Readable for DelayedPaymentOutputDescriptor

Source§

impl Readable for HTLCDescriptor

Source§

impl Readable for StaticPaymentOutputDescriptor

Source§

impl Readable for ChannelConfig

Source§

impl Readable for lightning::util::ser::BigSize

Source§

impl Readable for Hostname

Source§

impl Readable for TransactionU16LenLimited

Source§

impl Readable for WithoutLength<String>

Source§

impl Readable for WithoutLength<ScriptBuf>

Source§

impl Readable for WithoutLength<Features<BlindedHopContext>>

Source§

impl Readable for WithoutLength<Features<Bolt12InvoiceContext>>

Source§

impl Readable for WithoutLength<Features<ChannelTypeContext>>

Source§

impl Readable for WithoutLength<Features<InvoiceRequestContext>>

Source§

impl Readable for WithoutLength<Features<OfferContext>>

Source§

impl Readable for WithoutLength<UntrustedString>

Source§

impl Readable for TrackedSpendableOutput

Source§

impl Readable for DigitDecompositionEventDescriptor

Source§

impl Readable for EnumEventDescriptor

Source§

impl Readable for OracleAnnouncement

Source§

impl Readable for OracleAttestation

Source§

impl Readable for OracleEvent

Source§

impl Readable for kormir::Signature

Source§

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

Source§

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