// Code generated by MockGen. DO NOT EDIT.
// Source: interface.go
//
// Generated by this command:
//
//	mockgen -package sqldriver -source interface.go -destination interface_mock.go -self_package github.com/uber/cadence/common/persistence/sql/sqldriver
//

// Package sqldriver is a generated GoMock package.
package sqldriver

import (
	context "context"
	sql "database/sql"
	reflect "reflect"

	sqlx "github.com/jmoiron/sqlx"
	gomock "go.uber.org/mock/gomock"
)

// MockDriver is a mock of Driver interface.
type MockDriver struct {
	ctrl     *gomock.Controller
	recorder *MockDriverMockRecorder
	isgomock struct{}
}

// MockDriverMockRecorder is the mock recorder for MockDriver.
type MockDriverMockRecorder struct {
	mock *MockDriver
}

// NewMockDriver creates a new mock instance.
func NewMockDriver(ctrl *gomock.Controller) *MockDriver {
	mock := &MockDriver{ctrl: ctrl}
	mock.recorder = &MockDriverMockRecorder{mock}
	return mock
}

// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockDriver) EXPECT() *MockDriverMockRecorder {
	return m.recorder
}

// BeginTxx mocks base method.
func (m *MockDriver) BeginTxx(ctx context.Context, dbShardID int, opts *sql.TxOptions) (*sqlx.Tx, error) {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "BeginTxx", ctx, dbShardID, opts)
	ret0, _ := ret[0].(*sqlx.Tx)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// BeginTxx indicates an expected call of BeginTxx.
func (mr *MockDriverMockRecorder) BeginTxx(ctx, dbShardID, opts any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BeginTxx", reflect.TypeOf((*MockDriver)(nil).BeginTxx), ctx, dbShardID, opts)
}

// Close mocks base method.
func (m *MockDriver) Close() error {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "Close")
	ret0, _ := ret[0].(error)
	return ret0
}

// Close indicates an expected call of Close.
func (mr *MockDriverMockRecorder) Close() *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockDriver)(nil).Close))
}

// Commit mocks base method.
func (m *MockDriver) Commit() error {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "Commit")
	ret0, _ := ret[0].(error)
	return ret0
}

// Commit indicates an expected call of Commit.
func (mr *MockDriverMockRecorder) Commit() *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Commit", reflect.TypeOf((*MockDriver)(nil).Commit))
}

// ExecContext mocks base method.
func (m *MockDriver) ExecContext(ctx context.Context, dbShardID int, query string, args ...any) (sql.Result, error) {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "ExecContext", varargs...)
	ret0, _ := ret[0].(sql.Result)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// ExecContext indicates an expected call of ExecContext.
func (mr *MockDriverMockRecorder) ExecContext(ctx, dbShardID, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExecContext", reflect.TypeOf((*MockDriver)(nil).ExecContext), varargs...)
}

// ExecDDL mocks base method.
func (m *MockDriver) ExecDDL(ctx context.Context, dbShardID int, query string, args ...any) (sql.Result, error) {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "ExecDDL", varargs...)
	ret0, _ := ret[0].(sql.Result)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// ExecDDL indicates an expected call of ExecDDL.
func (mr *MockDriverMockRecorder) ExecDDL(ctx, dbShardID, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExecDDL", reflect.TypeOf((*MockDriver)(nil).ExecDDL), varargs...)
}

// GetContext mocks base method.
func (m *MockDriver) GetContext(ctx context.Context, dbShardID int, dest any, query string, args ...any) error {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, dest, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "GetContext", varargs...)
	ret0, _ := ret[0].(error)
	return ret0
}

// GetContext indicates an expected call of GetContext.
func (mr *MockDriverMockRecorder) GetContext(ctx, dbShardID, dest, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, dest, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetContext", reflect.TypeOf((*MockDriver)(nil).GetContext), varargs...)
}

// GetForSchemaQuery mocks base method.
func (m *MockDriver) GetForSchemaQuery(dbShardID int, dest any, query string, args ...any) error {
	m.ctrl.T.Helper()
	varargs := []any{dbShardID, dest, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "GetForSchemaQuery", varargs...)
	ret0, _ := ret[0].(error)
	return ret0
}

// GetForSchemaQuery indicates an expected call of GetForSchemaQuery.
func (mr *MockDriverMockRecorder) GetForSchemaQuery(dbShardID, dest, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{dbShardID, dest, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetForSchemaQuery", reflect.TypeOf((*MockDriver)(nil).GetForSchemaQuery), varargs...)
}

// NamedExecContext mocks base method.
func (m *MockDriver) NamedExecContext(ctx context.Context, dbShardID int, query string, arg any) (sql.Result, error) {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "NamedExecContext", ctx, dbShardID, query, arg)
	ret0, _ := ret[0].(sql.Result)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// NamedExecContext indicates an expected call of NamedExecContext.
func (mr *MockDriverMockRecorder) NamedExecContext(ctx, dbShardID, query, arg any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NamedExecContext", reflect.TypeOf((*MockDriver)(nil).NamedExecContext), ctx, dbShardID, query, arg)
}

// Rollback mocks base method.
func (m *MockDriver) Rollback() error {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "Rollback")
	ret0, _ := ret[0].(error)
	return ret0
}

// Rollback indicates an expected call of Rollback.
func (mr *MockDriverMockRecorder) Rollback() *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Rollback", reflect.TypeOf((*MockDriver)(nil).Rollback))
}

// SelectContext mocks base method.
func (m *MockDriver) SelectContext(ctx context.Context, dbShardID int, dest any, query string, args ...any) error {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, dest, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "SelectContext", varargs...)
	ret0, _ := ret[0].(error)
	return ret0
}

// SelectContext indicates an expected call of SelectContext.
func (mr *MockDriverMockRecorder) SelectContext(ctx, dbShardID, dest, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, dest, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SelectContext", reflect.TypeOf((*MockDriver)(nil).SelectContext), varargs...)
}

// SelectForSchemaQuery mocks base method.
func (m *MockDriver) SelectForSchemaQuery(dbShardID int, dest any, query string, args ...any) error {
	m.ctrl.T.Helper()
	varargs := []any{dbShardID, dest, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "SelectForSchemaQuery", varargs...)
	ret0, _ := ret[0].(error)
	return ret0
}

// SelectForSchemaQuery indicates an expected call of SelectForSchemaQuery.
func (mr *MockDriverMockRecorder) SelectForSchemaQuery(dbShardID, dest, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{dbShardID, dest, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SelectForSchemaQuery", reflect.TypeOf((*MockDriver)(nil).SelectForSchemaQuery), varargs...)
}

// MockcommonOfDbAndTx is a mock of commonOfDbAndTx interface.
type MockcommonOfDbAndTx struct {
	ctrl     *gomock.Controller
	recorder *MockcommonOfDbAndTxMockRecorder
	isgomock struct{}
}

// MockcommonOfDbAndTxMockRecorder is the mock recorder for MockcommonOfDbAndTx.
type MockcommonOfDbAndTxMockRecorder struct {
	mock *MockcommonOfDbAndTx
}

// NewMockcommonOfDbAndTx creates a new mock instance.
func NewMockcommonOfDbAndTx(ctrl *gomock.Controller) *MockcommonOfDbAndTx {
	mock := &MockcommonOfDbAndTx{ctrl: ctrl}
	mock.recorder = &MockcommonOfDbAndTxMockRecorder{mock}
	return mock
}

// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockcommonOfDbAndTx) EXPECT() *MockcommonOfDbAndTxMockRecorder {
	return m.recorder
}

// ExecContext mocks base method.
func (m *MockcommonOfDbAndTx) ExecContext(ctx context.Context, dbShardID int, query string, args ...any) (sql.Result, error) {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "ExecContext", varargs...)
	ret0, _ := ret[0].(sql.Result)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// ExecContext indicates an expected call of ExecContext.
func (mr *MockcommonOfDbAndTxMockRecorder) ExecContext(ctx, dbShardID, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExecContext", reflect.TypeOf((*MockcommonOfDbAndTx)(nil).ExecContext), varargs...)
}

// GetContext mocks base method.
func (m *MockcommonOfDbAndTx) GetContext(ctx context.Context, dbShardID int, dest any, query string, args ...any) error {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, dest, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "GetContext", varargs...)
	ret0, _ := ret[0].(error)
	return ret0
}

// GetContext indicates an expected call of GetContext.
func (mr *MockcommonOfDbAndTxMockRecorder) GetContext(ctx, dbShardID, dest, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, dest, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetContext", reflect.TypeOf((*MockcommonOfDbAndTx)(nil).GetContext), varargs...)
}

// NamedExecContext mocks base method.
func (m *MockcommonOfDbAndTx) NamedExecContext(ctx context.Context, dbShardID int, query string, arg any) (sql.Result, error) {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "NamedExecContext", ctx, dbShardID, query, arg)
	ret0, _ := ret[0].(sql.Result)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// NamedExecContext indicates an expected call of NamedExecContext.
func (mr *MockcommonOfDbAndTxMockRecorder) NamedExecContext(ctx, dbShardID, query, arg any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NamedExecContext", reflect.TypeOf((*MockcommonOfDbAndTx)(nil).NamedExecContext), ctx, dbShardID, query, arg)
}

// SelectContext mocks base method.
func (m *MockcommonOfDbAndTx) SelectContext(ctx context.Context, dbShardID int, dest any, query string, args ...any) error {
	m.ctrl.T.Helper()
	varargs := []any{ctx, dbShardID, dest, query}
	for _, a := range args {
		varargs = append(varargs, a)
	}
	ret := m.ctrl.Call(m, "SelectContext", varargs...)
	ret0, _ := ret[0].(error)
	return ret0
}

// SelectContext indicates an expected call of SelectContext.
func (mr *MockcommonOfDbAndTxMockRecorder) SelectContext(ctx, dbShardID, dest, query any, args ...any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	varargs := append([]any{ctx, dbShardID, dest, query}, args...)
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SelectContext", reflect.TypeOf((*MockcommonOfDbAndTx)(nil).SelectContext), varargs...)
}
