Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type StaticFileServer ¶
type StaticFileServer struct {
// contains filtered or unexported fields
}
StaticFileServer implements a static file http server that serves static files out of the runfiles bundled with this application.
func NewStaticFileServer ¶
func NewStaticFileServer(env environment.Env, relPath string, rootPaths []string) (*StaticFileServer, error)
NewStaticFileServer returns a new static file server that will serve the content in relpath, optionally stripping the prefix.
func (*StaticFileServer) ServeHTTP ¶
func (s *StaticFileServer) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP implements the HTTP HandlerFunc interface.
Click to show internal directories.
Click to hide internal directories.