Documentation ¶
Index ¶
Constants ¶
View Source
const ( Invalid = iota Bool Int Int8 Int16 Int32 Int64 Uint Uint8 Uint16 Uint32 Uint64 Float32 Float64 Complex64 Complex128 Interface Bytes Map Ptr String Slice Struct )
View Source
const ( EncodeGzip = "gzip" EncodeJson = "json" )
Variables ¶
View Source
var ( ErrTypeNotFound = errors.New("Cannot find type in the source code.") ErrTypeInvalid = errors.New("Cannot convert type to a SQL type.") )
View Source
var Types = map[string]uint8{ "bool": Bool, "int": Int, "int8": Int8, "int16": Int16, "int32": Int32, "int64": Int64, "uint": Uint, "uint8": Uint8, "uint16": Uint16, "uint32": Uint32, "uint64": Uint64, "float32": Float32, "float64": Float64, "complex64": Complex64, "complex128": Complex128, "interface{}": Interface, "[]byte": Bytes, "string": String, }
Functions ¶
This section is empty.
Types ¶
type Node ¶
type Node struct { Pkg string // source code package. Name string // source code name. Kind uint8 // source code kind. Type string // source code type. Tags *Tag Parent *Node Nodes []*Node }
type Tag ¶
type Tag struct { Name string `yaml:"name"` Type string `yaml:"type"` Primary bool `yaml:"pk"` Auto bool `yaml:"auto"` Index string `yaml:"index"` Unique string `yaml:"unique"` Size int `yaml:"size"` Skip bool `yaml:"skip"` Encode string `yaml:"encode"` }
Tag stores the parsed data from the tag string in a struct field.
Click to show internal directories.
Click to hide internal directories.