mysql

package
v0.0.0-...-672176f Latest Latest
Warning

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

Go to latest
Published: Dec 19, 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 Config

type Config struct {
	// contains filtered or unexported fields
}

database configs

func New

func New(opts ...func(*Config)) (*Config, error)

New returns a new Config with the given options

func (*Config) Insert

func (c *Config) Insert(record *Record) error

Insert inserts a record into the database

type Option

type Option func(c *Config)

Used to manage varidic options

func SetDSN

func SetDSN(dsn string) Option

SetDSN sets the database connection string

type Record

type Record struct {
	gorm.Model
	Record *rtl.Record `gorm:"embedded"`
}

Jump to

Keyboard shortcuts

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