util

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2024 License: Apache-2.0, Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CorsMiddleware

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

func NewCors

func NewCors(handler http.Handler) *CorsMiddleware

func (*CorsMiddleware) ServeHTTP

func (this *CorsMiddleware) ServeHTTP(res http.ResponseWriter, req *http.Request)

type LoggerMiddleWare

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

func NewLogger

func NewLogger(handler http.Handler) *LoggerMiddleWare

func (*LoggerMiddleWare) ServeHTTP

func (this *LoggerMiddleWare) ServeHTTP(w http.ResponseWriter, request *http.Request)

type ResponseWriterWithStatusCodeLog

type ResponseWriterWithStatusCodeLog struct {
	Parent http.ResponseWriter
	Status int
}

func (*ResponseWriterWithStatusCodeLog) Header

func (*ResponseWriterWithStatusCodeLog) Write

func (this *ResponseWriterWithStatusCodeLog) Write(payload []byte) (int, error)

func (*ResponseWriterWithStatusCodeLog) WriteHeader

func (this *ResponseWriterWithStatusCodeLog) WriteHeader(statusCode int)

Jump to

Keyboard shortcuts

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