pub fn canon_request<B>(parts: Parts, body: B, uri: Uri) -> Request<B>
Expand description

Create a Request by canonicalizing a URI

This function generates a Request whose URI combines the scheme and authority from uri with the path and query from parts.uri.

Arguments

  • parts - the Parts of the resulting Request, except that the scheme and authority from `parts.uri is ignored.
  • body - the body of the resulting Request.
  • uri - the scheme (i.e., “http”, “wss”, …) and authority (e.g., “mynode.xyz:1357”) of thhe URI in the resulting Request. The path and query from this URI are ignored.