fizz: github.com/gobuffalo/fizz/translators Index | Files

package translators

import "github.com/gobuffalo/fizz/translators"

Index

Package Files

cockroach.go cockroach_meta.go mariadb.go mssqlserver.go mysql.go mysql_meta.go postgres.go schema.go sqlite.go sqlite_meta.go

type Cockroach Uses

type Cockroach struct {
    Schema SchemaQuery
}

func NewCockroach Uses

func NewCockroach(url string, name string) *Cockroach

func (*Cockroach) AddColumn Uses

func (p *Cockroach) AddColumn(t fizz.Table) (string, error)

func (*Cockroach) AddForeignKey Uses

func (p *Cockroach) AddForeignKey(t fizz.Table) (string, error)

func (*Cockroach) AddIndex Uses

func (p *Cockroach) AddIndex(t fizz.Table) (string, error)

func (*Cockroach) ChangeColumn Uses

func (p *Cockroach) ChangeColumn(t fizz.Table) (string, error)

func (*Cockroach) CreateTable Uses

func (p *Cockroach) CreateTable(t fizz.Table) (string, error)

func (*Cockroach) DropColumn Uses

func (p *Cockroach) DropColumn(t fizz.Table) (string, error)

func (*Cockroach) DropForeignKey Uses

func (p *Cockroach) DropForeignKey(t fizz.Table) (string, error)

func (*Cockroach) DropIndex Uses

func (p *Cockroach) DropIndex(t fizz.Table) (string, error)

func (*Cockroach) DropTable Uses

func (p *Cockroach) DropTable(t fizz.Table) (string, error)

func (Cockroach) Name Uses

func (Cockroach) Name() string

func (*Cockroach) RenameColumn Uses

func (p *Cockroach) RenameColumn(t fizz.Table) (string, error)

func (*Cockroach) RenameIndex Uses

func (p *Cockroach) RenameIndex(t fizz.Table) (string, error)

func (*Cockroach) RenameTable Uses

func (p *Cockroach) RenameTable(t []fizz.Table) (string, error)

type MariaDB Uses

type MariaDB struct {
    *MySQL
}

MariaDB is a MariaDB-specific translator.

func NewMariaDB Uses

func NewMariaDB(url, name string) *MariaDB

NewMariaDB constructs a new MariaDB translator.

func (MariaDB) Name Uses

func (MariaDB) Name() string

type MsSqlServer Uses

type MsSqlServer struct{}

MsSqlServer is a MS SqlServer-specific translator.

func NewMsSqlServer Uses

func NewMsSqlServer() *MsSqlServer

NewMsSqlServer constructs a new MsSqlServer translator.

func (*MsSqlServer) AddColumn Uses

func (p *MsSqlServer) AddColumn(t fizz.Table) (string, error)

func (*MsSqlServer) AddForeignKey Uses

func (p *MsSqlServer) AddForeignKey(t fizz.Table) (string, error)

func (*MsSqlServer) AddIndex Uses

func (p *MsSqlServer) AddIndex(t fizz.Table) (string, error)

func (*MsSqlServer) ChangeColumn Uses

func (p *MsSqlServer) ChangeColumn(t fizz.Table) (string, error)

func (*MsSqlServer) CreateTable Uses

func (p *MsSqlServer) CreateTable(t fizz.Table) (string, error)

func (*MsSqlServer) DropColumn Uses

func (p *MsSqlServer) DropColumn(t fizz.Table) (string, error)

func (*MsSqlServer) DropForeignKey Uses

func (p *MsSqlServer) DropForeignKey(t fizz.Table) (string, error)

func (*MsSqlServer) DropIndex Uses

func (p *MsSqlServer) DropIndex(t fizz.Table) (string, error)

func (*MsSqlServer) DropTable Uses

func (p *MsSqlServer) DropTable(t fizz.Table) (string, error)

func (MsSqlServer) Name Uses

func (MsSqlServer) Name() string

func (*MsSqlServer) RenameColumn Uses

func (p *MsSqlServer) RenameColumn(t fizz.Table) (string, error)

func (*MsSqlServer) RenameIndex Uses

func (p *MsSqlServer) RenameIndex(t fizz.Table) (string, error)

func (*MsSqlServer) RenameTable Uses

func (p *MsSqlServer) RenameTable(t []fizz.Table) (string, error)

type MySQL Uses

type MySQL struct {
    Schema SchemaQuery
    // contains filtered or unexported fields
}

MySQL is a MySQL-specific translator.

func NewMySQL Uses

func NewMySQL(url, name string) *MySQL

NewMySQL constructs a new MySQL translator.

func (*MySQL) AddColumn Uses

func (p *MySQL) AddColumn(t fizz.Table) (string, error)

func (*MySQL) AddForeignKey Uses

func (p *MySQL) AddForeignKey(t fizz.Table) (string, error)

func (*MySQL) AddIndex Uses

func (p *MySQL) AddIndex(t fizz.Table) (string, error)

func (*MySQL) ChangeColumn Uses

func (p *MySQL) ChangeColumn(t fizz.Table) (string, error)

func (*MySQL) CreateTable Uses

func (p *MySQL) CreateTable(t fizz.Table) (string, error)

CreateTable translates a fizz Table to its MySQL SQL definition.

func (*MySQL) DropColumn Uses

func (p *MySQL) DropColumn(t fizz.Table) (string, error)

func (*MySQL) DropForeignKey Uses

func (p *MySQL) DropForeignKey(t fizz.Table) (string, error)

func (*MySQL) DropIndex Uses

func (p *MySQL) DropIndex(t fizz.Table) (string, error)

