database

package
v1.1.16 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2024 License: MIT Imports: 4 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*sqlx.DB
}

func New

func New(ctx context.Context, driverName string, creds *Credentials, production bool) (*Client, error)

func (*Client) Check

func (d *Client) Check(ctx context.Context) error

type Credentials

type Credentials struct {
	Username string `mapstructure:"username"`
	Password string `mapstructure:"password"`
	DBName   string `mapstructure:"dbname"`
	Host     string `mapstructure:"host"`
	SSLMode  string `mapstructure:"sslmode"`
}

func (*Credentials) SourceString

func (d *Credentials) SourceString(production bool) string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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