biz

package
v0.0.0-...-5a87348 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2023 License: MIT Imports: 3 Imported by: 0

README

Biz

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ProviderSet = wire.NewSet(NewUserUsecase)

ProviderSet is biz providers.

Functions

This section is empty.

Types

type User

type User struct {
}

User is a User model.

type UserRepo

type UserRepo interface {
	Save(context.Context, *User) (*User, error)
	Update(context.Context, *User) (*User, error)
	FindByID(context.Context, int64) (*User, error)
	ListByHello(context.Context, string) ([]*User, error)
	ListAll(context.Context) ([]*User, error)
}

UserRepo is a User repo.

type UserUsecase

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

UserUsecase is a User usecase.

func NewUserUsecase

func NewUserUsecase(repo UserRepo, logger log.Logger) *UserUsecase

NewUserUsecase new a User usecase.

func (*UserUsecase) CreateUser

func (uc *UserUsecase) CreateUser(ctx context.Context, g *User) (*User, error)

CreateUser creates a User, and returns the new User.

Jump to

Keyboard shortcuts

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