Skip to content

Document the typical value for an io param #2568

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/client/conn.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,9 @@ where

/// Returns a handshake future over some IO.
///
/// The io parameter will usually be a
/// [tokio::net::TcpStream](https://docs.rs/tokio/latest/tokio/net/struct.TcpStream.html).
///
/// This is a shortcut for `Builder::new().handshake(io)`.
pub async fn handshake<T>(
io: T,
Expand All @@ -106,6 +109,9 @@ pub struct SendRequest<B> {

/// A future that processes all HTTP state for the IO object.
///
/// The io parameter will usually be a
/// [tokio::net::TcpStream](https://docs.rs/tokio/latest/tokio/net/struct.TcpStream.html).
///
/// In most cases, this should just be spawned into an executor, so that it
/// can process incoming and outgoing messages, notice hangups, and the like.
#[must_use = "futures do nothing unless polled"]
Expand Down