server

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrorHandler

type ErrorHandler interface {
	Error(error)
}

ErrorHandler a handler for errors that can choose to exit or not if it wants, it can exit entirely

type ErrorResponse

type ErrorResponse struct {
	Response *http.Response
	Code     int    `json:"code"`
	Message  string `json:"message"`
}

type Server

type Server struct {
	Store store.DataStore
	ErrorHandler
}

Server a handler creator for an http server

func (*Server) CreateHandler

func (c *Server) CreateHandler() http.Handler

CreateHandler create an http.Handler

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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