echo

package
v0.0.0-...-ffb5472 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2017 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Option

type Option func(*Server)

Option is functional argument

func WithDebug

func WithDebug(d bool) Option

WithDebug sets the debug options of echo HTTP Server

func WithDevice

func WithDevice(d rpimonitor.Device) Option

WithDevice sets the component responsible for collecting device status. (e.g. Hardware)

func WithSampleFetcher

func WithSampleFetcher(sf rpimonitor.SampleFetcher) Option

WithSampleFetcher sets the component responsible for searching for samples.

func WithStaticDir

func WithStaticDir(d string) Option

WithStaticDir sets the static files path to the echo HTTP Server

func WithUserManager

func WithUserManager(um rpimonitor.UserManager) Option

WithUserManager sets the component for fetching and authenticating users.

type Server

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

Server is responsible to start the echo HTTP server.

func New

func New(key string, certFile string, keyFile string, options ...Option) *Server

New creates and configures a Echo HTTP Server

func (*Server) Start

func (s *Server) Start()

Start configures the echo framework and starts the HTTP server.

Jump to

Keyboard shortcuts

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