Documentation ¶
Overview ¶
Package mimir implemenst the AST parsing and code generation
Index ¶
Constants ¶
View Source
const DBTEMPLATE = `` /* 15565-byte string literal not displayed */
DBTEMPLATE the main mart of the db source
Variables ¶
View Source
var ( //INDEXABLE is an array of type names whitch have supported lexDump INDEXABLE = map[string]string{ "int": "Int", "int8": "Int8", "int16": "Int16", "int32": "Int32", "int64": "Int64", "uint": "Uint", "uint8": "Uint8", "uint16": "Uint16", "uint32": "Uint32", "uint64": "Uint64", "float32": "Float32", "float64": "Float64", "string": "String", "rune": "Rune", "byte": "Byte", "[]rune": "Runes", "[]byte": "Bytes", "time.Time": "Time", } )
Functions ¶
This section is empty.
Types ¶
type Attr ¶
Attr is the attribute of a struct, its type and if the attribute will be indexed
func (*Attr) IsIndexable ¶
IsIndexable returns true if the attribute type has suporting lexDump
type DBGenerator ¶
DBGenerator represents the structs in file
func Parse ¶
func Parse(filename string) (*DBGenerator, error)
Parse parses the given file and returns the DBGenerator
func (DBGenerator) Generate ¶
func (gen DBGenerator) Generate(w io.Writer) error
Generate generates the db sourcecode
func (*DBGenerator) String ¶
func (gen *DBGenerator) String() string
Directories ¶
Path | Synopsis |
---|---|
test
|
|
test1
Package main genereated with github.com/microo8/mimir DO NOT MODIFY!
|
Package main genereated with github.com/microo8/mimir DO NOT MODIFY! |
test2/mypackage
Package db genereated with github.com/microo8/mimir DO NOT MODIFY!
|
Package db genereated with github.com/microo8/mimir DO NOT MODIFY! |
Click to show internal directories.
Click to hide internal directories.