model

package
v0.0.0-...-64fada1 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2022 License: BSD-3-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB struct {
	*sql.DB
}

func NewDB

func NewDB() (*DB, func() error, error)

NewDB returns a new instance of DB, close function, and error if fail to open db.

type User

type User struct {
	ID           int
	Email        string
	PasswordHash string
}

type UserService

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

func NewUserService

func NewUserService(db *DB, user User) UserService

func (UserService) Byemail

func (us UserService) Byemail() User

func (UserService) Create

func (us UserService) Create()

Jump to

Keyboard shortcuts

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