MCPcopy
hub / github.com/gorilla/mux / BuildVarsFunc

Method BuildVarsFunc

mux.go:355–357  ·  view source on GitHub ↗

BuildVarsFunc registers a new route with a custom function for modifying route variables before building a URL.

(f BuildVarsFunc)

Source from the content-addressed store, hash-verified

353// BuildVarsFunc registers a new route with a custom function for modifying
354// route variables before building a URL.
355func (r *Router) BuildVarsFunc(f BuildVarsFunc) *Route {
356 return r.NewRoute().BuildVarsFunc(f)
357}
358
359// Walk walks the router and all its sub-routers, calling walkFn for each route
360// in the tree. The routes are walked in the order they were added. Sub-routers

Callers 1

TestBuildVarsFuncFunction · 0.45

Calls 1

NewRouteMethod · 0.95

Tested by 1

TestBuildVarsFuncFunction · 0.36