repositories

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 13, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDuplicate      = errors.New("a record already exists")
	ErrNoDependency   = errors.New("record dependencies don't exist")
	ErrNotExist       = errors.New("a row does not exist")
	ErrInsertFailed   = errors.New("insert failed")
	ErrUpdateFailed   = errors.New("update failed")
	ErrDeleteFailed   = errors.New("delete failed")
	ErrNotImplemented = errors.New("not implemented")
)

Functions

func ActorByBuildingIsEqual

func ActorByBuildingIsEqual(buildingID int64) func(s *ActorSpecificationByBuilding) bool

func AlikeAddressSpecIsEqual

func AlikeAddressSpecIsEqual(addressPrefix string, limit, offset int) func(s *BuildingSpecificationByAlikeAddress) bool

func BuildingByAddressIsEqual

func BuildingByAddressIsEqual(address string) func(s *BuildingSpecificationByAddress) bool

func BuildingByIDIsEqual added in v1.0.0

func BuildingByIDIsEqual(id int64) func(s *BuildingSpecificationByID) bool

func NearestSpecIsEqual

func NearestSpecIsEqual(
	distanceMeters int,
	latitude,
	longitude float64,
	limit,
	offset int,
) func(s *BuildingSpecificationNearest) bool

func NewUserRepo added in v1.0.0

func NewUserRepo(dbPool *pgxpool.Pool) *userStorage

func UserByIDIsEqual added in v1.0.0

func UserByIDIsEqual(telegramID int64) func(s *UserSpecificationByTelegramID) bool

Types

type Actor

type Actor struct {
	ID      int64
	Name    string
	TitleFi *string
	TitleEn *string
	TitleRu *string
	Timestamps
}

type ActorRepository

type ActorRepository interface {
	Add(context.Context, Actor) (*Actor, error)
	Remove(context.Context, Actor) error
	Update(context.Context, Actor) (*Actor, error)
	Query(context.Context, Specification) ([]Actor, error)
}

func NewActorRepo

func NewActorRepo(dbPool *pgxpool.Pool) ActorRepository

type ActorRepository_mock

type ActorRepository_mock struct {
	mock.Mock
}

ActorRepository_mock is an autogenerated mock type for the ActorRepository type

func NewActorRepository_mock

func NewActorRepository_mock(t interface {
	mock.TestingT
	Cleanup(func())
}) *ActorRepository_mock

NewActorRepository_mock creates a new instance of ActorRepository_mock. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*ActorRepository_mock) Add

func (_m *ActorRepository_mock) Add(_a0 context.Context, _a1 Actor) (*Actor, error)

Add provides a mock function with given fields: _a0, _a1

func (*ActorRepository_mock) EXPECT

func (*ActorRepository_mock) Query

func (_m *ActorRepository_mock) Query(_a0 context.Context, _a1 Specification) ([]Actor, error)

Query provides a mock function with given fields: _a0, _a1

func (*ActorRepository_mock) Remove

func (_m *ActorRepository_mock) Remove(_a0 context.Context, _a1 Actor) error

Remove provides a mock function with given fields: _a0, _a1

func (*ActorRepository_mock) Update

func (_m *ActorRepository_mock) Update(_a0 context.Context, _a1 Actor) (*Actor, error)

Update provides a mock function with given fields: _a0, _a1

type ActorRepository_mock_Add_Call

type ActorRepository_mock_Add_Call struct {
	*mock.Call
}

ActorRepository_mock_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'

func (*ActorRepository_mock_Add_Call) Return

func (*ActorRepository_mock_Add_Call) Run

func (*ActorRepository_mock_Add_Call) RunAndReturn

type ActorRepository_mock_Expecter

type ActorRepository_mock_Expecter struct {
	// contains filtered or unexported fields
}

func (*ActorRepository_mock_Expecter) Add

func (_e *ActorRepository_mock_Expecter) Add(_a0 interface{}, _a1 interface{}) *ActorRepository_mock_Add_Call

Add is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Actor

func (*ActorRepository_mock_Expecter) Query

func (_e *ActorRepository_mock_Expecter) Query(_a0 interface{}, _a1 interface{}) *ActorRepository_mock_Query_Call

Query is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Specification

func (*ActorRepository_mock_Expecter) Remove

