pub enum Cmd<M> {
Send {
id: SendId,
to: NodeId,
msg: M,
},
Stop {
id: SendId,
},
}Expand description
Requests from the layer above.
Variants§
Send
Transmit msg to to, and keep transmitting it until stopped.
id must not name a transmission that is still live. Reusing one replaces the earlier
transmission outright: it stops being retransmitted, and SL1 lapses for it silently —
there is no indication, and nothing above is told a promise was withdrawn. The identifier
is the caller’s to allocate, so the uniqueness is the caller’s to hold; debug_assert
checks it in debug builds.
Stop
Stop retransmitting the transmission named id.
Trait Implementations§
impl<M: Eq> Eq for Cmd<M>
impl<M: PartialEq> StructuralPartialEq for Cmd<M>
Auto Trait Implementations§
impl<M> Freeze for Cmd<M>where
M: Freeze,
impl<M> RefUnwindSafe for Cmd<M>where
M: RefUnwindSafe,
impl<M> Send for Cmd<M>where
M: Send,
impl<M> Sync for Cmd<M>where
M: Sync,
impl<M> Unpin for Cmd<M>where
M: Unpin,
impl<M> UnsafeUnpin for Cmd<M>where
M: UnsafeUnpin,
impl<M> UnwindSafe for Cmd<M>where
M: 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