pub struct Replicaset { /* private fields */ }Expand description
A replicaset with its instances and the buckets it owns.
Implementations§
Source§impl Replicaset
impl Replicaset
Sourcepub fn master(&self) -> Option<&Instance>
pub fn master(&self) -> Option<&Instance>
The current master, or None while the cluster has not named one.
Sourcepub fn instances(&self) -> impl Iterator<Item = &Instance>
pub fn instances(&self) -> impl Iterator<Item = &Instance>
All the instances, the master first.
Sourcepub fn ranges(&self) -> &[RangeInclusive<u64>]
pub fn ranges(&self) -> &[RangeInclusive<u64>]
Bucket ranges the replicaset owns, ordered by start.
Trait Implementations§
Source§impl Clone for Replicaset
impl Clone for Replicaset
Source§impl Debug for Replicaset
impl Debug for Replicaset
impl Eq for Replicaset
Source§impl PartialEq for Replicaset
impl PartialEq for Replicaset
impl StructuralPartialEq for Replicaset
Auto Trait Implementations§
impl Freeze for Replicaset
impl RefUnwindSafe for Replicaset
impl Send for Replicaset
impl Sync for Replicaset
impl Unpin for Replicaset
impl UnsafeUnpin for Replicaset
impl UnwindSafe for Replicaset
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