server

package
v0.0.0-...-95711e6 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Listener

type Listener struct {
	Port int
	// contains filtered or unexported fields
}

Listener handles requests to our API endpoints.

func New

func New(port int, db *database.DB, log *waterlog.WaterLog, rootDir string, errs chan error) *Listener

New creates a new HTTP listener on the given port.

func (Listener) Serve

func (l Listener) Serve()

Serve sets up our endpoint handlers and begins listening.

Jump to

Keyboard shortcuts

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