dialer

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2022 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dialect

type Dialect interface {
	Options() *types.Options
	Tables() []*Table
	Schema() string
	ParseColumnTag(tf *TableColumn) types.Tag
	ParseColumnType(tf *TableColumn) string
}

func Mysql

func Mysql(opts *types.Options) Dialect

Mysql .

func Postgres

func Postgres(opts *types.Options) Dialect

Postgres .

type Table

type Table struct {
	TableExpand
	Columns []*TableColumn // 表字段
}

type TableColumn

type TableColumn struct {
	ColumnName string // 列名
	ColumnKey  string // 键类别
	Extra      string // 自增
	IsNull     string // NOT NULL
	DataType   string // 类型
	ColumnType string // 类型+长度
	ColumnDesc string // 注释
}

type TableExpand

type TableExpand struct {
	TableName string // 表名
	TableDesc string // 表注释
}

Jump to

Keyboard shortcuts

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