app

package
v0.0.0-...-204c8b9 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2022 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigAndRun

func ConfigAndRun(config *config.Config)

Configure the app and run

Types

type App

type App struct {
	Router   *mux.Router
	DBClient *mongo.Client
	DB       *mongo.Database
	// contains filtered or unexported fields
}

Structure for the app It contains the serverAddress, router, Database client, Database name and the logger

type RequestHandlerFunction

type RequestHandlerFunction func(db *mongo.Database, w http.ResponseWriter, r *http.Request)

RequestHandlerFunction is a custome type that help us to pass db arg to all endpoints

Directories

Path Synopsis
Package classification NITD Results API
Package classification NITD Results API

Jump to

Keyboard shortcuts

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