account

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

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

func (*Account) ChangePassword

func (a *Account) ChangePassword(accountID uuid.UUID, password string) error

func (*Account) CreateAccount

func (a *Account) CreateAccount(account *accountEntities.Account) error

func (*Account) Login

func (*Account) Logout

func (a *Account) Logout(accountID uuid.UUID) error

func (*Account) RenewToken

func (a *Account) RenewToken(refreshToken, accessToken string) (*accountEntities.LoginResponse, error)

func (*Account) SendResetPasswordCode

func (a *Account) SendResetPasswordCode(email string) error

func (*Account) ValidateEmail

func (a *Account) ValidateEmail(accountID uuid.UUID) error

func (*Account) VerifyResetPasswordCode

func (a *Account) VerifyResetPasswordCode(data *accountEntities.ResetCodeData) (string, error)

type IAccount

type IAccount interface {
	CreateAccount(account *accountEntities.Account) error
	Login(loginData *accountEntities.LoginData) (*accountEntities.LoginResponse, error)
	ValidateEmail(accountID uuid.UUID) error
	SendResetPasswordCode(email string) error
	VerifyResetPasswordCode(data *accountEntities.ResetCodeData) (string, error)
	ChangePassword(accountID uuid.UUID, password string) error
	RenewToken(refreshToken, accessToken string) (*accountEntities.LoginResponse, error)
	Logout(accountID uuid.UUID) error
	// contains filtered or unexported methods
}

func NewAccountController

func NewAccountController(broker brokerLib.IBroker, databaseRead SQL.InterfaceRead,
	databaseWrite SQL.InterfaceWrite, cacheRepository cache.Interface, useCases accountUseCases.IAccount,
	appConfig app.IAppConfig) IAccount

Jump to

Keyboard shortcuts

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