pub enum ServerCMD {
ShutDown(u32),
SendAll(String),
Kick(SocketAddr),
}
Expand description
Defines commands that can be sent to the server.
Variants§
ShutDown(u32)
Instructs the server to shut down with the specified error code.
SendAll(String)
Instructs the server to send a message to all connected clients.
Kick(SocketAddr)
Instructs the server to kick a certain client identified by its socket address.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ServerCMD
impl RefUnwindSafe for ServerCMD
impl Send for ServerCMD
impl Sync for ServerCMD
impl Unpin for ServerCMD
impl UnwindSafe for ServerCMD
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