Documentation
¶
Index ¶
- func DetectTypeName(n ast.Node) (str string, name string, isPtr bool, isArray bool, err error)
- func MakeForeignKeyColumns(fields []*Field) (fks map[string]dialect.ForeignKey)
- func MakeStructASTMap(filename string, marker string) (map[string]*StructAST, error)
- type Field
- type ForeignKey
- type StructAST
- type Table
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DetectTypeName ¶
func MakeForeignKeyColumns ¶
func MakeForeignKeyColumns(fields []*Field) (fks map[string]dialect.ForeignKey)
Types ¶
type Field ¶
type Field struct {
Table string
Name string
GoType string
Type string
Column string
Comment string
RawIndexes []string
RawUniques []string
PrimaryKey bool
AutoIncrement bool
Ignore bool
Default string
Extra string
Nullable bool
ForeignKey *ForeignKey
}
func MakePrimaryKeyColumns ¶
func (*Field) IsEmbedded ¶
type ForeignKey ¶
type StructAST ¶
type StructAST struct {
Name string
StructType *ast.StructType
Annotation *annotation
}
Click to show internal directories.
Click to hide internal directories.