MCPcopy
hub / github.com/shopspring/decimal / StringFixedCash

Method StringFixedCash

decimal.go:1511–1514  ·  view source on GitHub ↗

StringFixedCash returns a Swedish/Cash rounded fixed-point string. For more details see the documentation at function RoundCash.

(interval uint8)

Source from the content-addressed store, hash-verified

1509// StringFixedCash returns a Swedish/Cash rounded fixed-point string. For
1510// more details see the documentation at function RoundCash.
1511func (d Decimal) StringFixedCash(interval uint8) string {
1512 rounded := d.RoundCash(interval)
1513 return rounded.string(false)
1514}
1515
1516// Round rounds the decimal to places decimal places.
1517// If places < 0, it will round the integer part to the nearest 10^(-places).

Callers 1

Calls 2

RoundCashMethod · 0.95
stringMethod · 0.80

Tested by 1