Documentation
¶
Index ¶
Constants ¶
View Source
const EPSILON float64 = 1e-9
View Source
const FALSE_STRINGS = "no,false,off,0,"
View Source
const HASH = MAP
compatible with old version
Variables ¶
This section is empty.
Functions ¶
func Bool ¶
func Bool(obj interface{}) bool
Bool try to get bool value of given object. number: 0 => false, otherwise => true string: ("", "false", "off", "no", "0") => false (case insensitive), otherwise => true nil: false otherwise: true
func Bytes ¶
func Bytes(obj interface{}) []byte
Bytes try to get []byte value of given object see String()
func Float ¶
func Float(obj interface{}) float64
Float try to get float value of given object. number: type cast bool: true => 1.0 false => 0.0 string: empty => 0, otherwise parse float nil && otherwise: 0.0
func Int ¶
func Int(obj interface{}) int64
Int try to get int64 value of given object. number : type cast bool: true => 1, false => 0, string: empty => 0, otherwise parse int nil & otherwise : 0
Types ¶
Click to show internal directories.
Click to hide internal directories.