pub(super) async fn write_to_stream( writer: &mut WriteHalf<Box<dyn PtStream>>, object: &JsonResult, ) -> Result<()>
Internal write function that writes a JSON-RPC object to the active stream.