services

package
v0.0.0-...-226c3a4 Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2020 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type DefaultProductsService

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

func (*DefaultProductsService) Get

func (s *DefaultProductsService) Get(c context.Context, productID uint64) (p *models.User, err error)

type DefaultUserService

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

func (*DefaultUserService) CreateSession

func (s *DefaultUserService) CreateSession(c context.Context, username, password string) (token string, err error)

func (*DefaultUserService) CreateUser

func (s *DefaultUserService) CreateUser(c context.Context, username, password, email string) (*models.User, error)

func (DefaultUserService) Update

func (d DefaultUserService) Update(c context.Context, ID uint64) error

type ProductsService

type ProductsService interface {
	Get(c context.Context, ID uint64) (*models.User, error)
}

func CreateProductsService

func CreateProductsService(cf string, usersClients protobuf_spec.UsersClient) (ProductsService, error)

func NewProductService

func NewProductService(logger *zap.Logger, usersSrv proto.UsersClient) ProductsService

type UserService

type UserService interface {
	CreateUser(c context.Context, username, password, email string) (*models.User, error)
	Update(c context.Context, ID uint64) error
	CreateSession(c context.Context, username, password string) (token string, err error)
}

func NewUserService

func NewUserService(logger *zap.Logger, usersSrv proto.UsersClient) UserService

Jump to

Keyboard shortcuts

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