Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var LinkText string
Functions ¶
Types ¶
type ColumnModel ¶
type ColumnModel struct { Name string // 字段名 Type string // 字段类型 IsPoint bool // 是否为指针类型 Tag map[string]string // 标签 Annotation *string // 注释 }
ColumnModel 字段列参数详情
func (*ColumnModel) GeneratorFunc ¶
func (d *ColumnModel) GeneratorFunc() string
func (*ColumnModel) ToStructColumn ¶
func (d *ColumnModel) ToStructColumn() string
ToStructColumn 字段列详情转结构体字段字符串
type DescTable ¶
type DescTable struct { Field string `db:"Field"` // 字段名称 Type string `db:"Type"` // 字段类型 Null string `db:"Null"` // 是否允许为空 Key string `db:"Key"` // 是否key Default *string `db:"Default"` // 默认值 Comment *string `db:"Comment"` // 注释 }
func DescTableFunc ¶
func (*DescTable) RowToColumn ¶
func (row *DescTable) RowToColumn(hump bool) *ColumnModel
RowToColumn 字段转结构体参数 依据hump判定是否驼峰算法进而生成golang结构体
Click to show internal directories.
Click to hide internal directories.