Documentation ¶
Overview ¶
Package price implements functions to ease working with digitalbits price values. At present, prices are only used within the offer system, and are represented by a fraction whose numberator and denominator are both 32-bit signed integers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Parse ¶
Parse calculates and returns the best rational approximation of the given real number price while still keeping both the numerator and the denominator of the resulting value within the precision limits of a 32-bit signed integer..
func StringFromFloat64 ¶
StringFromFloat64 will format a float64 to decimal representation with 7 digits after the decimal point
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.