Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Generator ¶
type Generator struct {
Version string
Revision string
BuildDate string
BuiltBy string
// contains filtered or unexported fields
}
Generator is responsible for generating validation files for the given in a go source file.
func (*Generator) GenerateFromFile ¶
GenerateFromFile is responsible for orchestrating the Code generation. It results in a byte array that can be written to any file desired.
func (*Generator) WithBuildTags ¶
WithBuildTags will add build tags to the generated file.
type Struct ¶
type Struct struct {
Name string
Views []string
Fields []StructField
}
Struct describes one struct
func NewStructList ¶
NewStructList creates a list of Struct from the provided ast.File node.
type StructField ¶
StructField describes one field on struct
Click to show internal directories.
Click to hide internal directories.