srv

package
v0.0.0-...-271626f Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIServer

type APIServer struct {
	Node   *node.Pegnetd
	Config *viper.Viper
}

func NewAPIServer

func NewAPIServer(conf *viper.Viper, n *node.Pegnetd) *APIServer

func (*APIServer) Start

func (s *APIServer) Start(stop <-chan struct{}) (done <-chan struct{})

Start the server in its own goroutine. If stop is closed, the server is closed and any goroutines will exit. The done channel is closed when the server exits for any reason. If the done channel is closed before the stop channel is closed, an error occurred. Errors are logged.

Jump to

Keyboard shortcuts

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