app

package
v0.0.0-...-d1e1034 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2020 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

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

App will hold all the dependencies the application needs.

func NewApp

func NewApp(args Args) App

NewApp creates a new instance of the App, registers the routes, and returns the instance.

func (App) Close

func (app App) Close()

Close performs actions needed when the App quits.

func (App) StartServer

func (app App) StartServer(errorChan chan error, port string)

StartServer starts the HTTP server on the specified port. Any errors will be returned on the specified channel.

type Args

type Args struct {
	Router *mux.Router
	Log    *logrus.Logger
	DSN    string
}

Args holds the arguments for App.

Jump to

Keyboard shortcuts

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