Documentation
¶
Overview ¶
Package sql2struct ... @Time : 2020/1/3 13:58 @Software: GoLand @File : init @Author : https://github.com/hsyan2008/gom
Package sql2struct ... @Time : 2020/1/7 11:04 @Software: GoLand @File : xorm_tag @Author : Bingo <airplayx@gmail.com>
Index ¶
- Variables
- func GetGormTag(table *schemas.Table, col *schemas.Column) string
- func GetJSONTag(column *schemas.Column, isOmitempty bool) string
- func GetXormTag(table *schemas.Table, col *schemas.Column) string
- func Init(db *SourceMap) (err error)
- func RmDuplicateElement(keywords []string) []string
- type GenTool
- type Model
- type ModelField
- type SQL2Struct
- type SourceMap
Constants ¶
This section is empty.
Variables ¶
View Source
var Engine *xorm.Engine
Engine ...
Functions ¶
func RmDuplicateElement ¶
RmDuplicateElement ...
Types ¶
type Model ¶
type Model struct { StructName string TableName string Imports map[string]string Fields []ModelField Comment string }
Model ...
type ModelField ¶
type ModelField struct { FieldName string ColumnName string Type string Imports map[string]string Tag string Comment string }
ModelField ...
func NewModelField ¶
NewModelField ...
type SQL2Struct ¶
type SQL2Struct struct { AutoSave bool `json:"auto_save"` JSONOmitempty bool `json:"json_omitempty"` Reflect string `json:"reflect"` SourceMap []SourceMap `json:"sourceMap"` Special string `json:"special"` Tags []string `json:"tags"` TargetDir string `json:"target_dir"` Tinyint2bool bool `json:"tinyint2bool"` }
SQL2Struct ...
Source Files
¶
Click to show internal directories.
Click to hide internal directories.