Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ComputeFnData ¶
ComputeFnData represents interpolation result for table's compute function
type ComputedFieldData ¶
type ComputedFieldData struct {
*schema.ComputedField
GoType string
}
ComputedFieldData represents interpolation result for table's compute field
type Interpolator ¶
type Interpolator struct {
Generator string
ImportPath string
TablesData []*TableData
ViewsData []*ViewData
HasExport bool
CreateDepsAll []dependencyData
DropDepsAll []dependencyData
// contains filtered or unexported fields
}
Interpolator represents interpolator struct
func NewInterpolator ¶
func NewInterpolator(baseImportPath, rootDir, defaultSchema string, ts []*schema.Table, vs []*schema.View) (*Interpolator, error)
NewInterpolator returns a new interpolator
func (Interpolator) DisplayTargets ¶
func (ip Interpolator) DisplayTargets()
DisplayTargets displays targets info to stdout
func (*Interpolator) Interpolate ¶
func (ip *Interpolator) Interpolate() error
Interpolate do interpolation based on specification files provided
type TableData ¶
type TableData struct {
*common.Names
Generator string
SpecFile string
DataSource string
CSVSeparator string
ComputePackage string
ComputePkgVar string
Fields []*FieldData
ComputedFields []*ComputedFieldData
ComputeFns []*ComputeFnData
Constraints []string
RequireSQLPkg bool
RequireStrconvPkg bool
RequireTimePkg bool
HasValidation bool
HasComputed bool
DependsOn []string
CreateDeps []dependencyData
DropDeps []dependencyData
CreateDepsIncludeTable bool
DropDepsIncludeTable bool
// contains filtered or unexported fields
}
TableData represents interpolation result for table
func (TableData) ImportPath ¶
ImportPath returns this table import path
Click to show internal directories.
Click to hide internal directories.