handlers

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BaseHandler

func BaseHandler(handler AppHandler) http.Handler

Types

type AppHandler

type AppHandler interface {
	Serve(ctx context.Context, w http.ResponseWriter, r *http.Request) *HTTPResponse
}

type BasicErrorMessage

type BasicErrorMessage struct {
	Err error `json:"error"`
}

type HTTPResponse

type HTTPResponse struct {
	StatusCode int
	Header     map[string]string
	Body       interface{}
}

Jump to

Keyboard shortcuts

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