Documentation
¶
Index ¶
- func PrettyPrint(prefix string, i interface{})
- type Driver
- func (p Driver) Apply(command string) error
- func (p Driver) Close() error
- func (p Driver) Connect() error
- func (p Driver) GetAppliedMigrations() ([]string, error)
- func (p Driver) GetClient() *sql.DB
- func (p Driver) GetVersion() (int, error)
- func (p Driver) InitSchema() error
- func (p Driver) PopVersion() error
- func (p Driver) PushVersion(version int) error
- type DriverConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PrettyPrint ¶
func PrettyPrint(prefix string, i interface{})
Types ¶
type Driver ¶
type Driver struct {
// contains filtered or unexported fields
}
func NewDriverWithConfig ¶
func NewDriverWithConfig(config DriverConfig) (Driver, error)
func (Driver) GetAppliedMigrations ¶
func (Driver) GetVersion ¶
func (Driver) InitSchema ¶
func (Driver) PopVersion ¶
func (Driver) PushVersion ¶
type DriverConfig ¶
type DriverConfig struct { Host string Port int Username string SSL bool Password string DatabaseName string MigrationTableName string }
func (DriverConfig) GetDSN ¶
func (p DriverConfig) GetDSN() string
func (DriverConfig) GetDriverName ¶
func (p DriverConfig) GetDriverName() string
Click to show internal directories.
Click to hide internal directories.