pub enum Wire<R, C> {
Broadcast(R),
Consensus {
round: u64,
msg: C,
},
}Expand description
This layer’s messages: the broadcast’s, and a consensus instance’s stamped with its round.
Variants§
Broadcast(R)
A reliable broadcast message.
Consensus
A consensus message, stamped with the round whose instance it belongs to.
The page addresses instances as c.round; nothing on this wire does. The stamp is this
layer’s rather than the consensus’s, because the round is this layer’s concept — which is why
it cannot live in the child as crate::epoch_consensus::Tagged’s does.
Trait Implementations§
Source§impl<'de, R, C> Deserialize<'de> for Wire<R, C>where
R: Deserialize<'de>,
C: Deserialize<'de>,
impl<'de, R, C> Deserialize<'de> for Wire<R, C>where
R: Deserialize<'de>,
C: Deserialize<'de>,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl<R: Eq, C: Eq> Eq for Wire<R, C>
Source§impl<R: PartialEq, C: PartialEq> PartialEq for Wire<R, C>
impl<R: PartialEq, C: PartialEq> PartialEq for Wire<R, C>
impl<R: PartialEq, C: PartialEq> StructuralPartialEq for Wire<R, C>
Auto Trait Implementations§
impl<R, C> Freeze for Wire<R, C>
impl<R, C> RefUnwindSafe for Wire<R, C>where
R: RefUnwindSafe,
C: RefUnwindSafe,
impl<R, C> Send for Wire<R, C>
impl<R, C> Sync for Wire<R, C>
impl<R, C> Unpin for Wire<R, C>
impl<R, C> UnsafeUnpin for Wire<R, C>where
R: UnsafeUnpin,
C: UnsafeUnpin,
impl<R, C> UnwindSafe for Wire<R, C>where
R: UnwindSafe,
C: UnwindSafe,
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