func (_e *ActorRepository_mock_Expecter) Remove(_a0 interface{}, _a1 interface{}) *ActorRepository_mock_Remove_Call

Remove is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Actor

func (*ActorRepository_mock_Expecter) Update

func (_e *ActorRepository_mock_Expecter) Update(_a0 interface{}, _a1 interface{}) *ActorRepository_mock_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Actor

type ActorRepository_mock_Query_Call

type ActorRepository_mock_Query_Call struct {
	*mock.Call
}

ActorRepository_mock_Query_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Query'

func (*ActorRepository_mock_Query_Call) Return

func (*ActorRepository_mock_Query_Call) Run

func (*ActorRepository_mock_Query_Call) RunAndReturn

type ActorRepository_mock_Remove_Call

type ActorRepository_mock_Remove_Call struct {
	*mock.Call
}

ActorRepository_mock_Remove_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remove'

func (*ActorRepository_mock_Remove_Call) Return

func (*ActorRepository_mock_Remove_Call) Run

func (*ActorRepository_mock_Remove_Call) RunAndReturn

type ActorRepository_mock_Update_Call

type ActorRepository_mock_Update_Call struct {
	*mock.Call
}

ActorRepository_mock_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*ActorRepository_mock_Update_Call) Return

func (*ActorRepository_mock_Update_Call) Run

func (*ActorRepository_mock_Update_Call) RunAndReturn

type ActorSpecificationAll

type ActorSpecificationAll struct {
	// contains filtered or unexported fields
}

func (*ActorSpecificationAll) ToSQL

func (a *ActorSpecificationAll) ToSQL() (string, map[string]any)

type ActorSpecificationByBuilding

type ActorSpecificationByBuilding struct {
	// contains filtered or unexported fields
}

func NewAuthorSpecificationByBuilding

func NewAuthorSpecificationByBuilding(buildingID int64) *ActorSpecificationByBuilding

func (*ActorSpecificationByBuilding) ToSQL

func (a *ActorSpecificationByBuilding) ToSQL() (string, map[string]any)

type ActorSpecificationByName

type ActorSpecificationByName struct {
	// contains filtered or unexported fields
}

func (*ActorSpecificationByName) ToSQL

func (a *ActorSpecificationByName) ToSQL() (string, map[string]any)

type Address

type Address struct {
	ID              int64
	StreetAddress   string
	NeighbourhoodID *int64
	Timestamps
}

type Building

type Building struct {
	ID                    int64
	Code                  *string
	NameFi                *string
	NameEn                *string
	NameRu                *string
	Address               Address
	ConstructionStartYear *int
	CompletionYear        *int
	ComplexFi             *string
	ComplexEn             *string
	ComplexRu             *string
	HistoryFi             *string
	HistoryEn             *string
	HistoryRu             *string
	ReasoningFi           *string
	ReasoningEn           *string
	ReasoningRu           *string
	ProtectionStatusFi    *string
	ProtectionStatusEn    *string
	ProtectionStatusRu    *string
	InfoSourceFi          *string
	InfoSourceEn          *string
	InfoSourceRu          *string
	SurroundingsFi        *string
	SurroundingsEn        *string
	SurroundingsRu        *string
	FoundationFi          *string
	FoundationEn          *string
	FoundationRu          *string
	FrameFi               *string
	FrameEn               *string
	FrameRu               *string
	FloorDescriptionFi    *string
	FloorDescriptionEn    *string
	FloorDescriptionRu    *string
	FacadesFi             *string
	FacadesEn             *string
	FacadesRu             *string
	SpecialFeaturesFi     *string
	SpecialFeaturesEn     *string
	SpecialFeaturesRu     *string
	Latitude_ETRSGK25     *float32
	Longitude_ETRSGK25    *float32
	Latitude_WGS84        *float64
	Longitude_WGS84       *float64
	AuthorIDs             []int64
	InitialUses           []UseType
	CurrentUses           []UseType
	Timestamps
}

type BuildingRepository

type BuildingRepository interface {
	Add(context.Context, Building) (*Building, error)
	Remove(context.Context, Building) error
	Update(context.Context, Building) (*Building, error)
	Query(context.Context, Specification) ([]Building, error)
}

type BuildingRepository_mock

type BuildingRepository_mock struct {
	mock.Mock
}

BuildingRepository_mock is an autogenerated mock type for the BuildingRepository type

