Files
zitadel/backend/v3/domain/mock/session.mock.go
T
Livio SpringandGitHub 4e6f68c511 feat(relational): implement session repository (#11109)
# Which Problems Are Solved

As part of going to a relation storage model, we need to implement the
repository for handling sessions and their events.

# How the Problems Are Solved

- Adds a migration step to create the necessary tables and types in the
database.
- Adds the repository implementation for sessions.
- Implements a projection handler for session events to handle the
events written by the old command handlers.
- Updates the `Session` type and `SessionRepository` interface:
  - added `CreatorID`
  - Adjusted `Delete` method to return amount of affected columns
  - Removed sub-repository clumns from the main interface
- Added `CreatorIDCondition`, `ExpirationCondition`, `ExistsFactor` and
`ExistsMetadata`
  - Removed `SetUserAgent`
- Methods of `SessionFactor` and `SessionChallenge` have been made
public
- fixed enumer on `SessionFactorType`
- Adds a `JSON` type to the repository package to easy can JSON columns,
resp. jsonb object inside a property of a `JSONArray` object.
- Adds a `NoChange` interface, which can be implemented to signal that a
`Change` interface implementation is not writing any changes to the
statement builder, e.g. `CTEChange`

# Additional Changes

- Fixes the operators enums. `TextOperations` had wrong comments and
`NumberOperations` additionally also had from comparisons.
- Fixes downgrade of migration step 008.

# Additional Context

- closes https://github.com/zitadel/zitadel/issues/10212
2026-01-06 08:08:11 +01:00

1355 lines
49 KiB
Go

// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/zitadel/zitadel/backend/v3/domain (interfaces: SessionRepository)
//
// Generated by this command:
//
// mockgen -typed -package domainmock -destination ./mock/session.mock.go . SessionRepository
//
// Package domainmock is a generated GoMock package.
package domainmock
import (
context "context"
reflect "reflect"
time "time"
domain "github.com/zitadel/zitadel/backend/v3/domain"
database "github.com/zitadel/zitadel/backend/v3/storage/database"
gomock "go.uber.org/mock/gomock"
)
// MockSessionRepository is a mock of SessionRepository interface.
type MockSessionRepository struct {
ctrl *gomock.Controller
recorder *MockSessionRepositoryMockRecorder
}
// MockSessionRepositoryMockRecorder is the mock recorder for MockSessionRepository.
type MockSessionRepositoryMockRecorder struct {
mock *MockSessionRepository
}
// NewMockSessionRepository creates a new mock instance.
func NewMockSessionRepository(ctrl *gomock.Controller) *MockSessionRepository {
mock := &MockSessionRepository{ctrl: ctrl}
mock.recorder = &MockSessionRepositoryMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockSessionRepository) EXPECT() *MockSessionRepositoryMockRecorder {
return m.recorder
}
// ClearFactor mocks base method.
func (m *MockSessionRepository) ClearFactor(arg0 domain.SessionFactorType) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ClearFactor", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// ClearFactor indicates an expected call of ClearFactor.
func (mr *MockSessionRepositoryMockRecorder) ClearFactor(arg0 any) *MockSessionRepositoryClearFactorCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ClearFactor", reflect.TypeOf((*MockSessionRepository)(nil).ClearFactor), arg0)
return &MockSessionRepositoryClearFactorCall{Call: call}
}
// MockSessionRepositoryClearFactorCall wrap *gomock.Call
type MockSessionRepositoryClearFactorCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryClearFactorCall) Return(arg0 database.Change) *MockSessionRepositoryClearFactorCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryClearFactorCall) Do(f func(domain.SessionFactorType) database.Change) *MockSessionRepositoryClearFactorCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryClearFactorCall) DoAndReturn(f func(domain.SessionFactorType) database.Change) *MockSessionRepositoryClearFactorCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// Create mocks base method.
func (m *MockSessionRepository) Create(arg0 context.Context, arg1 database.QueryExecutor, arg2 *domain.Session) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Create", arg0, arg1, arg2)
ret0, _ := ret[0].(error)
return ret0
}
// Create indicates an expected call of Create.
func (mr *MockSessionRepositoryMockRecorder) Create(arg0, arg1, arg2 any) *MockSessionRepositoryCreateCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Create", reflect.TypeOf((*MockSessionRepository)(nil).Create), arg0, arg1, arg2)
return &MockSessionRepositoryCreateCall{Call: call}
}
// MockSessionRepositoryCreateCall wrap *gomock.Call
type MockSessionRepositoryCreateCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryCreateCall) Return(arg0 error) *MockSessionRepositoryCreateCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryCreateCall) Do(f func(context.Context, database.QueryExecutor, *domain.Session) error) *MockSessionRepositoryCreateCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryCreateCall) DoAndReturn(f func(context.Context, database.QueryExecutor, *domain.Session) error) *MockSessionRepositoryCreateCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// CreatedAtColumn mocks base method.
func (m *MockSessionRepository) CreatedAtColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CreatedAtColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// CreatedAtColumn indicates an expected call of CreatedAtColumn.
func (mr *MockSessionRepositoryMockRecorder) CreatedAtColumn() *MockSessionRepositoryCreatedAtColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreatedAtColumn", reflect.TypeOf((*MockSessionRepository)(nil).CreatedAtColumn))
return &MockSessionRepositoryCreatedAtColumnCall{Call: call}
}
// MockSessionRepositoryCreatedAtColumnCall wrap *gomock.Call
type MockSessionRepositoryCreatedAtColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryCreatedAtColumnCall) Return(arg0 database.Column) *MockSessionRepositoryCreatedAtColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryCreatedAtColumnCall) Do(f func() database.Column) *MockSessionRepositoryCreatedAtColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryCreatedAtColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryCreatedAtColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// CreatedAtCondition mocks base method.
func (m *MockSessionRepository) CreatedAtCondition(arg0 database.NumberOperation, arg1 time.Time) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CreatedAtCondition", arg0, arg1)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// CreatedAtCondition indicates an expected call of CreatedAtCondition.
func (mr *MockSessionRepositoryMockRecorder) CreatedAtCondition(arg0, arg1 any) *MockSessionRepositoryCreatedAtConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreatedAtCondition", reflect.TypeOf((*MockSessionRepository)(nil).CreatedAtCondition), arg0, arg1)
return &MockSessionRepositoryCreatedAtConditionCall{Call: call}
}
// MockSessionRepositoryCreatedAtConditionCall wrap *gomock.Call
type MockSessionRepositoryCreatedAtConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryCreatedAtConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryCreatedAtConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryCreatedAtConditionCall) Do(f func(database.NumberOperation, time.Time) database.Condition) *MockSessionRepositoryCreatedAtConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryCreatedAtConditionCall) DoAndReturn(f func(database.NumberOperation, time.Time) database.Condition) *MockSessionRepositoryCreatedAtConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// CreatorIDCondition mocks base method.
func (m *MockSessionRepository) CreatorIDCondition(arg0 string) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CreatorIDCondition", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// CreatorIDCondition indicates an expected call of CreatorIDCondition.
func (mr *MockSessionRepositoryMockRecorder) CreatorIDCondition(arg0 any) *MockSessionRepositoryCreatorIDConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreatorIDCondition", reflect.TypeOf((*MockSessionRepository)(nil).CreatorIDCondition), arg0)
return &MockSessionRepositoryCreatorIDConditionCall{Call: call}
}
// MockSessionRepositoryCreatorIDConditionCall wrap *gomock.Call
type MockSessionRepositoryCreatorIDConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryCreatorIDConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryCreatorIDConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryCreatorIDConditionCall) Do(f func(string) database.Condition) *MockSessionRepositoryCreatorIDConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryCreatorIDConditionCall) DoAndReturn(f func(string) database.Condition) *MockSessionRepositoryCreatorIDConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// Delete mocks base method.
func (m *MockSessionRepository) Delete(arg0 context.Context, arg1 database.QueryExecutor, arg2 database.Condition) (int64, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Delete", arg0, arg1, arg2)
ret0, _ := ret[0].(int64)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Delete indicates an expected call of Delete.
func (mr *MockSessionRepositoryMockRecorder) Delete(arg0, arg1, arg2 any) *MockSessionRepositoryDeleteCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockSessionRepository)(nil).Delete), arg0, arg1, arg2)
return &MockSessionRepositoryDeleteCall{Call: call}
}
// MockSessionRepositoryDeleteCall wrap *gomock.Call
type MockSessionRepositoryDeleteCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryDeleteCall) Return(arg0 int64, arg1 error) *MockSessionRepositoryDeleteCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryDeleteCall) Do(f func(context.Context, database.QueryExecutor, database.Condition) (int64, error)) *MockSessionRepositoryDeleteCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryDeleteCall) DoAndReturn(f func(context.Context, database.QueryExecutor, database.Condition) (int64, error)) *MockSessionRepositoryDeleteCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// ExistsFactor mocks base method.
func (m *MockSessionRepository) ExistsFactor(arg0 database.Condition) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ExistsFactor", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// ExistsFactor indicates an expected call of ExistsFactor.
func (mr *MockSessionRepositoryMockRecorder) ExistsFactor(arg0 any) *MockSessionRepositoryExistsFactorCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExistsFactor", reflect.TypeOf((*MockSessionRepository)(nil).ExistsFactor), arg0)
return &MockSessionRepositoryExistsFactorCall{Call: call}
}
// MockSessionRepositoryExistsFactorCall wrap *gomock.Call
type MockSessionRepositoryExistsFactorCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryExistsFactorCall) Return(arg0 database.Condition) *MockSessionRepositoryExistsFactorCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryExistsFactorCall) Do(f func(database.Condition) database.Condition) *MockSessionRepositoryExistsFactorCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryExistsFactorCall) DoAndReturn(f func(database.Condition) database.Condition) *MockSessionRepositoryExistsFactorCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// ExistsMetadata mocks base method.
func (m *MockSessionRepository) ExistsMetadata(arg0 database.Condition) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ExistsMetadata", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// ExistsMetadata indicates an expected call of ExistsMetadata.
func (mr *MockSessionRepositoryMockRecorder) ExistsMetadata(arg0 any) *MockSessionRepositoryExistsMetadataCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExistsMetadata", reflect.TypeOf((*MockSessionRepository)(nil).ExistsMetadata), arg0)
return &MockSessionRepositoryExistsMetadataCall{Call: call}
}
// MockSessionRepositoryExistsMetadataCall wrap *gomock.Call
type MockSessionRepositoryExistsMetadataCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryExistsMetadataCall) Return(arg0 database.Condition) *MockSessionRepositoryExistsMetadataCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryExistsMetadataCall) Do(f func(database.Condition) database.Condition) *MockSessionRepositoryExistsMetadataCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryExistsMetadataCall) DoAndReturn(f func(database.Condition) database.Condition) *MockSessionRepositoryExistsMetadataCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// ExpirationColumn mocks base method.
func (m *MockSessionRepository) ExpirationColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ExpirationColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// ExpirationColumn indicates an expected call of ExpirationColumn.
func (mr *MockSessionRepositoryMockRecorder) ExpirationColumn() *MockSessionRepositoryExpirationColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExpirationColumn", reflect.TypeOf((*MockSessionRepository)(nil).ExpirationColumn))
return &MockSessionRepositoryExpirationColumnCall{Call: call}
}
// MockSessionRepositoryExpirationColumnCall wrap *gomock.Call
type MockSessionRepositoryExpirationColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryExpirationColumnCall) Return(arg0 database.Column) *MockSessionRepositoryExpirationColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryExpirationColumnCall) Do(f func() database.Column) *MockSessionRepositoryExpirationColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryExpirationColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryExpirationColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// ExpirationCondition mocks base method.
func (m *MockSessionRepository) ExpirationCondition(arg0 database.NumberOperation, arg1 time.Time) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ExpirationCondition", arg0, arg1)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// ExpirationCondition indicates an expected call of ExpirationCondition.
func (mr *MockSessionRepositoryMockRecorder) ExpirationCondition(arg0, arg1 any) *MockSessionRepositoryExpirationConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ExpirationCondition", reflect.TypeOf((*MockSessionRepository)(nil).ExpirationCondition), arg0, arg1)
return &MockSessionRepositoryExpirationConditionCall{Call: call}
}
// MockSessionRepositoryExpirationConditionCall wrap *gomock.Call
type MockSessionRepositoryExpirationConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryExpirationConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryExpirationConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryExpirationConditionCall) Do(f func(database.NumberOperation, time.Time) database.Condition) *MockSessionRepositoryExpirationConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryExpirationConditionCall) DoAndReturn(f func(database.NumberOperation, time.Time) database.Condition) *MockSessionRepositoryExpirationConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// FactorConditions mocks base method.
func (m *MockSessionRepository) FactorConditions() domain.SessionFactorConditions {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FactorConditions")
ret0, _ := ret[0].(domain.SessionFactorConditions)
return ret0
}
// FactorConditions indicates an expected call of FactorConditions.
func (mr *MockSessionRepositoryMockRecorder) FactorConditions() *MockSessionRepositoryFactorConditionsCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FactorConditions", reflect.TypeOf((*MockSessionRepository)(nil).FactorConditions))
return &MockSessionRepositoryFactorConditionsCall{Call: call}
}
// MockSessionRepositoryFactorConditionsCall wrap *gomock.Call
type MockSessionRepositoryFactorConditionsCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryFactorConditionsCall) Return(arg0 domain.SessionFactorConditions) *MockSessionRepositoryFactorConditionsCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryFactorConditionsCall) Do(f func() domain.SessionFactorConditions) *MockSessionRepositoryFactorConditionsCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryFactorConditionsCall) DoAndReturn(f func() domain.SessionFactorConditions) *MockSessionRepositoryFactorConditionsCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// Get mocks base method.
func (m *MockSessionRepository) Get(arg0 context.Context, arg1 database.QueryExecutor, arg2 ...database.QueryOption) (*domain.Session, error) {
m.ctrl.T.Helper()
varargs := []any{arg0, arg1}
for _, a := range arg2 {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "Get", varargs...)
ret0, _ := ret[0].(*domain.Session)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Get indicates an expected call of Get.
func (mr *MockSessionRepositoryMockRecorder) Get(arg0, arg1 any, arg2 ...any) *MockSessionRepositoryGetCall {
mr.mock.ctrl.T.Helper()
varargs := append([]any{arg0, arg1}, arg2...)
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockSessionRepository)(nil).Get), varargs...)
return &MockSessionRepositoryGetCall{Call: call}
}
// MockSessionRepositoryGetCall wrap *gomock.Call
type MockSessionRepositoryGetCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryGetCall) Return(arg0 *domain.Session, arg1 error) *MockSessionRepositoryGetCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryGetCall) Do(f func(context.Context, database.QueryExecutor, ...database.QueryOption) (*domain.Session, error)) *MockSessionRepositoryGetCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryGetCall) DoAndReturn(f func(context.Context, database.QueryExecutor, ...database.QueryOption) (*domain.Session, error)) *MockSessionRepositoryGetCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// IDColumn mocks base method.
func (m *MockSessionRepository) IDColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "IDColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// IDColumn indicates an expected call of IDColumn.
func (mr *MockSessionRepositoryMockRecorder) IDColumn() *MockSessionRepositoryIDColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IDColumn", reflect.TypeOf((*MockSessionRepository)(nil).IDColumn))
return &MockSessionRepositoryIDColumnCall{Call: call}
}
// MockSessionRepositoryIDColumnCall wrap *gomock.Call
type MockSessionRepositoryIDColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryIDColumnCall) Return(arg0 database.Column) *MockSessionRepositoryIDColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryIDColumnCall) Do(f func() database.Column) *MockSessionRepositoryIDColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryIDColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryIDColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// IDCondition mocks base method.
func (m *MockSessionRepository) IDCondition(arg0 string) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "IDCondition", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// IDCondition indicates an expected call of IDCondition.
func (mr *MockSessionRepositoryMockRecorder) IDCondition(arg0 any) *MockSessionRepositoryIDConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IDCondition", reflect.TypeOf((*MockSessionRepository)(nil).IDCondition), arg0)
return &MockSessionRepositoryIDConditionCall{Call: call}
}
// MockSessionRepositoryIDConditionCall wrap *gomock.Call
type MockSessionRepositoryIDConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryIDConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryIDConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryIDConditionCall) Do(f func(string) database.Condition) *MockSessionRepositoryIDConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryIDConditionCall) DoAndReturn(f func(string) database.Condition) *MockSessionRepositoryIDConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// InstanceIDColumn mocks base method.
func (m *MockSessionRepository) InstanceIDColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "InstanceIDColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// InstanceIDColumn indicates an expected call of InstanceIDColumn.
func (mr *MockSessionRepositoryMockRecorder) InstanceIDColumn() *MockSessionRepositoryInstanceIDColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InstanceIDColumn", reflect.TypeOf((*MockSessionRepository)(nil).InstanceIDColumn))
return &MockSessionRepositoryInstanceIDColumnCall{Call: call}
}
// MockSessionRepositoryInstanceIDColumnCall wrap *gomock.Call
type MockSessionRepositoryInstanceIDColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryInstanceIDColumnCall) Return(arg0 database.Column) *MockSessionRepositoryInstanceIDColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryInstanceIDColumnCall) Do(f func() database.Column) *MockSessionRepositoryInstanceIDColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryInstanceIDColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryInstanceIDColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// InstanceIDCondition mocks base method.
func (m *MockSessionRepository) InstanceIDCondition(arg0 string) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "InstanceIDCondition", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// InstanceIDCondition indicates an expected call of InstanceIDCondition.
func (mr *MockSessionRepositoryMockRecorder) InstanceIDCondition(arg0 any) *MockSessionRepositoryInstanceIDConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InstanceIDCondition", reflect.TypeOf((*MockSessionRepository)(nil).InstanceIDCondition), arg0)
return &MockSessionRepositoryInstanceIDConditionCall{Call: call}
}
// MockSessionRepositoryInstanceIDConditionCall wrap *gomock.Call
type MockSessionRepositoryInstanceIDConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryInstanceIDConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryInstanceIDConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryInstanceIDConditionCall) Do(f func(string) database.Condition) *MockSessionRepositoryInstanceIDConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryInstanceIDConditionCall) DoAndReturn(f func(string) database.Condition) *MockSessionRepositoryInstanceIDConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// LifetimeColumn mocks base method.
func (m *MockSessionRepository) LifetimeColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "LifetimeColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// LifetimeColumn indicates an expected call of LifetimeColumn.
func (mr *MockSessionRepositoryMockRecorder) LifetimeColumn() *MockSessionRepositoryLifetimeColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "LifetimeColumn", reflect.TypeOf((*MockSessionRepository)(nil).LifetimeColumn))
return &MockSessionRepositoryLifetimeColumnCall{Call: call}
}
// MockSessionRepositoryLifetimeColumnCall wrap *gomock.Call
type MockSessionRepositoryLifetimeColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryLifetimeColumnCall) Return(arg0 database.Column) *MockSessionRepositoryLifetimeColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryLifetimeColumnCall) Do(f func() database.Column) *MockSessionRepositoryLifetimeColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryLifetimeColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryLifetimeColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// List mocks base method.
func (m *MockSessionRepository) List(arg0 context.Context, arg1 database.QueryExecutor, arg2 ...database.QueryOption) ([]*domain.Session, error) {
m.ctrl.T.Helper()
varargs := []any{arg0, arg1}
for _, a := range arg2 {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "List", varargs...)
ret0, _ := ret[0].([]*domain.Session)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// List indicates an expected call of List.
func (mr *MockSessionRepositoryMockRecorder) List(arg0, arg1 any, arg2 ...any) *MockSessionRepositoryListCall {
mr.mock.ctrl.T.Helper()
varargs := append([]any{arg0, arg1}, arg2...)
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "List", reflect.TypeOf((*MockSessionRepository)(nil).List), varargs...)
return &MockSessionRepositoryListCall{Call: call}
}
// MockSessionRepositoryListCall wrap *gomock.Call
type MockSessionRepositoryListCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryListCall) Return(arg0 []*domain.Session, arg1 error) *MockSessionRepositoryListCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryListCall) Do(f func(context.Context, database.QueryExecutor, ...database.QueryOption) ([]*domain.Session, error)) *MockSessionRepositoryListCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryListCall) DoAndReturn(f func(context.Context, database.QueryExecutor, ...database.QueryOption) ([]*domain.Session, error)) *MockSessionRepositoryListCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// MetadataConditions mocks base method.
func (m *MockSessionRepository) MetadataConditions() domain.SessionMetadataConditions {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "MetadataConditions")
ret0, _ := ret[0].(domain.SessionMetadataConditions)
return ret0
}
// MetadataConditions indicates an expected call of MetadataConditions.
func (mr *MockSessionRepositoryMockRecorder) MetadataConditions() *MockSessionRepositoryMetadataConditionsCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "MetadataConditions", reflect.TypeOf((*MockSessionRepository)(nil).MetadataConditions))
return &MockSessionRepositoryMetadataConditionsCall{Call: call}
}
// MockSessionRepositoryMetadataConditionsCall wrap *gomock.Call
type MockSessionRepositoryMetadataConditionsCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryMetadataConditionsCall) Return(arg0 domain.SessionMetadataConditions) *MockSessionRepositoryMetadataConditionsCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryMetadataConditionsCall) Do(f func() domain.SessionMetadataConditions) *MockSessionRepositoryMetadataConditionsCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryMetadataConditionsCall) DoAndReturn(f func() domain.SessionMetadataConditions) *MockSessionRepositoryMetadataConditionsCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// PrimaryKeyColumns mocks base method.
func (m *MockSessionRepository) PrimaryKeyColumns() []database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "PrimaryKeyColumns")
ret0, _ := ret[0].([]database.Column)
return ret0
}
// PrimaryKeyColumns indicates an expected call of PrimaryKeyColumns.
func (mr *MockSessionRepositoryMockRecorder) PrimaryKeyColumns() *MockSessionRepositoryPrimaryKeyColumnsCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PrimaryKeyColumns", reflect.TypeOf((*MockSessionRepository)(nil).PrimaryKeyColumns))
return &MockSessionRepositoryPrimaryKeyColumnsCall{Call: call}
}
// MockSessionRepositoryPrimaryKeyColumnsCall wrap *gomock.Call
type MockSessionRepositoryPrimaryKeyColumnsCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryPrimaryKeyColumnsCall) Return(arg0 []database.Column) *MockSessionRepositoryPrimaryKeyColumnsCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryPrimaryKeyColumnsCall) Do(f func() []database.Column) *MockSessionRepositoryPrimaryKeyColumnsCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryPrimaryKeyColumnsCall) DoAndReturn(f func() []database.Column) *MockSessionRepositoryPrimaryKeyColumnsCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// PrimaryKeyCondition mocks base method.
func (m *MockSessionRepository) PrimaryKeyCondition(arg0, arg1 string) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "PrimaryKeyCondition", arg0, arg1)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// PrimaryKeyCondition indicates an expected call of PrimaryKeyCondition.
func (mr *MockSessionRepositoryMockRecorder) PrimaryKeyCondition(arg0, arg1 any) *MockSessionRepositoryPrimaryKeyConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PrimaryKeyCondition", reflect.TypeOf((*MockSessionRepository)(nil).PrimaryKeyCondition), arg0, arg1)
return &MockSessionRepositoryPrimaryKeyConditionCall{Call: call}
}
// MockSessionRepositoryPrimaryKeyConditionCall wrap *gomock.Call
type MockSessionRepositoryPrimaryKeyConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryPrimaryKeyConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryPrimaryKeyConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryPrimaryKeyConditionCall) Do(f func(string, string) database.Condition) *MockSessionRepositoryPrimaryKeyConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryPrimaryKeyConditionCall) DoAndReturn(f func(string, string) database.Condition) *MockSessionRepositoryPrimaryKeyConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// SetChallenge mocks base method.
func (m *MockSessionRepository) SetChallenge(arg0 domain.SessionChallenge) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SetChallenge", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// SetChallenge indicates an expected call of SetChallenge.
func (mr *MockSessionRepositoryMockRecorder) SetChallenge(arg0 any) *MockSessionRepositorySetChallengeCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetChallenge", reflect.TypeOf((*MockSessionRepository)(nil).SetChallenge), arg0)
return &MockSessionRepositorySetChallengeCall{Call: call}
}
// MockSessionRepositorySetChallengeCall wrap *gomock.Call
type MockSessionRepositorySetChallengeCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositorySetChallengeCall) Return(arg0 database.Change) *MockSessionRepositorySetChallengeCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositorySetChallengeCall) Do(f func(domain.SessionChallenge) database.Change) *MockSessionRepositorySetChallengeCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositorySetChallengeCall) DoAndReturn(f func(domain.SessionChallenge) database.Change) *MockSessionRepositorySetChallengeCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// SetFactor mocks base method.
func (m *MockSessionRepository) SetFactor(arg0 domain.SessionFactor) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SetFactor", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// SetFactor indicates an expected call of SetFactor.
func (mr *MockSessionRepositoryMockRecorder) SetFactor(arg0 any) *MockSessionRepositorySetFactorCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetFactor", reflect.TypeOf((*MockSessionRepository)(nil).SetFactor), arg0)
return &MockSessionRepositorySetFactorCall{Call: call}
}
// MockSessionRepositorySetFactorCall wrap *gomock.Call
type MockSessionRepositorySetFactorCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositorySetFactorCall) Return(arg0 database.Change) *MockSessionRepositorySetFactorCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositorySetFactorCall) Do(f func(domain.SessionFactor) database.Change) *MockSessionRepositorySetFactorCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositorySetFactorCall) DoAndReturn(f func(domain.SessionFactor) database.Change) *MockSessionRepositorySetFactorCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// SetLifetime mocks base method.
func (m *MockSessionRepository) SetLifetime(arg0 time.Duration) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SetLifetime", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// SetLifetime indicates an expected call of SetLifetime.
func (mr *MockSessionRepositoryMockRecorder) SetLifetime(arg0 any) *MockSessionRepositorySetLifetimeCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetLifetime", reflect.TypeOf((*MockSessionRepository)(nil).SetLifetime), arg0)
return &MockSessionRepositorySetLifetimeCall{Call: call}
}
// MockSessionRepositorySetLifetimeCall wrap *gomock.Call
type MockSessionRepositorySetLifetimeCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositorySetLifetimeCall) Return(arg0 database.Change) *MockSessionRepositorySetLifetimeCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositorySetLifetimeCall) Do(f func(time.Duration) database.Change) *MockSessionRepositorySetLifetimeCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositorySetLifetimeCall) DoAndReturn(f func(time.Duration) database.Change) *MockSessionRepositorySetLifetimeCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// SetMetadata mocks base method.
func (m *MockSessionRepository) SetMetadata(arg0 []*domain.SessionMetadata) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SetMetadata", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// SetMetadata indicates an expected call of SetMetadata.
func (mr *MockSessionRepositoryMockRecorder) SetMetadata(arg0 any) *MockSessionRepositorySetMetadataCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetMetadata", reflect.TypeOf((*MockSessionRepository)(nil).SetMetadata), arg0)
return &MockSessionRepositorySetMetadataCall{Call: call}
}
// MockSessionRepositorySetMetadataCall wrap *gomock.Call
type MockSessionRepositorySetMetadataCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositorySetMetadataCall) Return(arg0 database.Change) *MockSessionRepositorySetMetadataCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositorySetMetadataCall) Do(f func([]*domain.SessionMetadata) database.Change) *MockSessionRepositorySetMetadataCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositorySetMetadataCall) DoAndReturn(f func([]*domain.SessionMetadata) database.Change) *MockSessionRepositorySetMetadataCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// SetToken mocks base method.
func (m *MockSessionRepository) SetToken(arg0 string) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SetToken", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// SetToken indicates an expected call of SetToken.
func (mr *MockSessionRepositoryMockRecorder) SetToken(arg0 any) *MockSessionRepositorySetTokenCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetToken", reflect.TypeOf((*MockSessionRepository)(nil).SetToken), arg0)
return &MockSessionRepositorySetTokenCall{Call: call}
}
// MockSessionRepositorySetTokenCall wrap *gomock.Call
type MockSessionRepositorySetTokenCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositorySetTokenCall) Return(arg0 database.Change) *MockSessionRepositorySetTokenCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositorySetTokenCall) Do(f func(string) database.Change) *MockSessionRepositorySetTokenCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositorySetTokenCall) DoAndReturn(f func(string) database.Change) *MockSessionRepositorySetTokenCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// SetUpdatedAt mocks base method.
func (m *MockSessionRepository) SetUpdatedAt(arg0 time.Time) database.Change {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SetUpdatedAt", arg0)
ret0, _ := ret[0].(database.Change)
return ret0
}
// SetUpdatedAt indicates an expected call of SetUpdatedAt.
func (mr *MockSessionRepositoryMockRecorder) SetUpdatedAt(arg0 any) *MockSessionRepositorySetUpdatedAtCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetUpdatedAt", reflect.TypeOf((*MockSessionRepository)(nil).SetUpdatedAt), arg0)
return &MockSessionRepositorySetUpdatedAtCall{Call: call}
}
// MockSessionRepositorySetUpdatedAtCall wrap *gomock.Call
type MockSessionRepositorySetUpdatedAtCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositorySetUpdatedAtCall) Return(arg0 database.Change) *MockSessionRepositorySetUpdatedAtCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositorySetUpdatedAtCall) Do(f func(time.Time) database.Change) *MockSessionRepositorySetUpdatedAtCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositorySetUpdatedAtCall) DoAndReturn(f func(time.Time) database.Change) *MockSessionRepositorySetUpdatedAtCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// TokenColumn mocks base method.
func (m *MockSessionRepository) TokenColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "TokenColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// TokenColumn indicates an expected call of TokenColumn.
func (mr *MockSessionRepositoryMockRecorder) TokenColumn() *MockSessionRepositoryTokenColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TokenColumn", reflect.TypeOf((*MockSessionRepository)(nil).TokenColumn))
return &MockSessionRepositoryTokenColumnCall{Call: call}
}
// MockSessionRepositoryTokenColumnCall wrap *gomock.Call
type MockSessionRepositoryTokenColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryTokenColumnCall) Return(arg0 database.Column) *MockSessionRepositoryTokenColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryTokenColumnCall) Do(f func() database.Column) *MockSessionRepositoryTokenColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryTokenColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryTokenColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// Update mocks base method.
func (m *MockSessionRepository) Update(arg0 context.Context, arg1 database.QueryExecutor, arg2 database.Condition, arg3 ...database.Change) (int64, error) {
m.ctrl.T.Helper()
varargs := []any{arg0, arg1, arg2}
for _, a := range arg3 {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "Update", varargs...)
ret0, _ := ret[0].(int64)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Update indicates an expected call of Update.
func (mr *MockSessionRepositoryMockRecorder) Update(arg0, arg1, arg2 any, arg3 ...any) *MockSessionRepositoryUpdateCall {
mr.mock.ctrl.T.Helper()
varargs := append([]any{arg0, arg1, arg2}, arg3...)
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockSessionRepository)(nil).Update), varargs...)
return &MockSessionRepositoryUpdateCall{Call: call}
}
// MockSessionRepositoryUpdateCall wrap *gomock.Call
type MockSessionRepositoryUpdateCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryUpdateCall) Return(arg0 int64, arg1 error) *MockSessionRepositoryUpdateCall {
c.Call = c.Call.Return(arg0, arg1)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryUpdateCall) Do(f func(context.Context, database.QueryExecutor, database.Condition, ...database.Change) (int64, error)) *MockSessionRepositoryUpdateCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryUpdateCall) DoAndReturn(f func(context.Context, database.QueryExecutor, database.Condition, ...database.Change) (int64, error)) *MockSessionRepositoryUpdateCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// UpdatedAtColumn mocks base method.
func (m *MockSessionRepository) UpdatedAtColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UpdatedAtColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// UpdatedAtColumn indicates an expected call of UpdatedAtColumn.
func (mr *MockSessionRepositoryMockRecorder) UpdatedAtColumn() *MockSessionRepositoryUpdatedAtColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdatedAtColumn", reflect.TypeOf((*MockSessionRepository)(nil).UpdatedAtColumn))
return &MockSessionRepositoryUpdatedAtColumnCall{Call: call}
}
// MockSessionRepositoryUpdatedAtColumnCall wrap *gomock.Call
type MockSessionRepositoryUpdatedAtColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryUpdatedAtColumnCall) Return(arg0 database.Column) *MockSessionRepositoryUpdatedAtColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryUpdatedAtColumnCall) Do(f func() database.Column) *MockSessionRepositoryUpdatedAtColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryUpdatedAtColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryUpdatedAtColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// UpdatedAtCondition mocks base method.
func (m *MockSessionRepository) UpdatedAtCondition(arg0 database.NumberOperation, arg1 time.Time) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UpdatedAtCondition", arg0, arg1)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// UpdatedAtCondition indicates an expected call of UpdatedAtCondition.
func (mr *MockSessionRepositoryMockRecorder) UpdatedAtCondition(arg0, arg1 any) *MockSessionRepositoryUpdatedAtConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdatedAtCondition", reflect.TypeOf((*MockSessionRepository)(nil).UpdatedAtCondition), arg0, arg1)
return &MockSessionRepositoryUpdatedAtConditionCall{Call: call}
}
// MockSessionRepositoryUpdatedAtConditionCall wrap *gomock.Call
type MockSessionRepositoryUpdatedAtConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryUpdatedAtConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryUpdatedAtConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryUpdatedAtConditionCall) Do(f func(database.NumberOperation, time.Time) database.Condition) *MockSessionRepositoryUpdatedAtConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryUpdatedAtConditionCall) DoAndReturn(f func(database.NumberOperation, time.Time) database.Condition) *MockSessionRepositoryUpdatedAtConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// UserAgentIDCondition mocks base method.
func (m *MockSessionRepository) UserAgentIDCondition(arg0 string) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UserAgentIDCondition", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// UserAgentIDCondition indicates an expected call of UserAgentIDCondition.
func (mr *MockSessionRepositoryMockRecorder) UserAgentIDCondition(arg0 any) *MockSessionRepositoryUserAgentIDConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UserAgentIDCondition", reflect.TypeOf((*MockSessionRepository)(nil).UserAgentIDCondition), arg0)
return &MockSessionRepositoryUserAgentIDConditionCall{Call: call}
}
// MockSessionRepositoryUserAgentIDConditionCall wrap *gomock.Call
type MockSessionRepositoryUserAgentIDConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryUserAgentIDConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryUserAgentIDConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryUserAgentIDConditionCall) Do(f func(string) database.Condition) *MockSessionRepositoryUserAgentIDConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryUserAgentIDConditionCall) DoAndReturn(f func(string) database.Condition) *MockSessionRepositoryUserAgentIDConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// UserIDColumn mocks base method.
func (m *MockSessionRepository) UserIDColumn() database.Column {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UserIDColumn")
ret0, _ := ret[0].(database.Column)
return ret0
}
// UserIDColumn indicates an expected call of UserIDColumn.
func (mr *MockSessionRepositoryMockRecorder) UserIDColumn() *MockSessionRepositoryUserIDColumnCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UserIDColumn", reflect.TypeOf((*MockSessionRepository)(nil).UserIDColumn))
return &MockSessionRepositoryUserIDColumnCall{Call: call}
}
// MockSessionRepositoryUserIDColumnCall wrap *gomock.Call
type MockSessionRepositoryUserIDColumnCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryUserIDColumnCall) Return(arg0 database.Column) *MockSessionRepositoryUserIDColumnCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryUserIDColumnCall) Do(f func() database.Column) *MockSessionRepositoryUserIDColumnCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryUserIDColumnCall) DoAndReturn(f func() database.Column) *MockSessionRepositoryUserIDColumnCall {
c.Call = c.Call.DoAndReturn(f)
return c
}
// UserIDCondition mocks base method.
func (m *MockSessionRepository) UserIDCondition(arg0 string) database.Condition {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UserIDCondition", arg0)
ret0, _ := ret[0].(database.Condition)
return ret0
}
// UserIDCondition indicates an expected call of UserIDCondition.
func (mr *MockSessionRepositoryMockRecorder) UserIDCondition(arg0 any) *MockSessionRepositoryUserIDConditionCall {
mr.mock.ctrl.T.Helper()
call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UserIDCondition", reflect.TypeOf((*MockSessionRepository)(nil).UserIDCondition), arg0)
return &MockSessionRepositoryUserIDConditionCall{Call: call}
}
// MockSessionRepositoryUserIDConditionCall wrap *gomock.Call
type MockSessionRepositoryUserIDConditionCall struct {
*gomock.Call
}
// Return rewrite *gomock.Call.Return
func (c *MockSessionRepositoryUserIDConditionCall) Return(arg0 database.Condition) *MockSessionRepositoryUserIDConditionCall {
c.Call = c.Call.Return(arg0)
return c
}
// Do rewrite *gomock.Call.Do
func (c *MockSessionRepositoryUserIDConditionCall) Do(f func(string) database.Condition) *MockSessionRepositoryUserIDConditionCall {
c.Call = c.Call.Do(f)
return c
}
// DoAndReturn rewrite *gomock.Call.DoAndReturn
func (c *MockSessionRepositoryUserIDConditionCall) DoAndReturn(f func(string) database.Condition) *MockSessionRepositoryUserIDConditionCall {
c.Call = c.Call.DoAndReturn(f)
return c
}