Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DB ¶
type DB interface { Exec(ctx context.Context, sql string, prep PP) (sql.Result, error) Query(ctx context.Context, sql string, prep PP) (*sqlx.Rows, error) Ping(ctx context.Context) error BeginTransaction(ctx context.Context, iso sql.IsolationLevel) (Tx, error) AddListener(listener Listener) Exit() error }
type Listener ¶
type Listener interface { PrePing(ctx context.Context) error PreTxBegin(ctx context.Context, txid uint16) error PreTxCommit(txid uint16) error PreTxRollback(txid uint16) error PreQuery(ctx context.Context, txID *uint16, sql *string, params *PP) error PreExec(ctx context.Context, txID *uint16, sql *string, params *PP) error PostPing(result error) PostTxBegin(txid uint16, result error) PostTxCommit(txid uint16, result error) PostTxRollback(txid uint16, result error) PostQuery(txID *uint16, sqlOriginal string, sqlReal string, params PP) PostExec(txID *uint16, sqlOriginal string, sqlReal string, params PP) }
Click to show internal directories.
Click to hide internal directories.