func NewBuildingRepository_mock

func NewBuildingRepository_mock(t interface {
	mock.TestingT
	Cleanup(func())
}) *BuildingRepository_mock

NewBuildingRepository_mock creates a new instance of BuildingRepository_mock. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*BuildingRepository_mock) Add

Add provides a mock function with given fields: _a0, _a1

func (*BuildingRepository_mock) EXPECT

func (*BuildingRepository_mock) Query

Query provides a mock function with given fields: _a0, _a1

func (*BuildingRepository_mock) Remove

func (_m *BuildingRepository_mock) Remove(_a0 context.Context, _a1 Building) error

Remove provides a mock function with given fields: _a0, _a1

func (*BuildingRepository_mock) Update

func (_m *BuildingRepository_mock) Update(_a0 context.Context, _a1 Building) (*Building, error)

Update provides a mock function with given fields: _a0, _a1

type BuildingRepository_mock_Add_Call

type BuildingRepository_mock_Add_Call struct {
	*mock.Call
}

BuildingRepository_mock_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'

func (*BuildingRepository_mock_Add_Call) Return

func (*BuildingRepository_mock_Add_Call) Run

func (*BuildingRepository_mock_Add_Call) RunAndReturn

type BuildingRepository_mock_Expecter

type BuildingRepository_mock_Expecter struct {
	// contains filtered or unexported fields
}

func (*BuildingRepository_mock_Expecter) Add

func (_e *BuildingRepository_mock_Expecter) Add(_a0 interface{}, _a1 interface{}) *BuildingRepository_mock_Add_Call

Add is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Building

func (*BuildingRepository_mock_Expecter) Query

func (_e *BuildingRepository_mock_Expecter) Query(_a0 interface{}, _a1 interface{}) *BuildingRepository_mock_Query_Call

Query is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Specification

func (*BuildingRepository_mock_Expecter) Remove

func (_e *BuildingRepository_mock_Expecter) Remove(_a0 interface{}, _a1 interface{}) *BuildingRepository_mock_Remove_Call

Remove is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Building

func (*BuildingRepository_mock_Expecter) Update

func (_e *BuildingRepository_mock_Expecter) Update(_a0 interface{}, _a1 interface{}) *BuildingRepository_mock_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Building

type BuildingRepository_mock_Query_Call

type BuildingRepository_mock_Query_Call struct {
	*mock.Call
}

BuildingRepository_mock_Query_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Query'

func (*BuildingRepository_mock_Query_Call) Return

func (*BuildingRepository_mock_Query_Call) Run

func (*BuildingRepository_mock_Query_Call) RunAndReturn

type BuildingRepository_mock_Remove_Call

type BuildingRepository_mock_Remove_Call struct {
	*mock.Call
}

BuildingRepository_mock_Remove_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remove'

func (*BuildingRepository_mock_Remove_Call) Return

func (*BuildingRepository_mock_Remove_Call) Run

func (*BuildingRepository_mock_Remove_Call) RunAndReturn

type BuildingRepository_mock_Update_Call

type BuildingRepository_mock_Update_Call struct {
	*mock.Call
}

BuildingRepository_mock_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*BuildingRepository_mock_Update_Call) Return

func (*BuildingRepository_mock_Update_Call) Run

func (*BuildingRepository_mock_Update_Call) RunAndReturn

type BuildingSpecificationAll

type BuildingSpecificationAll struct {
	// contains filtered or unexported fields
}

func (*BuildingSpecificationAll) ToSQL

func (b *BuildingSpecificationAll) ToSQL() (string, map[string]any)

type BuildingSpecificationByAddress

type BuildingSpecificationByAddress struct {
	// contains filtered or unexported fields
}

func (*BuildingSpecificationByAddress) ToSQL

func (b *BuildingSpecificationByAddress) ToSQL() (string, map[string]any)

type BuildingSpecificationByAlikeAddress

type BuildingSpecificationByAlikeAddress struct {
	// contains filtered or unexported fields
}

func (*BuildingSpecificationByAlikeAddress) ToSQL

type BuildingSpecificationByID added in v1.0.0

type BuildingSpecificationByID struct {
	// contains filtered or unexported fields
}

func NewBuildingSpecificationByID added in v1.0.0

func NewBuildingSpecificationByID(id int64) *BuildingSpecificationByID

