sqlstore

package
v0.0.46 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

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

func New

func New(conf *config.Store) (*Store, error)

func TestDB

func TestDB(t *testing.T, conf *config.Store) (*Store, func(...string))

TestDB returns special test connection and teardown function.

func (*Store) Update

func (s *Store) Update() store.UpdateRepository

func (*Store) User

func (s *Store) User() store.UserRepository

type UpdateRepository

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

func (*UpdateRepository) Create

func (r *UpdateRepository) Create(update *model.Update) error

func (*UpdateRepository) FindByID

func (r *UpdateRepository) FindByID(id int) (*model.Update, error)

type UserRepository

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

func (*UserRepository) Create

func (r *UserRepository) Create(user *model.User) error

func (*UserRepository) FindByID

func (r *UserRepository) FindByID(id int) (*model.User, error)

Jump to

Keyboard shortcuts

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