exchangerate

package
v1.10.20 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLatestExchangeRateTime

func GetLatestExchangeRateTime() time.Time

GetLatestExchangeRateTime gets the latest time for fetching an exchange rate. By synchronizing on a time, we can eliminate the amount of perceived volatility over short time spans.

func GetPotentialClientExchangeRates

func GetPotentialClientExchangeRates(ctx context.Context, data code_data.Provider, code currency_lib.Code) ([]*currency.ExchangeRateRecord, error)

GetPotentialClientExchangeRates gets a set of exchange rates that a client attempting to maintain a latest state could have fetched from the currency server.

func ValidateClientExchangeData

func ValidateClientExchangeData(ctx context.Context, data code_data.Provider, proto *transactionpb.ExchangeData) (bool, string, error)

ValidateClientExchangeData validates proto exchange data provided by a client

Types

This section is empty.

Jump to

Keyboard shortcuts

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