func (*BuildingSpecificationByID) ToSQL added in v1.0.0

func (b *BuildingSpecificationByID) ToSQL() (string, map[string]any)

type BuildingSpecificationNearest

type BuildingSpecificationNearest struct {
	// contains filtered or unexported fields
}

func (*BuildingSpecificationNearest) ToSQL

func (b *BuildingSpecificationNearest) ToSQL() (string, map[string]any)

type BuildingStorage

type BuildingStorage struct {
	// contains filtered or unexported fields
}

func NewBuildingRepo

func NewBuildingRepo(dbPool *pgxpool.Pool) *BuildingStorage

func (*BuildingStorage) Add

func (b *BuildingStorage) Add(ctx context.Context, building Building) (*Building, error)

func (*BuildingStorage) Query

func (b *BuildingStorage) Query(
	ctx context.Context,
	spec Specification,
) ([]Building, error)

func (*BuildingStorage) Remove

func (b *BuildingStorage) Remove(ctx context.Context, building Building) error

func (*BuildingStorage) Update

func (b *BuildingStorage) Update(ctx context.Context, building Building) (*Building, error)

type Neighbourhood

type Neighbourhood struct {
	ID           int64
	Name         string
	Municipality *string
	Timestamps
}

type NeighbourhoodRepository_mock

type NeighbourhoodRepository_mock struct {
	mock.Mock
}

NeighbourhoodRepository_mock is an autogenerated mock type for the NeighbourhoodRepository type

func NewNeighbourhoodRepository_mock

func NewNeighbourhoodRepository_mock(t interface {
	mock.TestingT
	Cleanup(func())
}) *NeighbourhoodRepository_mock

NewNeighbourhoodRepository_mock creates a new instance of NeighbourhoodRepository_mock. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*NeighbourhoodRepository_mock) Add

Add provides a mock function with given fields: _a0, _a1

func (*NeighbourhoodRepository_mock) EXPECT

func (*NeighbourhoodRepository_mock) Query

Query provides a mock function with given fields: _a0, _a1

func (*NeighbourhoodRepository_mock) Remove

Remove provides a mock function with given fields: _a0, _a1

func (*NeighbourhoodRepository_mock) Update

Update provides a mock function with given fields: _a0, _a1

type NeighbourhoodRepository_mock_Add_Call

type NeighbourhoodRepository_mock_Add_Call struct {
	*mock.Call
}

NeighbourhoodRepository_mock_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'

func (*NeighbourhoodRepository_mock_Add_Call) Return

func (*NeighbourhoodRepository_mock_Add_Call) Run

func (*NeighbourhoodRepository_mock_Add_Call) RunAndReturn

type NeighbourhoodRepository_mock_Expecter

type NeighbourhoodRepository_mock_Expecter struct {
	// contains filtered or unexported fields
}

func (*NeighbourhoodRepository_mock_Expecter) Add

func (_e *NeighbourhoodRepository_mock_Expecter) Add(_a0 interface{}, _a1 interface{}) *NeighbourhoodRepository_mock_Add_Call

Add is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Neighbourhood

func (*NeighbourhoodRepository_mock_Expecter) Query

func (_e *NeighbourhoodRepository_mock_Expecter) Query(_a0 interface{}, _a1 interface{}) *NeighbourhoodRepository_mock_Query_Call

Query is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Specification

func (*NeighbourhoodRepository_mock_Expecter) Remove

func (_e *NeighbourhoodRepository_mock_Expecter) Remove(_a0 interface{}, _a1 interface{}) *NeighbourhoodRepository_mock_Remove_Call

Remove is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Neighbourhood

func (*NeighbourhoodRepository_mock_Expecter) Update

func (_e *NeighbourhoodRepository_mock_Expecter) Update(_a0 interface{}, _a1 interface{}) *NeighbourhoodRepository_mock_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Neighbourhood

type NeighbourhoodRepository_mock_Query_Call

type NeighbourhoodRepository_mock_Query_Call struct {
	*mock.Call
}

NeighbourhoodRepository_mock_Query_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Query'

func (*NeighbourhoodRepository_mock_Query_Call) Return

func (*NeighbourhoodRepository_mock_Query_Call) Run

func (*NeighbourhoodRepository_mock_Query_Call) RunAndReturn

