services

package
v0.0.0-...-65dd222 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProfileManager

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

func NewProfileManager

func NewProfileManager(userRepository *repositories.UserRepository) *ProfileManager

func (*ProfileManager) GetProfileByID

func (s *ProfileManager) GetProfileByID(ctx context.Context, ID string) (*models.User, error)

func (*ProfileManager) GetProfileByUsername

func (s *ProfileManager) GetProfileByUsername(ctx context.Context, username string) (*models.User, error)

func (*ProfileManager) Login

func (s *ProfileManager) Login(ctx context.Context, email, password string) (*models.User, string, error)

func (*ProfileManager) Register

func (s *ProfileManager) Register(ctx context.Context, model *models.User, password string) (string, error)

func (*ProfileManager) UpdateProfile

func (s *ProfileManager) UpdateProfile(ctx context.Context, subjectEmail, clientUsername, password string, model *models.User) (string, error)

type UserGetter

type UserGetter interface {
	GetUserByEmail(ctx context.Context, email string) (*models.User, error)
	GetUserByUsername(ctx context.Context, username string) (*models.User, error)
	GetUserByID(ctx context.Context, ID string) (*models.User, error)
}

Jump to

Keyboard shortcuts

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