Documentation
¶
Index ¶
- type Reader
- type Repository
- type Service
- func (s *Service) CreateUser(email, password, firstName, lastName string) (entity.ID, error)
- func (s *Service) DeleteUser(id entity.ID) error
- func (s *Service) GetUser(id entity.ID) (*entity.User, error)
- func (s *Service) ListUsers() ([]*entity.User, error)
- func (s *Service) SearchUsers(query string) ([]*entity.User, error)
- func (s *Service) UpdateUser(e *entity.User) error
- type UseCase
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Reader ¶
type Reader interface { Get(id entity.ID) (*entity.User, error) Search(query string) ([]*entity.User, error) List() ([]*entity.User, error) }
Reader interface
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service interface
func (*Service) CreateUser ¶
CreateUser Create an user
func (*Service) DeleteUser ¶
DeleteUser Delete an user
func (*Service) SearchUsers ¶
SearchUsers Search users
type UseCase ¶
type UseCase interface { GetUser(id entity.ID) (*entity.User, error) SearchUsers(query string) ([]*entity.User, error) ListUsers() ([]*entity.User, error) CreateUser(email, password, firstName, lastName string) (entity.ID, error) UpdateUser(e *entity.User) error DeleteUser(id entity.ID) error }
UseCase interfacce
Click to show internal directories.
Click to hide internal directories.