middleware

package
v1.15.7-go1.9 Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2023 License: MIT Imports: 3 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Context

type Context struct {
	PrefixReqPath string
	VhostReqPath  string
	AliasReqPath  string
	AliasFsPath   string
	AliasFsRoot   string

	NeedAuth     bool
	AuthUserName string
	AuthSuccess  bool

	RestrictAccess bool
	AllowAccess    bool

	WantJson bool

	Status int

	Item     os.FileInfo
	SubItems []os.FileInfo

	Logger *serverLog.Logger
}

type Middleware

type Middleware func(w http.ResponseWriter, r *http.Request, context *Context) (result ProcessResult)

type ProcessResult added in v1.15.3

type ProcessResult int
const (
	GoNext ProcessResult = iota
	SkipRests
	Outputted
)

Jump to

Keyboard shortcuts

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