type NeighbourhoodRepository_mock_Remove_Call

type NeighbourhoodRepository_mock_Remove_Call struct {
	*mock.Call
}

NeighbourhoodRepository_mock_Remove_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remove'

func (*NeighbourhoodRepository_mock_Remove_Call) Return

func (*NeighbourhoodRepository_mock_Remove_Call) Run

func (*NeighbourhoodRepository_mock_Remove_Call) RunAndReturn

type NeighbourhoodRepository_mock_Update_Call

type NeighbourhoodRepository_mock_Update_Call struct {
	*mock.Call
}

NeighbourhoodRepository_mock_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*NeighbourhoodRepository_mock_Update_Call) Return

func (*NeighbourhoodRepository_mock_Update_Call) Run

func (*NeighbourhoodRepository_mock_Update_Call) RunAndReturn

type NeighbourhoodSpecificationAll

type NeighbourhoodSpecificationAll struct {
	// contains filtered or unexported fields
}

func (*NeighbourhoodSpecificationAll) ToSQL

func (a *NeighbourhoodSpecificationAll) ToSQL() (string, map[string]any)

type NeighbourhoodSpecificationByName

type NeighbourhoodSpecificationByName struct {
	// contains filtered or unexported fields
}

func (*NeighbourhoodSpecificationByName) ToSQL

type Specification

type Specification interface {
	ToSQL() (string, map[string]any)
}

func NewActorSpecificationAll

func NewActorSpecificationAll(limit, offset int) Specification

func NewActorSpecificationByName

func NewActorSpecificationByName(a Actor) Specification

func NewBuildingSpecificationAll

func NewBuildingSpecificationAll(limit, offset int) Specification

func NewBuildingSpecificationByAddress

func NewBuildingSpecificationByAddress(address string) Specification

func NewBuildingSpecificationByAlikeAddress

func NewBuildingSpecificationByAlikeAddress(
	prefix string,
	limit,
	offset int,
) Specification

func NewBuildingSpecificationNearest

func NewBuildingSpecificationNearest(
	distanceMeters int,
	latitude,
	longitude float64,
	limit,
	offset int,
) Specification

func NewNeighbourhoodSpecificationAll

func NewNeighbourhoodSpecificationAll(limit, offset int) Specification

func NewNeighbourhoodSpecificationByName

func NewNeighbourhoodSpecificationByName(n Neighbourhood) Specification

type Timestamps

type Timestamps struct {
	CreatedAt time.Time
	UpdatedAt *time.Time
	// contains filtered or unexported fields
}

type UseTableNames

type UseTableNames string

type UseType

type UseType struct {
	ID     int64
	NameFi string
	NameEn string
	NameRu string
	Timestamps
}

type User added in v1.0.0

type User struct {
	ID                int64
	TelegramID        int64
	PreferredLanguage string
	Timestamps
}

type UserRepository added in v1.0.0

type UserRepository interface {
	Add(context.Context, User) (*User, error)
	AddOrUpdate(context.Context, User) (*User, error)
	Remove(context.Context, User) error
	Update(context.Context, User) (*User, error)
	Query(context.Context, Specification) ([]User, error)
}

type UserRepository_mock added in v1.0.0

type UserRepository_mock struct {
	mock.Mock
}

UserRepository_mock is an autogenerated mock type for the UserRepository type

func NewUserRepository_mock added in v1.0.0

func NewUserRepository_mock(t interface {
	mock.TestingT
	Cleanup(func())
}) *UserRepository_mock

NewUserRepository_mock creates a new instance of UserRepository_mock. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*UserRepository_mock) Add added in v1.0.0

func (_m *UserRepository_mock) Add(_a0 context.Context, _a1 User) (*User, error)

Add provides a mock function with given fields: _a0, _a1

func (*UserRepository_mock) AddOrUpdate added in v1.0.0

func (_m *UserRepository_mock) AddOrUpdate(_a0 context.Context, _a1 User) (*User, error)

AddOrUpdate provides a mock function with given fields: _a0, _a1

func (*UserRepository_mock) EXPECT added in v1.0.0

func (*UserRepository_mock) Query added in v1.0.0

func (_m *UserRepository_mock) Query(_a0 context.Context, _a1 Specification) ([]User, error)

Query provides a mock function with given fields: _a0, _a1

