Add executor interface

master
Nick Krichevsky 2019-03-18 22:33:37 -04:00
parent 7ce90c3673
commit 19b591e48b
1 changed files with 10 additions and 0 deletions

10
repository/executor.go Normal file
View File

@ -0,0 +1,10 @@
package repository
import "database/sql"
// executor allows for the execution of various database functions
type executor interface {
Exec(query string, args ...interface{}) (sql.Result, error)
Query(query string, args ...interface{}) (*sql.Rows, error)
QueryRow(query string, args ...interface{}) *sql.Row
}