changelog

package
v0.0.0-...-82233a1 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2024 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

You can use the "packr clean" command to clean up this, and any other packr generated files.

Index

Constants

View Source
const (
	PrimaryTemplate = `` /* 204-byte string literal not displayed */

	BigintTemplate = `` /* 174-byte string literal not displayed */

	TinyIntTemplate = `` /* 175-byte string literal not displayed */

	SmallIntTemplate = `` /* 176-byte string literal not displayed */

	MediumIntTemplate = `` /* 177-byte string literal not displayed */

	IntTemplate = `` /* 171-byte string literal not displayed */

	FloatTemplate = `` /* 173-byte string literal not displayed */

	DoubleColumn = `` /* 174-byte string literal not displayed */

	DecimalTemplate = `` /* 207-byte string literal not displayed */

	CharTemplate = `` /* 191-byte string literal not displayed */

	VarcharTemplate = `` /* 194-byte string literal not displayed */

	TextTemplate = `` /* 152-byte string literal not displayed */

	DateTemplate = `` /* 172-byte string literal not displayed */

	TimeTemplate = `` /* 172-byte string literal not displayed */

	DatetimeTemplate = `` /* 176-byte string literal not displayed */

	TimestampTemplate = `` /* 177-byte string literal not displayed */

	UpdateTimestampTemplate = `` /* 218-byte string literal not displayed */

)
View Source
const (
	FixedNameTemplate = "template_employee_1.0.0"
	DatetimeLayout    = "20060102"
	TmplSuffix        = ".tmpl"
)
View Source
const (
	EmptyString = ""
)
View Source
const (
	VersionTemplate = "1.0.0"
)

Variables

This section is empty.

Functions

func OnDatabaseMode

func OnDatabaseMode(args *Args)

func OnSQLMode

func OnSQLMode(args *Args)

Types

type Args

type Args struct {
	Author  string
	Email   string
	Version string
	Cwd     string
	Path    string

	Host     string
	Port     int
	Username string
	Password string
	Dialect  string
	Database string

	Format string

	SQLFile string
	SQL     string
	Ast     *ast.Ast
}

type Column

type Column struct {
	Name         string
	Type         string
	Comment      string
	DefaultValue string

	AutoIncrement   bool
	Nullable        bool
	UpdateTimestamp bool

	TypeLength int
	Precision  int
	Scale      int

	PrimaryColumn string
	BigintColumn  string

	TinyIntColumn   string
	SmallIntColumn  string
	MediumIntColumn string
	IntColumn       string

	FloatColumn   string
	DoubleColumn  string
	DecimalColumn string

	CharColumn    string
	VarcharColumn string
	TextColumn    string

	DateColumn     string
	TimeColumn     string
	DatetimeColumn string

	TimestampColumn       string
	UpdateTimestampColumn string

	Dialect  string
	MySQL    string
	Postgres string
	SQLite   string
}

type Context

type Context struct {
	Author  string
	Version string
	Date    string

	Dialect  string
	MySQL    string
	Postgres string
	SQLite   string

	Cwd  string
	Path string

	*Table
}

func NewContext

func NewContext() *Context

type Index

type Index struct {
	Name    string
	Columns []string
}

type Table

type Table struct {
	Name    string
	Comment string

	Columns []*Column
	Indexes []*Index
}

Directories

Path Synopsis
You can use the "packr2 clean" command to clean up this, and any other packr generated files.
You can use the "packr2 clean" command to clean up this, and any other packr generated files.

Jump to

Keyboard shortcuts

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