Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompareMigrations ¶
CompareMigrations compares two migrations and returns `true` if `left` migration is less.
Types ¶
type Migration ¶
type Migration struct {
ID string `json:"_id,omitempty"`
Version int64 `json:"version"`
Name string `json:"name"`
Up ApplyFunc `json:"-"`
Down ApplyFunc `json:"-"`
Stored bool `json:"-"`
}
Migration declares a migration data structure.
type Migrations ¶
type Migrations []Migration
Migrations type declares a slice-type of `Migration` with an implementation of `sort.Sort` interface.
func (Migrations) Len ¶
func (ms Migrations) Len() int
func (Migrations) Swap ¶
func (ms Migrations) Swap(i int, j int)
Click to show internal directories.
Click to hide internal directories.