package
0.0.0-20130121074735-1d03baafba06
Repository: https://github.com/icattlecoder/go.git
Documentation: pkg.go.dev
# Packages
Package cgi implements CGI (Common Gateway Interface) as specified in RFC 3875.
Package fcgi implements the FastCGI protocol.
Package httptest provides utilities for HTTP testing.
Package httputil provides HTTP utility functions, complementing the more common ones in the net/http package.
Package pprof serves via its HTTP server runtime profiling data in the format expected by the pprof visualization tool.
# Functions
CanonicalHeaderKey returns the canonical format of the header key s.
DetectContentType implements the algorithm described at http://mimesniff.spec.whatwg.org/ to determine the Content-Type of the given data.
Error replies to the request with the specified error message and HTTP code.
FileServer returns a handler that serves HTTP requests with the contents of the file system rooted at root.
Get issues a GET to the specified URL.
Handle registers the handler for the given pattern in the DefaultServeMux.
HandleFunc registers the handler function for the given pattern in the DefaultServeMux.
Head issues a HEAD to the specified URL.
ListenAndServe listens on the TCP network address addr and then calls Serve with handler to handle requests on incoming connections.
ListenAndServeTLS acts identically to ListenAndServe, except that it expects HTTPS connections.
MaxBytesReader is similar to io.LimitReader but is intended for limiting the size of incoming request bodies.
NewFileTransport returns a new RoundTripper, serving the provided FileSystem.
NewRequest returns a new Request given a method, URL, and optional body.
NewServeMux allocates and returns a new ServeMux.
NotFound replies to the request with an HTTP 404 not found error.
NotFoundHandler returns a simple request handler that replies to each request with a ``404 page not found'' reply.
ParseHTTPVersion parses a HTTP version string.
ParseTime parses a time header (such as the Date: header), trying each of the three formats allowed by HTTP/1.1: TimeFormat, time.RFC850, and time.ANSIC.
Post issues a POST to the specified URL.
PostForm issues a POST to the specified URL, with data's keys and values URL-encoded as the request body.
ProxyFromEnvironment returns the URL of the proxy to use for a given request, as indicated by the environment variables $HTTP_PROXY and $NO_PROXY (or $http_proxy and $no_proxy).
ProxyURL returns a proxy function (for use in a Transport) that always returns the same URL.
ReadRequest reads and parses a request from b.
ReadResponse reads and returns an HTTP response from r.
Redirect replies to the request with a redirect to url, which may be a path relative to the request path.
RedirectHandler returns a request handler that redirects each request it receives to the given url using the given status code.
Serve accepts incoming HTTP connections on the listener l, creating a new service goroutine for each.
ServeContent replies to the request using the content in the provided ReadSeeker.
ServeFile replies to the request with the contents of the named file or directory.
SetCookie adds a Set-Cookie header to the provided ResponseWriter's headers.
StatusText returns a text for the HTTP status code.
StripPrefix returns a handler that serves HTTP requests by removing the given prefix from the request URL's Path and invoking the handler h.
TimeoutHandler returns a Handler that runs h with the given time limit.
# Constants
1 MB.
DefaultMaxIdleConnsPerHost is the default value of Transport's MaxIdleConnsPerHost.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
HTTP status codes, defined in RFC 2616.
TimeFormat is the time format to use with time.Parse and time.Time.Format when parsing or generating times in HTTP headers.
# Variables
DefaultClient is the default Client and is used by Get, Head, and Post.
DefaultServeMux is the default ServeMux used by Serve.
DefaultTransport is the default implementation of Transport and is used by DefaultClient.
Errors introduced by the HTTP server.
ErrBodyReadAfterClose is returned when reading a Request or Response Body after the body has been closed.
Errors introduced by the HTTP server.
ErrHandlerTimeout is returned on ResponseWriter Write calls in handlers which have timed out.
No description provided by the author
Errors introduced by the HTTP server.
No description provided by the author
No description provided by the author
No description provided by the author
ErrMissingFile is returned by FormFile when the provided file field name is either not present in the request or not a file field.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Errors introduced by the HTTP server.
# Structs
A Client is an HTTP client.
A Cookie represents an HTTP cookie as sent in the Set-Cookie header of an HTTP response or the Cookie header of an HTTP request.
HTTP request parsing errors.
A Request represents an HTTP request received by a server or to be sent by a client.
Response represents the response from an HTTP request.
ServeMux is an HTTP request multiplexer.
A Server defines parameters for running an HTTP server.
Transport is an implementation of RoundTripper that supports http, https, and http proxies (for either http or https with CONNECT).
# Interfaces
The CloseNotifier interface is implemented by ResponseWriters which allow detecting when the underlying connection has gone away.
A CookieJar manages storage and use of cookies in HTTP requests.
A File is returned by a FileSystem's Open method and can be served by the FileServer implementation.
A FileSystem implements access to a collection of named files.
The Flusher interface is implemented by ResponseWriters that allow an HTTP handler to flush buffered data to the client.
Objects implementing the Handler interface can be registered to serve a particular path or subtree in the HTTP server.
The Hijacker interface is implemented by ResponseWriters that allow an HTTP handler to take over the connection.
A ResponseWriter interface is used by an HTTP handler to construct an HTTP response.
RoundTripper is an interface representing the ability to execute a single HTTP transaction, obtaining the Response for a given Request.
# Type aliases
A Dir implements http.FileSystem using the native file system restricted to a specific directory tree.
The HandlerFunc type is an adapter to allow the use of ordinary functions as HTTP handlers.
A Header represents the key-value pairs in an HTTP header.