Skip to main content

send_message

Function send_message 

Source
pub async fn send_message<W>(
    writer: &mut FramedWrite<W, LengthDelimitedCodec>,
    msg: &impl Serialize,
) -> Result<(), Error>
where W: AsyncWrite + Unpin,
Expand description

Serialize a message as JSON and send it over a framed writer.