pub struct Channel(/* private fields */);Expand description
One exclusively used endpoint of a reliable local channel carrying u32 records. Ownership may transfer during startup; shared cross-thread access is excluded.
Implementations§
Source§impl Channel
impl Channel
pub fn pair() -> Result<(Self, Self), Create>
Sourcepub fn send(&self, value: u32) -> Result<(), Fault>
pub fn send(&self, value: u32) -> Result<(), Fault>
A failed send is terminal: a stream may already have transferred a prefix.
Sourcepub fn recv(&self) -> Record
pub fn recv(&self) -> Record
Receives one exact record, retaining native packet or stream framing. A syscall error is terminal: a stream may already have transferred a prefix.
pub fn shutdown(&self) -> Result<(), Errno>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Channel
impl !Sync for Channel
impl Freeze for Channel
impl Send for Channel
impl Unpin for Channel
impl UnsafeUnpin for Channel
impl UnwindSafe for Channel
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