Struct raft::prelude::ConfChangeV2[][src]

pub struct ConfChangeV2 {
    pub transition: ConfChangeTransition,
    pub changes: RepeatedField<ConfChangeSingle>,
    pub context: Bytes,
    pub unknown_fields: UnknownFields,
    pub cached_size: CachedSize,
}

Fields

transition: ConfChangeTransitionchanges: RepeatedField<ConfChangeSingle>context: Bytesunknown_fields: UnknownFieldscached_size: CachedSize

Implementations

impl ConfChangeV2[src]

pub fn enter_joint(&self) -> Option<bool>[src]

Checks if uses Joint Consensus.

It will return Some if and only if this config change will use Joint Consensus, which is the case if it contains more than one change or if the use of Joint Consensus was requested explicitly. The bool indicates whether the Joint State will be left automatically.

pub fn leave_joint(&self) -> bool[src]

Checks if the configuration change leaves a joint configuration.

This is the case if the ConfChangeV2 is zero, with the possible exception of the Context field.

impl ConfChangeV2[src]

pub fn new() -> ConfChangeV2[src]

pub fn get_transition(&self) -> ConfChangeTransition[src]

pub fn clear_transition(&mut self)[src]

pub fn set_transition(&mut self, v: ConfChangeTransition)[src]

pub fn get_changes(&self) -> &[ConfChangeSingle][src]

pub fn clear_changes(&mut self)[src]

pub fn set_changes(&mut self, v: RepeatedField<ConfChangeSingle>)[src]

pub fn mut_changes(&mut self) -> &mut RepeatedField<ConfChangeSingle>[src]

pub fn take_changes(&mut self) -> RepeatedField<ConfChangeSingle>[src]

pub fn get_context(&self) -> &[u8][src]

pub fn clear_context(&mut self)[src]

pub fn set_context(&mut self, v: Bytes)[src]

pub fn mut_context(&mut self) -> &mut Bytes[src]

pub fn take_context(&mut self) -> Bytes[src]

Trait Implementations

impl Clear for ConfChangeV2[src]

impl Clone for ConfChangeV2[src]

impl ConfChangeI for ConfChangeV2[src]

impl Debug for ConfChangeV2[src]

impl Default for ConfChangeV2[src]

impl<'a> Default for &'a ConfChangeV2[src]

impl Message for ConfChangeV2[src]

impl PartialEq<ConfChangeV2> for ConfChangeV2[src]

impl PbPrint for ConfChangeV2[src]

impl ProtobufValue for ConfChangeV2[src]

impl StructuralPartialEq for ConfChangeV2[src]

Auto Trait Implementations

impl RefUnwindSafe for ConfChangeV2

impl Send for ConfChangeV2

impl Sync for ConfChangeV2

impl Unpin for ConfChangeV2

impl UnwindSafe for ConfChangeV2

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]