package httputils
import "github.com/dotcloud/docker/pkg/httputils"
Index ¶
- func Download(url string) (resp *http.Response, err error)
- func NewHTTPRequestError(msg string, res *http.Response) error
- func ResumableRequestReader(c *http.Client, r *http.Request, maxfail uint32, totalsize int64) io.ReadCloser
- func ResumableRequestReaderWithInitialResponse(c *http.Client, r *http.Request, maxfail uint32, totalsize int64, initialResponse *http.Response) io.ReadCloser
Functions ¶
func Download ¶
Request a given URL and return an io.Reader
func NewHTTPRequestError ¶
func ResumableRequestReader ¶
func ResumableRequestReader(c *http.Client, r *http.Request, maxfail uint32, totalsize int64) io.ReadCloser
ResumableRequestReader makes it possible to resume reading a request's body transparently maxfail is the number of times we retry to make requests again (not resumes) totalsize is the total length of the body; auto detect if not provided
func ResumableRequestReaderWithInitialResponse ¶
func ResumableRequestReaderWithInitialResponse(c *http.Client, r *http.Request, maxfail uint32, totalsize int64, initialResponse *http.Response) io.ReadCloser
Source Files ¶
httputils.go resumablerequestreader.go
- Version
- v1.7.1-rc1
- Published
- Jul 2, 2015
- Platform
- windows/amd64
- Imports
- 6 packages
- Last checked
- 1 hour ago –
Tools for package owners.