Struct minetest_protocol::services::client::MinetestClient
source · pub struct MinetestClient { /* private fields */ }
Implementations§
source§impl MinetestClient
impl MinetestClient
pub async fn connect(connect_to: SocketAddr) -> Result<Self>
sourcepub async fn recv(&mut self) -> Result<ToClientCommand>
pub async fn recv(&mut self) -> Result<ToClientCommand>
If this fails, the client has disconnected.
sourcepub async fn send(&mut self, command: ToServerCommand) -> Result<()>
pub async fn send(&mut self, command: ToServerCommand) -> Result<()>
If this fails, the client has disconnected.