This repository has been archived on 2025-03-30. You can view files and clone it, but cannot push or open issues or pull requests.
bactdb/Godeps/_workspace/src/github.com/DavidHuie/gomigrate/migration.go
2015-01-27 16:39:04 -09:00

26 lines
468 B
Go

// Holds metadata about a migration.
package gomigrate
// Migration statuses.
const (
Inactive = iota
Active
)
// Holds configuration information for a given migration.
type Migration struct {
DownPath string
Id uint64
Name string
Status int
UpPath string
}
// Performs a basic validation of a migration.
func (m *Migration) valid() bool {
if m.Id != 0 && m.Name != "" && m.UpPath != "" && m.DownPath != "" {
return true
}
return false
}