migration

package
v0.0.0-...-6e5bb36 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2021 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IMigration

type IMigration interface {
	Up(string) error
	Down(string) error
	Create(string, string) error
}

IMigration ...

func New

func New(opts ...Option) IMigration

New ...

type Migration

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

Migration ...

func (*Migration) Create

func (migration *Migration) Create(name string, ext string) (err error)

Create ...

func (*Migration) Down

func (migration *Migration) Down(dialect string) (err error)

Down ...

func (*Migration) Up

func (migration *Migration) Up(dialect string) (err error)

Up ...

type Option

type Option func(*Migration)

Option ...

func WithDatabase

func WithDatabase(dialect string, conn *gorm.DB) Option

WithDatabase ...

Jump to

Keyboard shortcuts

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