pub enum ProgressMessage {
HotStuffMessage(HotStuffMessage),
PacemakerMessage(PacemakerMessage),
BlockSyncAdvertiseMessage(BlockSyncAdvertiseMessage),
}
Expand description
Message variants sent or received by the algorithm
thread.
Variants§
HotStuffMessage(HotStuffMessage)
See HotStuffMessage
.
PacemakerMessage(PacemakerMessage)
See PacemakerMessage
.
BlockSyncAdvertiseMessage(BlockSyncAdvertiseMessage)
Implementations§
source§impl ProgressMessage
impl ProgressMessage
sourcepub fn view(&self) -> Option<ViewNumber>
pub fn view(&self) -> Option<ViewNumber>
Get the view
field of the inner message.
sourcepub fn is_block_sync_trigger_msg(&self) -> bool
pub fn is_block_sync_trigger_msg(&self) -> bool
Check whether the inner message is a BlockSyncAdvertiseMessage
.
Trait Implementations§
source§impl BorshDeserialize for ProgressMessagewhere
HotStuffMessage: BorshDeserialize,
PacemakerMessage: BorshDeserialize,
BlockSyncAdvertiseMessage: BorshDeserialize,
impl BorshDeserialize for ProgressMessagewhere
HotStuffMessage: BorshDeserialize,
PacemakerMessage: BorshDeserialize,
BlockSyncAdvertiseMessage: BorshDeserialize,
fn deserialize_reader<R: Read>(reader: &mut R) -> Result<Self, Error>
§fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>
Deserializes this instance from a given slice of bytes.
Updates the buffer to point at the remaining bytes.
§fn try_from_slice(v: &[u8]) -> Result<Self, Error>
fn try_from_slice(v: &[u8]) -> Result<Self, Error>
Deserialize this instance from a slice of bytes.
fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>where
R: Read,
source§impl BorshSerialize for ProgressMessagewhere
HotStuffMessage: BorshSerialize,
PacemakerMessage: BorshSerialize,
BlockSyncAdvertiseMessage: BorshSerialize,
impl BorshSerialize for ProgressMessagewhere
HotStuffMessage: BorshSerialize,
PacemakerMessage: BorshSerialize,
BlockSyncAdvertiseMessage: BorshSerialize,
source§impl Clone for ProgressMessage
impl Clone for ProgressMessage
source§fn clone(&self) -> ProgressMessage
fn clone(&self) -> ProgressMessage
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl EnumExt for ProgressMessagewhere
HotStuffMessage: BorshDeserialize,
PacemakerMessage: BorshDeserialize,
BlockSyncAdvertiseMessage: BorshDeserialize,
impl EnumExt for ProgressMessagewhere
HotStuffMessage: BorshDeserialize,
PacemakerMessage: BorshDeserialize,
BlockSyncAdvertiseMessage: BorshDeserialize,
source§impl Into<ProgressMessage> for HotStuffMessage
impl Into<ProgressMessage> for HotStuffMessage
source§fn into(self) -> ProgressMessage
fn into(self) -> ProgressMessage
Converts this type into the (usually inferred) input type.
source§impl Into<ProgressMessage> for PacemakerMessage
impl Into<ProgressMessage> for PacemakerMessage
source§fn into(self) -> ProgressMessage
fn into(self) -> ProgressMessage
Converts this type into the (usually inferred) input type.
Auto Trait Implementations§
impl Freeze for ProgressMessage
impl RefUnwindSafe for ProgressMessage
impl Send for ProgressMessage
impl Sync for ProgressMessage
impl Unpin for ProgressMessage
impl UnwindSafe for ProgressMessage
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)