Documentation
¶
Index ¶
- Variables
- func NewMuxWithConfig(conf *Config) (http.Handler, error)
- type Config
- type Mux
- func (m *Mux) HandlePath(path string, handler http.Handler)
- func (m *Mux) HandlePrefix(prefix string, handler http.Handler) error
- func (m *Mux) HandlePrefixAndRegexp(prefix, reg string, handler http.Handler) error
- func (m *Mux) Handler(path string) (handler http.Handler)
- func (m *Mux) NotFound(handler http.Handler)
- func (m *Mux) ServeHTTP(rw http.ResponseWriter, r *http.Request)
- type Route
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNotHandler = fmt.Errorf("error not handler") ErrNotRouter = fmt.Errorf("error not router") )
View Source
var (
ErrRouteAlreadyExists = fmt.Errorf("error route already exists")
)
Functions ¶
Types ¶
type Mux ¶
type Mux struct {
// contains filtered or unexported fields
}
Mux is an Applicative protocol multiplexer.
func (*Mux) HandlePrefixAndRegexp ¶
func (*Mux) Handler ¶
Handler returns most matching handler and prefix bytes data to use for the given reader.
Click to show internal directories.
Click to hide internal directories.