services

package
v0.0.0-...-6ed9fbc Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2021 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GracefullyShutDown

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

func NewGracefullyShutDown

func NewGracefullyShutDown(h http.Handler, address string) *GracefullyShutDown

func (*GracefullyShutDown) RunGracefully

func (r *GracefullyShutDown) RunGracefully()

type LoggerHandler

type LoggerHandler struct{}

func NewLoggerHandler

func NewLoggerHandler() *LoggerHandler

NewLogger return a Logger.

func (*LoggerHandler) LogAccess

func (*LoggerHandler) LogAccess(format string, v ...interface{})

LogAccess is print messages to log.

func (*LoggerHandler) LogError

func (*LoggerHandler) LogError(format string, v ...interface{})

LogError is print messages to log.

func (*LoggerHandler) Open

func (l *LoggerHandler) Open()

type ResponseHandler

type ResponseHandler struct{}

func NewResponseHandler

func NewResponseHandler() *ResponseHandler

func (*ResponseHandler) RespondWithAuthorized

func (rh *ResponseHandler) RespondWithAuthorized(data interface{}, w http.ResponseWriter)

func (*ResponseHandler) RespondWithBadRequest

func (rh *ResponseHandler) RespondWithBadRequest(data interface{}, w http.ResponseWriter)

func (*ResponseHandler) RespondWithInternalServerError

func (rh *ResponseHandler) RespondWithInternalServerError(data interface{}, w http.ResponseWriter)

func (*ResponseHandler) RespondWithSuccess

func (rh *ResponseHandler) RespondWithSuccess(data interface{}, w http.ResponseWriter)

func (*ResponseHandler) RespondWithUnauthorized

func (rh *ResponseHandler) RespondWithUnauthorized(data interface{}, w http.ResponseWriter)

Jump to

Keyboard shortcuts

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