2
0
mirror of https://github.com/lightninglabs/loop synced 2024-11-17 21:25:56 +00:00
loop/loopdb/sqlc/db.go

32 lines
597 B
Go
Raw Normal View History

2023-05-17 17:03:51 +00:00
// Code generated by sqlc. DO NOT EDIT.
// versions:
2024-03-20 12:57:11 +00:00
// sqlc v1.25.0
2023-05-17 17:03:51 +00:00
package sqlc
import (
"context"
"database/sql"
)
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
PrepareContext(context.Context, string) (*sql.Stmt, error)
QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
func (q *Queries) WithTx(tx *sql.Tx) *Queries {
return &Queries{
db: tx,
}
}