Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var JSONNumberType = reflect.TypeOf(json.Number(""))
JSONNumberType is the reflect.Type of encoding/json.Number. Marshaling code recognizes it and emits a DynamoDB N value so a decoded number that cannot be represented exactly by int64 or float64 survives a rewrite unchanged.
Functions ¶
func ClampIntToInt32 ¶
ClampIntToInt32 converts n to int32, clamping to the int32 range.
func ParseNumber ¶
ParseNumber converts a DynamoDB numeric string into a Go value that preserves the exact persisted value. Integers that fit int64 become int64; decimals that a float64 reproduces exactly become float64; every other valid number becomes json.Number so no precision is lost. Malformed input returns an error.
func ParseNumberSet ¶
ParseNumberSet converts DynamoDB number-set elements with the same exactness guarantees as ParseNumber.
Types ¶
This section is empty.