func (*MySQL) DropTable Uses

func (p *MySQL) DropTable(t fizz.Table) (string, error)

func (MySQL) Name Uses

func (MySQL) Name() string

func (*MySQL) RenameColumn Uses

func (p *MySQL) RenameColumn(t fizz.Table) (string, error)

func (*MySQL) RenameIndex Uses

func (p *MySQL) RenameIndex(t fizz.Table) (string, error)

func (*MySQL) RenameTable Uses

func (p *MySQL) RenameTable(t []fizz.Table) (string, error)

type Postgres Uses

type Postgres struct {
}

func NewPostgres Uses

func NewPostgres() *Postgres

func (*Postgres) AddColumn Uses

func (p *Postgres) AddColumn(t fizz.Table) (string, error)

func (*Postgres) AddForeignKey Uses

func (p *Postgres) AddForeignKey(t fizz.Table) (string, error)

func (*Postgres) AddIndex Uses

func (p *Postgres) AddIndex(t fizz.Table) (string, error)

func (*Postgres) ChangeColumn Uses

func (p *Postgres) ChangeColumn(t fizz.Table) (string, error)

func (*Postgres) CreateTable Uses

func (p *Postgres) CreateTable(t fizz.Table) (string, error)

func (*Postgres) DropColumn Uses

func (p *Postgres) DropColumn(t fizz.Table) (string, error)

func (*Postgres) DropForeignKey Uses

func (p *Postgres) DropForeignKey(t fizz.Table) (string, error)

func (*Postgres) DropIndex Uses

func (p *Postgres) DropIndex(t fizz.Table) (string, error)

func (*Postgres) DropTable Uses

func (p *Postgres) DropTable(t fizz.Table) (string, error)

func (Postgres) Name Uses

func (Postgres) Name() string

func (*Postgres) RenameColumn Uses

func (p *Postgres) RenameColumn(t fizz.Table) (string, error)

func (*Postgres) RenameIndex Uses

func (p *Postgres) RenameIndex(t fizz.Table) (string, error)

func (*Postgres) RenameTable Uses

func (p *Postgres) RenameTable(t []fizz.Table) (string, error)

type SQLite Uses

type SQLite struct {
    Schema SchemaQuery
}

func NewSQLite Uses

func NewSQLite(url string) *SQLite

func (*SQLite) AddColumn Uses

func (p *SQLite) AddColumn(t fizz.Table) (string, error)

func (*SQLite) AddForeignKey Uses

func (p *SQLite) AddForeignKey(t fizz.Table) (string, error)

func (*SQLite) AddIndex Uses

func (p *SQLite) AddIndex(t fizz.Table) (string, error)

func (*SQLite) ChangeColumn Uses

func (p *SQLite) ChangeColumn(t fizz.Table) (string, error)

func (*SQLite) CreateTable Uses

func (p *SQLite) CreateTable(t fizz.Table) (string, error)

func (*SQLite) DropColumn Uses

func (p *SQLite) DropColumn(t fizz.Table) (string, error)

func (*SQLite) DropForeignKey Uses

func (p *SQLite) DropForeignKey(t fizz.Table) (string, error)

func (*SQLite) DropIndex Uses

func (p *SQLite) DropIndex(t fizz.Table) (string, error)

func (*SQLite) DropTable Uses

func (p *SQLite) DropTable(t fizz.Table) (string, error)

func (SQLite) Name Uses

func (SQLite) Name() string

func (*SQLite) RenameColumn Uses

func (p *SQLite) RenameColumn(t fizz.Table) (string, error)

func (*SQLite) RenameIndex Uses

func (p *SQLite) RenameIndex(t fizz.Table) (string, error)

func (*SQLite) RenameTable Uses

func (p *SQLite) RenameTable(t []fizz.Table) (string, error)

type Schema Uses

type Schema struct {
    Builder SchemaQuery
    Name    string
    URL     string
    // contains filtered or unexported fields
}

func CreateSchema Uses

func CreateSchema(name string, url string, schema map[string]*fizz.Table) Schema

func (*Schema) Build Uses

func (s *Schema) Build() error

func (*Schema) ColumnInfo Uses

func (s *Schema) ColumnInfo(table string, column string) (*fizz.Column, error)

func (*Schema) Delete Uses

func (s *Schema) Delete(table string)

func (*Schema) DeleteColumn Uses

func (s *Schema) DeleteColumn(table string, column string)

func (*Schema) IndexInfo Uses

func (s *Schema) IndexInfo(table string, idx string) (*fizz.Index, error)

func (*Schema) ReplaceColumn Uses

func (s *Schema) ReplaceColumn(table string, oldColumn string, newColumn fizz.Column) error

func (*Schema) ReplaceSchema Uses

func (s *Schema) ReplaceSchema(newSchema map[string]*fizz.Table)

func (*Schema) SetTable Uses

func (s *Schema) SetTable(table *fizz.Table)

func (*Schema) TableInfo Uses

func (s *Schema) TableInfo(table string) (*fizz.Table, error)

type SchemaQuery Uses

type SchemaQuery interface {
    ReplaceSchema(map[string]*fizz.Table)
    Build() error
    TableInfo(string) (*fizz.Table, error)
    ReplaceColumn(table string, oldColumn string, newColumn fizz.Column) error
    ColumnInfo(table string, column string) (*fizz.Column, error)
    IndexInfo(table string, idx string) (*fizz.Index, error)
    Delete(string)
    SetTable(*fizz.Table)
    DeleteColumn(string, string)
}

Package translators imports 6 packages (graph) and is imported by 3 packages. Updated 2019-09-13. Refresh now. Tools for package owners.