http

package
v1.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 18, 2017 License: Apache-2.0 Imports: 2 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultServeMux = NewServeMux()

Functions

This section is empty.

Types

type Pattern

type Pattern []string

POST /servers/<ServerId>/action => []string{"POST", "servers", "*", "action"}

func NewPattern

func NewPattern(pattern string) Pattern

"POST /servers/*/action"

func (Pattern) Match

func (p Pattern) Match(method string, cmds []string) (args []string, ok bool)

type ServeMux

type ServeMux struct {
	// contains filtered or unexported fields
}

func NewServeMux

func NewServeMux() *ServeMux

func (*ServeMux) Handle

func (h *ServeMux) Handle(pattern string, handler http.Handler)

func (*ServeMux) HandleFunc

func (h *ServeMux) HandleFunc(pattern string, handler func(http.ResponseWriter, *http.Request))

func (*ServeMux) ServeHTTP

func (h *ServeMux) ServeHTTP(w http.ResponseWriter, r *http.Request)

func (*ServeMux) SetDefault

func (h *ServeMux) SetDefault(handler http.Handler)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL