code: func NewHandlerMap(rhs []RouteHandler) HandlerMap {
  	hm := HandlerMap{}
  	for _, rh := range rhs {
  		route := HTTPRoute{
  			Path:   rh.Path,
  			Method: rh.Method,
  		}
  		hm[route] = rh.Handler
  	}
  	return hm
  }
docs: // NewHandlerMap builds a HandlerMap from a slice of RouteHandlers. This is a
  // convenience function, since using RouteHandlers directly is very verbose for
  // plugins.