pub struct RaftHardState {
pub term: u64,
pub voted_for: Option<usize>,
}Expand description
What must survive a restart: the term, the vote and the log.
Fields§
§term: u64§voted_for: Option<usize>Trait Implementations§
Source§impl Clone for RaftHardState
impl Clone for RaftHardState
Source§impl Debug for RaftHardState
impl Debug for RaftHardState
Source§impl Default for RaftHardState
impl Default for RaftHardState
impl Eq for RaftHardState
Source§impl PartialEq for RaftHardState
impl PartialEq for RaftHardState
impl StructuralPartialEq for RaftHardState
Auto Trait Implementations§
impl Freeze for RaftHardState
impl RefUnwindSafe for RaftHardState
impl Send for RaftHardState
impl Sync for RaftHardState
impl Unpin for RaftHardState
impl UnsafeUnpin for RaftHardState
impl UnwindSafe for RaftHardState
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