vo

package
v0.0.0-...-c877830 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Verify

func Verify(pin string, p Pin) error

func VerifyPassword

func VerifyPassword(password string, hashedPassword []byte) error

func VerifyRecover

func VerifyRecover(recoveryPin string, p Pin) error

Types

type Amount

type Amount float64

func NewAmount

func NewAmount(amount float64, isNew bool) (Amount, error)

type CreditorName

type CreditorName string

func NewCreditor

func NewCreditor(name string) (CreditorName, error)

func (*CreditorName) String

func (cr *CreditorName) String() string

type Currency

type Currency string
const (
	EURO Currency = "EUR"
	USD  Currency = "USD"
	GBP  Currency = "GBP"
)

func NewCurrency

func NewCurrency(currency string) (Currency, error)

func (*Currency) String

func (c *Currency) String() string

type EmailAddress

type EmailAddress struct {
	Value string
}

func CreateEmailAddress

func CreateEmailAddress(emailAddress string) (*EmailAddress, error)

type EmailAddressError

type EmailAddressError struct {
	ErrorMsg string
}

func (EmailAddressError) Error

func (e EmailAddressError) Error() string

type Money

type Money struct {
	Amount   Amount
	Currency Currency
}

func NewMoney

func NewMoney(amount Amount, currency Currency) *Money

type MoneyConverted

type MoneyConverted float64

func NewMoneyConverted

func NewMoneyConverted(amount Amount, to, from Currency) MoneyConverted

type Owner

type Owner string

func NewOwner

func NewOwner(userId string) (Owner, error)

func (*Owner) String

func (o *Owner) String() string

type Password

type Password struct {
	Value []byte
}

func CreatePassword

func CreatePassword(password string) (Password, error)

type PasswordError

type PasswordError struct {
	ErrorMsg string
}

func (PasswordError) Error

func (e PasswordError) Error() string

type Pin

type Pin struct {
	HashValue    []byte
	RecoverValue string
}

func NewPin

func NewPin(pin PinValue) *Pin

type PinError

type PinError struct {
	ErrorMsg string
}

func (PinError) Error

func (e PinError) Error() string

type PinValue

type PinValue string

func NewPinValue

func NewPinValue(val string) (PinValue, error)

func (*PinValue) String

func (p *PinValue) String() string

type TypeError

type TypeError struct {
	ErrorMsg string
}

func (TypeError) Error

func (e TypeError) Error() string

type WalletNumber

type WalletNumber string

func NewWalletNumber

func NewWalletNumber(walletNo string) (WalletNumber, error)

func (*WalletNumber) String

func (w *WalletNumber) String() string

Jump to

Keyboard shortcuts

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