user

package
v0.0.0-...-6ce8071 Latest Latest
Warning

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

Go to latest
Published: May 10, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Repository

type Repository interface {
	Fetch(ctx context.Context) ([]models.User, error)
	GetByID(ctx context.Context, id int64) (*models.User, error)
	GetByEmpNumber(ctx context.Context, empNumber string) (models.User, error)
	Update(ctx context.Context, ar *models.User, id int) error
	Store(ctx context.Context, a *models.User) (int, error)
	Delete(ctx context.Context, a *models.User) error
	FindAll() (res []*models.User, err error)
	GetByUserName(ctx context.Context, userName string) (models.User, error)
}

Repository represent the User's repository contract

type Usecase

type Usecase interface {
	Store(context.Context, *models.User) error
	Update(ctx context.Context, u *models.User) error
	Delete(ctx context.Context, empNumber string) error
	GetByEmpNumber(ctx context.Context, empNumber string) (models.User, error)
	Fetch(ctx context.Context) ([]models.User, error)
	Login(ctx context.Context, u models.User) (models.User, error)
}

Usecase represent the user's usecases

Directories

Path Synopsis
delivery

Jump to

Keyboard shortcuts

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