pub struct VirtualSocket<ID: Debug + Clone, MSG> { /* private fields */ }Implementations§
Source§impl<ID: Debug + Clone, MSG> VirtualSocket<ID, MSG>
impl<ID: Debug + Clone, MSG> VirtualSocket<ID, MSG>
pub fn ctx(&self) -> &VirtualSocketContext
pub fn send_to( &self, dest: Option<SocketAddr>, msg: MSG, ) -> Result<(), VirtualSocketError>
pub async fn recv(&self) -> Result<MSG, VirtualSocketError>
pub async fn close(&mut self)
Trait Implementations§
Auto Trait Implementations§
impl<ID, MSG> Freeze for VirtualSocket<ID, MSG>where
ID: Freeze,
impl<ID, MSG> RefUnwindSafe for VirtualSocket<ID, MSG>where
ID: RefUnwindSafe,
impl<ID, MSG> Send for VirtualSocket<ID, MSG>
impl<ID, MSG> Sync for VirtualSocket<ID, MSG>
impl<ID, MSG> Unpin for VirtualSocket<ID, MSG>where
ID: Unpin,
impl<ID, MSG> UnwindSafe for VirtualSocket<ID, MSG>where
ID: 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