func (m *Mux) Handle(method, pattern string, handler HandlerFunc) {
	if method == "" {
		panic(fmt.Errorf("invalid method"))
	}
	m.trie.Define(pattern).Handle(strings.ToUpper(method), handler)
}
Handle registers a new handler with method and path in the Mux.
For GET, POST, PUT, PATCH and DELETE requests the respective shortcut
functions can be used.

This function is intended for bulk loading and to allow the usage of less
frequently used, non-standardized or custom methods (e.g. for internal
communication with a proxy).
package mux
import (
	"fmt"
	"net/http"
	"strings"
	"github.com/teambition/trie-mux"
)
type Params map[string]string
type HandlerFunc func(http.ResponseWriter, *http.Request, Params)
type Mux struct {
	trie      *trie.Trie
	otherwise HandlerFunc
}
func New(opts ...trie.Options) *Mux {
	return &Mux{trie: trie.New(opts...)}
}
func (m *Mux) Get(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodGet, pattern, handler)
}
func (m *Mux) Head(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodHead, pattern, handler)
}
func (m *Mux) Post(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodPost, pattern, handler)
}
func (m *Mux) Put(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodPut, pattern, handler)
}
func (m *Mux) Patch(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodPatch, pattern, handler)
}
func (m *Mux) Delete(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodDelete, pattern, handler)
}
func (m *Mux) Options(pattern string, handler HandlerFunc) {
	m.Handle(http.MethodOptions, pattern, handler)
}
func (m *Mux) Otherwise(handler HandlerFunc) {
	m.otherwise = handler
}