service

package
v0.0.0-...-66e44cd Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddTask

type AddTask struct {
	DB   store.Execer
	Repo TaskAdder
}

func (*AddTask) AddTask

func (a *AddTask) AddTask(ctx context.Context, title string) (*entity.Task, error)

type ListTask

type ListTask struct {
	DB   store.Queryer
	Repo TaskLister
}

func (*ListTask) ListTasks

func (l *ListTask) ListTasks(ctx context.Context) (entity.Tasks, error)

type RegisterUser

type RegisterUser struct {
	DB   store.Execer
	Repo UserRegisterer
}

func (*RegisterUser) RegisterUser

func (r *RegisterUser) RegisterUser(ctx context.Context, name, password, role string) (*entity.User, error)

type TaskAdder

type TaskAdder interface {
	AddTask(ctx context.Context, db store.Execer, t *entity.Task) error
}

type TaskLister

type TaskLister interface {
	ListTasks(ctx context.Context, db store.Queryer) (entity.Tasks, error)
}

type UserRegisterer

type UserRegisterer interface {
	RegisterUser(ctx context.Context, db store.Execer, u *entity.User) error
}

Jump to

Keyboard shortcuts

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