/// Sends single command and waits for response
Sends single command and waits for response
Sends single command and waits for response
pub async fn send_command(self, cmd: Command) -> Result<CommandResponse, String> {
        let (message, promise) = self.prepare_command_to_send(&cmd);
        self.write.borrow_mut().send(message).await.unwrap();
        Ok(promise.await)
    }
pub async fn send_command ( self , cmd : Command ) -> Result < CommandResponse , String > { let ( message , promise ) = self . prepare_command_to_send ( & cmd ) ; self . write . borrow_mut ( ) . send ( message ) . await . unwrap ( ) ; Ok ( promise . await ) }
Sends single command and waits for response
Sends single command and waits for response
self
cmd
Command