import "gitoa.ru/go-4devs/translation/arg"
Arg defaults argument.
String arg to string.
Val gets valuet argument.
type Currency struct { Key string Value interface{} Format FormatCurrency // ISO 3-letter ISO 4217 ISO string }
Currency argument.
String gets string from currency.
Val gets value currency.
CurrencyOption configures option.
func WithCurrencyFormat(format FormatCurrency) CurrencyOption
WithCurrencyFormat sets format currency.
func WithCurrencyISO(iso string) CurrencyOption
WithCurrencyISO sets ISO 4217 code currecy.
FormatCurrency types format.
const ( CurrencyFormat FormatCurrency = iota CurrencyFormatSymbol CurrencyFormatISO CurrencyFormatNarrowSymbol )
Currency format.
FormatNumber format number.
const ( NumberFormatUndefined FormatNumber = iota NumberFormatDecimal NumberFormatPercent NumberFormatPerMille NumberFormatEngineering NumberFormatScientific )
format argument.
type Number struct { Key string Value interface{} Format FormatNumber }
Number argument.
func (n Number) Configure(opts ...NumberOption) Number
Configure number.
String number to string.
Val gets number value.
NumberOption configure number argument.
func WithNumberFormat(format FormatNumber) NumberOption
WithNumberFormat sets format number.
Package arg imports 1 packages (graph) and is imported by 2 packages. Updated 2020-05-20. Refresh now. Tools for package owners.