vegeMysql

package
v1.0.6 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MysqlDSN

type MysqlDSN struct {
	Dsn      string
	Type     string //deprecated
	Username string
	Password string
	Protocol string
	Address  string
	Database string
	Params   map[string]string
}

func NewDefaultMysqlDsn

func NewDefaultMysqlDsn(ops ...MysqlDsnOptionFunc) *MysqlDSN

func ParseMysqlDSN

func ParseMysqlDSN(s string) *MysqlDSN

Turns a MysqlDSN string into a parsed MysqlDSN struct.

func (*MysqlDSN) String

func (d *MysqlDSN) String() string

Converts a MysqlDSN struct into its string representation.

type MysqlDsnOptionFunc

type MysqlDsnOptionFunc func(dsn *MysqlDSN)

func WithAddress

func WithAddress(addr string) MysqlDsnOptionFunc

func WithAuth

func WithAuth(u string, pswd string) MysqlDsnOptionFunc

func WithDatabase

func WithDatabase(dbname string) MysqlDsnOptionFunc

Jump to

Keyboard shortcuts

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