package
0.34.0
Repository: https://go.googlesource.com/net
Documentation: pkg.go.dev

# Packages

Package ctxhttp provides helper functions for performing context-aware HTTP requests.

# Functions

Background returns a non-nil, empty Context.
TODO returns a non-nil, empty Context.
WithCancel returns a copy of parent with a new Done channel.
WithDeadline returns a copy of the parent context with the deadline adjusted to be no later than d.
WithTimeout returns WithDeadline(parent, time.Now().Add(timeout)).
WithValue returns a copy of parent in which the value associated with key is val.

# Variables

Canceled is the error returned by Context.Err when the context is canceled.
DeadlineExceeded is the error returned by Context.Err when the context's deadline passes.

# Type aliases

A CancelFunc tells an operation to abandon its work.
A Context carries a deadline, a cancelation signal, and other values across API boundaries.