pub trait CommitmentPointProvider: SendSync {
    // Required methods
    fn get_holder_commitment_point(&self, commitment_number: u64) -> PublicKey;
    fn get_counterparty_commitment_point(
        &self,
        commitment_number: u64
    ) -> Option<PublicKey>;
    fn get_transaction_parameters(&self) -> ChannelTransactionParameters;
    fn clone_box(&self) -> Box<dyn CommitmentPointProvider>;
}
Expand description

A trait for getting a commitment point for a given commitment number, if known.

Required Methods§

source

fn get_holder_commitment_point(&self, commitment_number: u64) -> PublicKey

Get the commitment point for a holder commitment transaction

source

fn get_counterparty_commitment_point( &self, commitment_number: u64 ) -> Option<PublicKey>

Get the commitment point for a counterparty commitment transaction, if known. It might not be known if we didn’t reach that commitment number yet or it’s a revoked commitment transaction and we don’t store revocation secrets.

source

fn get_transaction_parameters(&self) -> ChannelTransactionParameters

Get channel transaction parameters, for decoding on-chain transactions

source

fn clone_box(&self) -> Box<dyn CommitmentPointProvider>

Clone

Trait Implementations§

source§

impl Clone for Box<dyn CommitmentPointProvider>

source§

fn clone(&self) -> Self

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more

Implementors§