server

package
v0.0.19 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 25, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server represents the main HTTP server.

func New

func New(cache *cache.Cache) *Server

New returns a new server.

func (*Server) ServeHTTP

func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP implements http.Handler and turns the Server type into a handler.

func (*Server) SetDeletePermitted added in v0.0.4

func (s *Server) SetDeletePermitted(dp bool)

SetDeletePermitted configures the server to either allow or deny access to DELETE.

func (*Server) SetPutPermitted added in v0.0.4

func (s *Server) SetPutPermitted(pp bool)

SetPutPermitted configures the server to either allow or deny access to PUT.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL