mfile

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	Source  string
	RunType string

	Vars []Variable

	Conn db.Config

	Instances []Instance

	Idxes map[string]int
	// contains filtered or unexported fields
}

func Parse

func Parse(lines []string, model string) (*File, error)

func (*File) GetConfig

func (f *File) GetConfig(key string) string

func (*File) NewRunner

func (f *File) NewRunner(externalStr string) (*Runner, error)

type Instance

type Instance struct {
	Name       string
	Num        *mrule.Iterator
	FieldNames []string
	FieldIters []*mrule.Iterator
}

type Runner

type Runner struct {
	Vars      map[string]interface{}
	Externals map[string]string
	Idxes     map[string]int

	Instances []Instance
}

func (*Runner) RunSql

func (r *Runner) RunSql(prepare bool) ([]sqlutil.BuildResult, error)

type SqlEpochHandler

type SqlEpochHandler func(epoch []sqlutil.BuildResult, meta *mrule.EpochMeta) error

type Variable

type Variable struct {
	Name string
	Iter *mrule.Iterator
}

Jump to

Keyboard shortcuts

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