pub async fn write_all_with_timeout<S, B>(
stream: &mut S,
buf: B,
duration: Option<Duration>,
) -> Result<BufResult<(), B>>Expand description
Execute an async write_all operation with a timeout.
Writes the entire buffer or returns an error.