Documentation ¶
Index ¶
Constants ¶
View Source
const ( ENGINE_UNSET = iota ENGINE_POSTGRES )
DB Engine Enum
Variables ¶
This section is empty.
Functions ¶
func CleanImports ¶
CleanImports removes extraneous imports and lines from a proto response file Content
Types ¶
type Field ¶ added in v0.5.0
type Field struct { Type string *gorm.GormFieldOptions }
type OrmPlugin ¶
type OrmPlugin struct { *generator.Generator EmptyFiles []string // contains filtered or unexported fields }
OrmPlugin implements the plugin interface and creates GORM code from .protos
func (*OrmPlugin) CleanFiles ¶ added in v0.5.0
func (p *OrmPlugin) CleanFiles(response *plugin.CodeGeneratorResponse)
CleanFiles will prevent generation of any files where no real code is generated
func (*OrmPlugin) Generate ¶
func (p *OrmPlugin) Generate(file *generator.FileDescriptor)
Generate produces the code generated by the plugin for this file, except for the imports, by calling the generator's methods P, In, and Out.
func (*OrmPlugin) GenerateImports ¶
func (p *OrmPlugin) GenerateImports(file *generator.FileDescriptor)
GenerateImports writes out required imports for the generated files
type OrmableType ¶ added in v0.5.0
func NewOrmableType ¶ added in v0.5.0
func NewOrmableType() *OrmableType
Click to show internal directories.
Click to hide internal directories.