fn send_message(&self, message: Message) -> Result<(), Error> {
        if self.thread_terminated.load(Ordering::SeqCst) {
            error!("agent thread terminated prematurely");
            return Err(Error::Internal);
        }

        self.message_tx.send(message).map_err(|_| Error::Internal)?;
        self.notify_tx.notify();

        Ok(())
    }
/// Send a message to the associated agent.
///
/// If the agent is not connected, an error is returned.
Send a message to the associated agent.
If the agent is not connected, an error is returned.
Send a message to the associated agent . If the agent is not connected an error is returned .
fn send_message(&self, message: Message) -> Result<(), Error> {
        if self.thread_terminated.load(Ordering::SeqCst) {
            error!("agent thread terminated prematurely");
            return Err(Error::Internal);
        }
        self.message_tx.send(message).map_err(|_| Error::Internal)?;
        self.notify_tx.notify();
        Ok(())
    }
fn send_message ( & self , message : Message ) -> Result < ( ) , Error > { if self . thread_terminated . load ( Ordering :: SeqCst ) { error ! ( " " ) ; return Err ( Error :: Internal ) ; } self . message_tx . send ( message ) . map_err ( | _ | Error :: Internal ) ? ; self . notify_tx . notify ( ) ; Ok ( ( ) ) }
Send a message to the associated agent.
Send a message to the associated agent .
&self
message
Message
&self
message
Message