util

package
v0.0.0-...-2b42cf3 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractContextValue

func ExtractContextValue(ctx context.Context, key string) string

ExtractContextValue extracts the value by key

func GetCurrentISOTime

func GetCurrentISOTime() string

func IsEven

func IsEven(number int) bool

IsEven determines whether or not a number is even

func SumAccountBalances

func SumAccountBalances(accountA int, accountB int, client BankConnection) (float64, error)

SumAccountBalances sum the amount of two accounts

Types

type BankConnection

type BankConnection interface {
	GetBalanceByID(id int) (float64, error)
}

BankConnection interface definition

func GetBankConnection

func GetBankConnection() BankConnection

GetBankConnection gets a connection to a bank

Jump to

Keyboard shortcuts

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