func (*UserRepository_mock) Remove added in v1.0.0

func (_m *UserRepository_mock) Remove(_a0 context.Context, _a1 User) error

Remove provides a mock function with given fields: _a0, _a1

func (*UserRepository_mock) Update added in v1.0.0

func (_m *UserRepository_mock) Update(_a0 context.Context, _a1 User) (*User, error)

Update provides a mock function with given fields: _a0, _a1

type UserRepository_mock_AddOrUpdate_Call added in v1.0.0

type UserRepository_mock_AddOrUpdate_Call struct {
	*mock.Call
}

UserRepository_mock_AddOrUpdate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AddOrUpdate'

func (*UserRepository_mock_AddOrUpdate_Call) Return added in v1.0.0

func (*UserRepository_mock_AddOrUpdate_Call) Run added in v1.0.0

func (*UserRepository_mock_AddOrUpdate_Call) RunAndReturn added in v1.0.0

type UserRepository_mock_Add_Call added in v1.0.0

type UserRepository_mock_Add_Call struct {
	*mock.Call
}

UserRepository_mock_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'

func (*UserRepository_mock_Add_Call) Return added in v1.0.0

func (*UserRepository_mock_Add_Call) Run added in v1.0.0

func (*UserRepository_mock_Add_Call) RunAndReturn added in v1.0.0

type UserRepository_mock_Expecter added in v1.0.0

type UserRepository_mock_Expecter struct {
	// contains filtered or unexported fields
}

func (*UserRepository_mock_Expecter) Add added in v1.0.0

func (_e *UserRepository_mock_Expecter) Add(_a0 interface{}, _a1 interface{}) *UserRepository_mock_Add_Call

Add is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 User

func (*UserRepository_mock_Expecter) AddOrUpdate added in v1.0.0

func (_e *UserRepository_mock_Expecter) AddOrUpdate(_a0 interface{}, _a1 interface{}) *UserRepository_mock_AddOrUpdate_Call

AddOrUpdate is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 User

func (*UserRepository_mock_Expecter) Query added in v1.0.0

func (_e *UserRepository_mock_Expecter) Query(_a0 interface{}, _a1 interface{}) *UserRepository_mock_Query_Call

Query is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 Specification

func (*UserRepository_mock_Expecter) Remove added in v1.0.0

func (_e *UserRepository_mock_Expecter) Remove(_a0 interface{}, _a1 interface{}) *UserRepository_mock_Remove_Call

Remove is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 User

func (*UserRepository_mock_Expecter) Update added in v1.0.0

func (_e *UserRepository_mock_Expecter) Update(_a0 interface{}, _a1 interface{}) *UserRepository_mock_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 User

type UserRepository_mock_Query_Call added in v1.0.0

type UserRepository_mock_Query_Call struct {
	*mock.Call
}

UserRepository_mock_Query_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Query'

func (*UserRepository_mock_Query_Call) Return added in v1.0.0

func (*UserRepository_mock_Query_Call) Run added in v1.0.0

func (*UserRepository_mock_Query_Call) RunAndReturn added in v1.0.0

type UserRepository_mock_Remove_Call added in v1.0.0

type UserRepository_mock_Remove_Call struct {
	*mock.Call
}

UserRepository_mock_Remove_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remove'

func (*UserRepository_mock_Remove_Call) Return added in v1.0.0

func (*UserRepository_mock_Remove_Call) Run added in v1.0.0

func (*UserRepository_mock_Remove_Call) RunAndReturn added in v1.0.0

type UserRepository_mock_Update_Call added in v1.0.0

type UserRepository_mock_Update_Call struct {
	*mock.Call
}

UserRepository_mock_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*UserRepository_mock_Update_Call) Return added in v1.0.0

func (*UserRepository_mock_Update_Call) Run added in v1.0.0

func (*UserRepository_mock_Update_Call) RunAndReturn added in v1.0.0

type UserSpecificationByTelegramID added in v1.0.0

type UserSpecificationByTelegramID struct {
	// contains filtered or unexported fields
}

func NewUserSpecificationByID added in v1.0.0

func NewUserSpecificationByID(telegramID int64) *UserSpecificationByTelegramID

func (*UserSpecificationByTelegramID) ToSQL added in v1.0.0

func (a *UserSpecificationByTelegramID) ToSQL() (string, map[string]any)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL