Documentation ¶
Overview ¶
nolint
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client interface { Query(query string, args ...interface{}) (*sql.Rows, error) QueryRow(query string, args ...interface{}) *sql.Row Exec(query string, args ...interface{}) (sql.Result, error) Queryx(query string, args ...interface{}) (*sqlx.Rows, error) QueryRowx(query string, args ...interface{}) *sqlx.Row Select(dest interface{}, query string, args ...interface{}) error Get(dest interface{}, query string, args ...interface{}) error NamedQuery(query string, arg interface{}) (*sqlx.Rows, error) NamedExec(query string, arg interface{}) (sql.Result, error) }
type Connector ¶
type Connector interface { Open(dsn DSN, maxConnections int) error MigrateUp(dsn DSN, migrationsProvider MigrationProvider) error Client() Client TransactionalClient() TransactionalClient Close() error }
func NewConnector ¶
func NewConnector() Connector
type MigrationProvider ¶
type MigrationProvider interface {
GetDir() http.FileSystem
}
type Transaction ¶
type TransactionalClient ¶
type TransactionalClient interface { Client BeginTransaction() (Transaction, error) }
Click to show internal directories.
Click to hide internal directories.