middleware

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Crypto

type Crypto interface {
	DecryptString(text string) (string, error)
}

type Logger

type Logger interface {
	Debug(msg string, kv ...any)
	Error(err error, msg string, kv ...any)
}

type MiddlewareFunc

type MiddlewareFunc func(tarmac.HandlerFunc) tarmac.HandlerFunc

func BasicAuth

func BasicAuth(crypto Crypto) MiddlewareFunc

func Log

func Log(logger Logger) MiddlewareFunc

func Recover

func Recover(logger Logger) MiddlewareFunc

func RenderTypeJSON

func RenderTypeJSON() MiddlewareFunc

func RenderTypeXML

func RenderTypeXML() MiddlewareFunc

func RequestID

func RequestID() MiddlewareFunc

Jump to

Keyboard shortcuts

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