lightning-terminal/db/interfaces.go
Viktor Torstensson 03f4261714
multi: remove unused db code
As we've now switched over to using sqldb v2 for most of the db objects,
we can remove a lot of deprecated code that's no longer used in the litd
project. This commit removes that code.
2026-05-14 11:37:52 +02:00

22 lines
538 B
Go

package db
// QueriesTxOptions defines the set of db txn options the SQLQueries
// understands.
type QueriesTxOptions struct {
// readOnly governs if a read only transaction is needed or not.
readOnly bool
}
// ReadOnly returns true if the transaction should be read only.
//
// NOTE: This implements the TxOptions.
func (a *QueriesTxOptions) ReadOnly() bool {
return a.readOnly
}
// NewQueryReadTx creates a new read transaction option set.
func NewQueryReadTx() QueriesTxOptions {
return QueriesTxOptions{
readOnly: true,
}
}