db

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2018 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DefaultKey todo
	DefaultKey = "db_connection_key"
)

Variables

This section is empty.

Functions

func DatabaseMiddleware

func DatabaseMiddleware(db *sql.DB) echo.MiddlewareFunc

DatabaseMiddleware todo

func Default

func Default(ctx echo.Context) *sql.DB

Default todo

func InjectDB

func InjectDB() *sql.DB

InjectDB todo

func NewDB

func NewDB(config *NewDBConfig) (*sql.DB, error)

NewDB todo

Types

type NewDBConfig

type NewDBConfig struct {
	Host     string
	Port     string
	User     string
	Password string
	Database string
	SSLMode  string
}

NewDBConfig todo

Jump to

Keyboard shortcuts

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