Documentation
¶
Index ¶
- Variables
- func ErrorArrayToStringArray(errorArray *[]error) *[]string
- func PrettyDuration(d time.Duration, minUnit string) (string, error)
- func ToBool(value string, dest interface{}) error
- func ToFloat32(value string, dest interface{}) error
- func ToFloat64(value string, dest interface{}) error
- func ToInt(value string, dest interface{}) error
- func ToInt16(value string, dest interface{}) error
- func ToInt32(value string, dest interface{}) error
- func ToInt64(value string, dest interface{}) error
- func ToInt8(value string, dest interface{}) error
- func ToString(value string, dest interface{}) error
- func ToUint(value string, dest interface{}) error
- func ToUint16(value string, dest interface{}) error
- func ToUint32(value string, dest interface{}) error
- func ToUint64(value string, dest interface{}) error
- func ToUint8(value string, dest interface{}) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidDestinationType = "invalid destination type, expected: '%s'" ErrParseIntFailed = "cannot parse '%s', expected integer" ErrParseInt8Failed = "cannot parse '%s', expected integer of 8 bits" ErrParseInt16Failed = "cannot parse '%s', expected integer of 16 bits" ErrParseInt32Failed = "cannot parse '%s', expected integer of 32 bits" ErrParseInt64Failed = "cannot parse '%s', expected integer of 64 bits" ErrParseUintFailed = "cannot parse '%s', expected unsigned integer" ErrParseUint8Failed = "cannot parse '%s', expected unsigned integer of 8 bits" ErrParseUint16Failed = "cannot parse '%s', expected unsigned integer of 16 bits" ErrParseUint32Failed = "cannot parse '%s', expected unsigned integer of 32 bits" ErrParseUint64Failed = "cannot parse '%s', expected unsigned integer of 64 bits" ErrParseFloat32Failed = "cannot parse '%s', expected float of 32 bits" ErrParseFloat64Failed = "cannot parse '%s', expected float of 64 bits" ErrParseBoolFailed = "cannot parse '%s', expected boolean" ErrInvalidDurationUnit = "invalid duration unit, expected: '%s'" )
Functions ¶
func ErrorArrayToStringArray ¶
ErrorArrayToStringArray maps an array of errors to an array of strings
func PrettyDuration ¶ added in v0.1.10
PrettyDuration formats a duration without zero units
func ToFloat32 ¶ added in v0.1.2
ToFloat32 sets the destination to the value of the string as a float32
func ToFloat64 ¶ added in v0.1.2
ToFloat64 sets the destination to the value of the string as a float64
func ToUint16 ¶ added in v0.1.2
ToUint16 sets the destination to the value of the string as an uint16
func ToUint32 ¶ added in v0.1.2
ToUint32 sets the destination to the value of the string as an uint32
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.