mariadriver

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultPort = "3306"

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	User         string
	Pass         string
	Host         string
	DatabaseName string
	Port         string
	MaxLifetime  string
	MaxIdleConns string
	MaxOpenConns string
	Loc          string
}

Config is a model for connect MariaDB

func ConfigEnv

func ConfigEnv() Config

ConfigEnv for create mariadb driver

type MariaDBDriver

type MariaDBDriver interface {
	Connect() *sqlx.DB
}

MariaDBDriver is the interface

func New

func New(config Config) MariaDBDriver

New for create mariadb driver

Jump to

Keyboard shortcuts

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