pub struct BridgeEventDelegate<I, A, PD, D = VoidDelegate<I, A>>where
I: Id + IdCodec + Clone + Ord + Send + Sync + 'static,
A: CheapClone + Send + Sync + 'static,
PD: PlumtreeDelegate<I>,{ /* private fields */ }Expand description
Bridge event delegate that implements Memberlist’s EventDelegate.
This is a wrapper around PlumtreeBridge that implements the full
EventDelegate trait for integration with Memberlist.
§Type Parameters
I: Node identifier typeA: Node address typePD: Plumtree delegate typeD: Inner delegate type (for forwarding events)
Implementations§
Source§impl<I, A, PD, D> BridgeEventDelegate<I, A, PD, D>where
I: Id + IdCodec + Clone + Ord + Send + Sync + 'static,
A: CheapClone + Send + Sync + 'static,
PD: PlumtreeDelegate<I>,
impl<I, A, PD, D> BridgeEventDelegate<I, A, PD, D>where
I: Id + IdCodec + Clone + Ord + Send + Sync + 'static,
A: CheapClone + Send + Sync + 'static,
PD: PlumtreeDelegate<I>,
Sourcepub fn new(
bridge: PlumtreeBridge<I, PD>,
) -> BridgeEventDelegate<I, A, PD, VoidDelegate<I, A>>
pub fn new( bridge: PlumtreeBridge<I, PD>, ) -> BridgeEventDelegate<I, A, PD, VoidDelegate<I, A>>
Create a new bridge event delegate with a void inner delegate.
Sourcepub fn with_inner(bridge: PlumtreeBridge<I, PD>, inner: D) -> Self
pub fn with_inner(bridge: PlumtreeBridge<I, PD>, inner: D) -> Self
Create a new bridge event delegate with a custom inner delegate.
Sourcepub fn bridge(&self) -> &PlumtreeBridge<I, PD>
pub fn bridge(&self) -> &PlumtreeBridge<I, PD>
Get a reference to the bridge.
Trait Implementations§
Source§impl<I, A, PD, D> Clone for BridgeEventDelegate<I, A, PD, D>
impl<I, A, PD, D> Clone for BridgeEventDelegate<I, A, PD, D>
Source§impl<I, A, PD, D> EventDelegate for BridgeEventDelegate<I, A, PD, D>where
I: Id + IdCodec + Clone + Ord + Send + Sync + 'static,
A: CheapClone + Send + Sync + 'static,
PD: PlumtreeDelegate<I>,
D: EventDelegate<Id = I, Address = A>,
impl<I, A, PD, D> EventDelegate for BridgeEventDelegate<I, A, PD, D>where
I: Id + IdCodec + Clone + Ord + Send + Sync + 'static,
A: CheapClone + Send + Sync + 'static,
PD: PlumtreeDelegate<I>,
D: EventDelegate<Id = I, Address = A>,
Auto Trait Implementations§
impl<I, A, PD, D> Freeze for BridgeEventDelegate<I, A, PD, D>where
D: Freeze,
impl<I, A, PD, D = VoidDelegate<I, A>> !RefUnwindSafe for BridgeEventDelegate<I, A, PD, D>
impl<I, A, PD, D> Send for BridgeEventDelegate<I, A, PD, D>where
D: Send,
impl<I, A, PD, D> Sync for BridgeEventDelegate<I, A, PD, D>where
D: Sync,
impl<I, A, PD, D> Unpin for BridgeEventDelegate<I, A, PD, D>
impl<I, A, PD, D = VoidDelegate<I, A>> !UnwindSafe for BridgeEventDelegate<I, A, PD, D>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more