Documentation
¶
Index ¶
- Constants
- type Field
- type OrmPlugin
- func (p *OrmPlugin) Execute(targets map[string]pgs.File, pkgs map[string]pgs.Package) []pgs.Artifact
- func (p *OrmPlugin) InitContext(c pgs.BuildContext)
- func (p *OrmPlugin) IsAbleToMakePQArray(fieldType string) bool
- func (p *OrmPlugin) Name() string
- func (p *OrmPlugin) P(parts ...string)
- func (p *OrmPlugin) TypeName(msg pgs.Message) string
- type OrmableType
Constants ¶
View Source
const ( ENGINE_UNSET = iota ENGINE_POSTGRES )
DB Engine Enum
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OrmPlugin ¶
type OrmPlugin struct { // *generator.Generator *pgs.ModuleBase EmptyFiles []string // contains filtered or unexported fields }
OrmPlugin implements the plugin interface and creates GORM code from .protos
func (*OrmPlugin) InitContext ¶ added in v0.21.0
func (p *OrmPlugin) InitContext(c pgs.BuildContext)
Init is called once after data structures are built but before code generation begins.
func (*OrmPlugin) IsAbleToMakePQArray ¶ added in v0.21.0
IsAbleToMakePQArray tells us if the specific field-type can automatically be turned into a PQ array:
type OrmableType ¶ added in v0.5.0
type OrmableType struct { OriginName string Name string // Package string File pgs.File Fields map[string]*Field FieldsOrder []string }
func NewOrmableType ¶ added in v0.5.0
func NewOrmableType(oname string, file pgs.File) *OrmableType
Click to show internal directories.
Click to hide internal directories.