MCPcopy Create free account
hub / github.com/devfeel/dotweb / ServerFile

Method ServerFile

router.go:413–415  ·  view source on GitHub ↗

ServerFile register ServerFile router with GET method on http.FileServer simple demo:router.ServerFile("/src/*", "/var/www") simple demo:router.ServerFile("/src/*filepath", "/var/www")

(path string, fileRoot string)

Source from the content-addressed store, hash-verified

411// simple demo:router.ServerFile("/src/*", "/var/www")
412// simple demo:router.ServerFile("/src/*filepath", "/var/www")
413func (r *router) ServerFile(path string, fileRoot string) RouterNode {
414 return r.RegisterServerFile(RouteMethod_GET, path, fileRoot, nil)
415}
416
417// RegisterServerFile register ServerFile router with routeMethod method on http.FileServer
418// simple demo:server.RegisterServerFile(RouteMethod_GET, "/src/*", "/var/www", nil)

Callers

nothing calls this directly

Calls 1

RegisterServerFileMethod · 0.95

Tested by

no test coverage detected