pub struct NetworkMonitor { /* private fields */ }Implementations§
Source§impl NetworkMonitor
impl NetworkMonitor
pub fn new(config: ClusterConfig) -> Self
pub fn update_connected_nodes( &mut self, nodes: HashSet<NodeId>, ) -> Vec<NetworkEvent>
pub fn has_quorum(&self) -> bool
pub fn connected_nodes(&self) -> &HashSet<NodeId>
pub fn quorum_size(&self) -> usize
Auto Trait Implementations§
impl Forget for NetworkMonitor
impl Freeze for NetworkMonitor
impl Move for NetworkMonitor
impl RefUnwindSafe for NetworkMonitor
impl Send for NetworkMonitor
impl Sync for NetworkMonitor
impl Unpin for NetworkMonitor
impl UnsafeUnpin for NetworkMonitor
impl UnwindSafe for NetworkMonitor
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