model

package
v1.0.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 11, 2021 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const BelongsTo = "belongsTo"

BelongsTo - belongsToMany relationship

View Source
const HasMany = "hasMany"

HasMany - hasMany relationship

View Source
const ManyToMany = "manyToMany"

ManyToMany - manyToMany relationship

Variables

View Source
var ErrInvalidRelationship = errors.New("invalid relationship")

ErrInvalidRelationship - returned when relationship is not valid

View Source
var TEMPLATE string

Functions

This section is empty.

Types

type Model

type Model struct {
	// contains filtered or unexported fields
}

Model generator

func (*Model) Generate

func (m *Model) Generate(input *parser.Parser, conf *config.Config) error

Generate generates the '{MODEL}.go' file

func (*Model) GetContent added in v1.0.11

func (m *Model) GetContent() string

GetContent content getter

func (*Model) Save added in v1.0.11

func (m *Model) Save() error

Save saves the generated content to file

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL