pub struct BufferedMailbox<P>where
P: Protocol,{ /* private fields */ }Implementations§
Source§impl<P> BufferedMailbox<P>where
P: Protocol,
impl<P> BufferedMailbox<P>where
P: Protocol,
pub fn is_empty(&self) -> bool
pub fn pop_inbound(&mut self) -> Option<ProtocolPayload<P>>
pub fn drain_inbound( &mut self, ) -> impl DoubleEndedIterator<Item = ProtocolPayload<P>> + ExactSizeIterator + FusedIterator + '_
pub fn drain_replies( &mut self, ) -> impl DoubleEndedIterator<Item = Envelope<ClientIdentifier, Reply<P::Reply>>> + ExactSizeIterator + FusedIterator + '_
pub fn drain_send( &mut self, ) -> impl DoubleEndedIterator<Item = Envelope<usize, ProtocolPayload<P>>> + ExactSizeIterator + FusedIterator + '_
pub fn drain_broadcast( &mut self, ) -> impl DoubleEndedIterator<Item = ProtocolPayload<P>> + ExactSizeIterator + FusedIterator + '_
Trait Implementations§
Source§impl<P> Default for BufferedMailbox<P>where
P: Protocol,
impl<P> Default for BufferedMailbox<P>where
P: Protocol,
Source§impl<P> Inbox<P> for BufferedMailbox<P>where
P: Protocol,
impl<P> Inbox<P> for BufferedMailbox<P>where
P: Protocol,
fn push_prepare(&mut self, message: Prepare<P::Request, P::Prediction>)
fn push_prepare_ok(&mut self, message: PrepareOk)
fn push_commit(&mut self, message: Commit)
fn push_get_state(&mut self, message: GetState)
fn push_new_state(&mut self, message: NewState<P::Request, P::Prediction>)
fn push_start_view_change(&mut self, message: StartViewChange)
fn push_do_view_change( &mut self, message: DoViewChange<P::Request, P::Prediction>, )
fn push_start_view(&mut self, message: StartView<P::Request, P::Prediction>)
fn push_recovery(&mut self, message: Recovery)
fn push_recovery_response( &mut self, message: RecoveryResponse<P::Request, P::Prediction>, )
Source§impl<P> Outbox<P> for BufferedMailbox<P>where
P: Protocol,
impl<P> Outbox<P> for BufferedMailbox<P>where
P: Protocol,
fn prepare(&mut self, message: Prepare<P::Request, P::Prediction>)
fn prepare_ok(&mut self, index: usize, message: PrepareOk)
fn commit(&mut self, message: Commit)
fn get_state(&mut self, index: usize, message: GetState)
fn new_state( &mut self, index: usize, message: NewState<P::Request, P::Prediction>, )
fn start_view_change(&mut self, message: StartViewChange)
fn do_view_change( &mut self, index: usize, message: DoViewChange<P::Request, P::Prediction>, )
fn start_view(&mut self, message: StartView<P::Request, P::Prediction>)
fn recovery(&mut self, message: Recovery)
fn recovery_response( &mut self, index: usize, message: RecoveryResponse<P::Request, P::Prediction>, )
fn reply(&mut self, client: ClientIdentifier, reply: &Reply<P::Reply>)
impl<P> Mailbox<P> for BufferedMailbox<P>where
P: Protocol,
Auto Trait Implementations§
impl<P> Freeze for BufferedMailbox<P>
impl<P> RefUnwindSafe for BufferedMailbox<P>where
<P as Protocol>::Prediction: RefUnwindSafe,
<P as Protocol>::Reply: RefUnwindSafe,
<P as Protocol>::Request: RefUnwindSafe,
impl<P> Send for BufferedMailbox<P>
impl<P> Sync for BufferedMailbox<P>
impl<P> Unpin for BufferedMailbox<P>
impl<P> UnwindSafe for BufferedMailbox<P>where
<P as Protocol>::Prediction: UnwindSafe,
<P as Protocol>::Reply: UnwindSafe,
<P as Protocol>::Request: UnwindSafe,
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