pub struct UdpManager { /* private fields */ }Expand description
Actor-style UDP manager bound to a single socket.
Implementations§
Source§impl UdpManager
impl UdpManager
pub async fn bind( addr: SocketAddr, ) -> Result<(Self, UnboundedReceiver<IoEvent>)>
pub fn local_addr(&self) -> SocketAddr
pub fn send_to(&self, to: SocketAddr, bytes: Vec<u8>) -> Result<()>
pub fn shutdown(&self)
Auto Trait Implementations§
impl Freeze for UdpManager
impl RefUnwindSafe for UdpManager
impl Send for UdpManager
impl Sync for UdpManager
impl Unpin for UdpManager
impl UnsafeUnpin for UdpManager
impl UnwindSafe for UdpManager
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