breez_sdk_liquid::lightning::ln::peer_handler

Trait APeerManager

pub trait APeerManager {
Show 14 associated items type Descriptor: SocketDescriptor; type CMT: ChannelMessageHandler + ?Sized; type CM: Deref<Target = Self::CMT>; type RMT: RoutingMessageHandler + ?Sized; type RM: Deref<Target = Self::RMT>; type OMT: OnionMessageHandler + ?Sized; type OM: Deref<Target = Self::OMT>; type LT: Logger + ?Sized; type L: Deref<Target = Self::LT>; type CMHT: CustomMessageHandler + ?Sized; type CMH: Deref<Target = Self::CMHT>; type NST: NodeSigner + ?Sized; type NS: Deref<Target = Self::NST>; // Required method fn as_ref( &self, ) -> &PeerManager<Self::Descriptor, Self::CM, Self::RM, Self::OM, Self::L, Self::CMH, Self::NS>;
}
Expand description

A generic trait which is implemented for all PeerManagers. This makes bounding functions or structs on any PeerManager much simpler as only this trait is needed as a bound, rather than the full set of bounds on PeerManager itself.

This is not exported to bindings users as general cover traits aren’t useful in other languages.

Required Associated Types§

type Descriptor: SocketDescriptor

type CMT: ChannelMessageHandler + ?Sized

type CM: Deref<Target = Self::CMT>

type RMT: RoutingMessageHandler + ?Sized

type RM: Deref<Target = Self::RMT>

type OMT: OnionMessageHandler + ?Sized

type OM: Deref<Target = Self::OMT>

type LT: Logger + ?Sized

type L: Deref<Target = Self::LT>

type CMHT: CustomMessageHandler + ?Sized

type CMH: Deref<Target = Self::CMHT>

type NST: NodeSigner + ?Sized

type NS: Deref<Target = Self::NST>

Required Methods§

fn as_ref( &self, ) -> &PeerManager<Self::Descriptor, Self::CM, Self::RM, Self::OM, Self::L, Self::CMH, Self::NS>

Gets a reference to the underlying PeerManager.

Implementors§

§

impl<Descriptor, CM, RM, OM, L, CMH, NS> APeerManager for PeerManager<Descriptor, CM, RM, OM, L, CMH, NS>

§

type Descriptor = Descriptor

§

type CMT = <CM as Deref>::Target

§

type CM = CM

§

type RMT = <RM as Deref>::Target

§

type RM = RM

§

type OMT = <OM as Deref>::Target

§

type OM = OM

§

type LT = <L as Deref>::Target

§

type L = L

§

type CMHT = <CMH as Deref>::Target

§

type CMH = CMH

§

type NST = <NS as Deref>::Target

§

type NS = NS