server

package
v0.0.2-0...-fcdf84f Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2020 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	Port   string
	Router *httprouter.Router
	DB     *sql.DB
}

Server is a struct responsible for managing a *httprouter.Router. All HandlerFunc Closures hang off of this struct, so all HandlerFunc's have access to the server values.

func (*Server) Start

func (s *Server) Start()

Start binds all routes to our router and then serves our router to handle all requests on incoming connections.

Jump to

Keyboard shortcuts

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