usecases

package
Version: v0.0.0-...-abc7074 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewUserUsecase

func NewUserUsecase(repo user.UserRepository) user.UserUsecase

Types

type UserUsecase

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

func (*UserUsecase) CheckSessionByUsername

func (uu *UserUsecase) CheckSessionByUsername(username string) (status int, err error)

func (*UserUsecase) Create

func (uu *UserUsecase) Create(user *models.User) (status int, err error)

func (*UserUsecase) FindUserByUsername

func (uu *UserUsecase) FindUserByUsername(username string) (user *models.User, status int, err error)

func (*UserUsecase) GetAllUsers

func (uu *UserUsecase) GetAllUsers() (users []models.User, status int, err error)

func (*UserUsecase) GetPassword

func (uu *UserUsecase) GetPassword(username string) (password string, status int, err error)

func (*UserUsecase) GetUserByID

func (uu *UserUsecase) GetUserByID(userID int64) (user *models.User, err error)

func (*UserUsecase) UpdateSession

func (uu *UserUsecase) UpdateSession(userID int64, sessionValue string) (err error)

func (*UserUsecase) ValidateSession

func (uu *UserUsecase) ValidateSession(sessionValue string) (user *models.User, status int, err error)

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL