conv

package
Version: v0.0.0-...-9cbcb7c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 7, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToBool

func ToBool(i interface{}) bool

ToBool casts an interface to a bool type.

func ToBoolDefault

func ToBoolDefault(i interface{}, defaultValue bool) bool

ToBool casts an interface to a bool type.

func ToBoolE

func ToBoolE(i interface{}) (bool, error)

ToBool casts an interface to a bool type.

func ToBoolSlice

func ToBoolSlice(i interface{}) []bool

ToBoolSlice casts an interface to a []bool type.

func ToBoolSliceE

func ToBoolSliceE(i interface{}) ([]bool, error)

ToBoolSlice casts an interface to a []bool type.

func ToBytes

func ToBytes(i interface{}) []byte

func ToBytesE

func ToBytesE(i interface{}) ([]byte, error)

func ToDuration

func ToDuration(i interface{}) time.Duration

ToDuration casts an interface to a time.Duration type.

func ToDurationDefault

func ToDurationDefault(i interface{}, defaultValue time.Duration) time.Duration

ToDuration casts an interface to a time.Duration type.

func ToDurationE

func ToDurationE(i interface{}) (time.Duration, error)

ToDuration casts an interface to a time.Duration type.

func ToDurationSlice

func ToDurationSlice(i interface{}) []time.Duration

ToDurationSlice casts an interface to a []time.Duration type.

func ToDurationSliceE

func ToDurationSliceE(i interface{}) ([]time.Duration, error)

ToDurationSlice casts an interface to a []time.Duration type.

func ToFloat32

func ToFloat32(i interface{}) float32

ToFloat32 casts an interface to a float32 type.

func ToFloat32Default

func ToFloat32Default(i interface{}, defaultValue float32) float32

ToFloat32 casts an interface to a float32 type.

func ToFloat32E

func ToFloat32E(i interface{}) (float32, error)

ToFloat32 casts an interface to a float32 type.

func ToFloat64

func ToFloat64(i interface{}) float64

ToFloat64 casts an interface to a float64 type.

func ToFloat64Default

func ToFloat64Default(i interface{}, defaultValue float64) float64

ToFloat64 casts an interface to a float64 type.

func ToFloat64E

func ToFloat64E(i interface{}) (float64, error)

ToFloat64 casts an interface to a float64 type.

func ToInt

func ToInt(i interface{}) int

ToInt casts an interface to an int type.

func ToInt16

func ToInt16(i interface{}) int16

ToInt16 casts an interface to an int16 type.

func ToInt16Default

func ToInt16Default(i interface{}, defaultValue int16) int16

ToInt16 casts an interface to an int16 type.

func ToInt16E

func ToInt16E(i interface{}) (int16, error)

ToInt16 casts an interface to an int16 type.

func ToInt32

func ToInt32(i interface{}) int32

ToInt32 casts an interface to an int32 type.

func ToInt32Default

func ToInt32Default(i interface{}, defaultValue int32) int32

ToInt32 casts an interface to an int32 type.

func ToInt32E

func ToInt32E(i interface{}) (int32, error)

ToInt32 casts an interface to an int32 type.

func ToInt64

func ToInt64(i interface{}) int64

ToInt64 casts an interface to an int64 type.

func ToInt64Default

func ToInt64Default(i interface{}, defaultValue int64) int64

ToInt64 casts an interface to an int64 type.

func ToInt64E

func ToInt64E(i interface{}) (int64, error)

ToInt64 casts an interface to an int64 type.

func ToInt8

func ToInt8(i interface{}) int8

ToInt8 casts an interface to an int8 type.

func ToInt8Default

func ToInt8Default(i interface{}, defaultValue int8) int8

ToInt8 casts an interface to an int8 type.

func ToInt8E

func ToInt8E(i interface{}) (int8, error)

ToInt8 casts an interface to an int8 type.

func ToIntDefault

func ToIntDefault(i interface{}, defaultValue int) int

ToInt casts an interface to an int type.

func ToIntE

func ToIntE(i interface{}) (int, error)

ToInt casts an interface to an int type.

func ToIntSlice

func ToIntSlice(i interface{}) []int

ToIntSlice casts an interface to a []int type.

func ToIntSliceE

func ToIntSliceE(i interface{}) ([]int, error)

ToIntSlice casts an interface to a []int type.

func ToSlice

func ToSlice(i interface{}) []interface{}

ToSlice casts an interface to a []interface{} type.

func ToSliceE

func ToSliceE(i interface{}) ([]interface{}, error)

ToSlice casts an interface to a []interface{} type.

func ToString

func ToString(i interface{}) string

ToString casts an interface to a string type.

func ToStringDefault

func ToStringDefault(i interface{}, defaultValue string) string

ToString casts an interface to a string type.

func ToStringE

func ToStringE(i interface{}) (string, error)

ToString casts an interface to a string type.

func ToStringMap

func ToStringMap(i interface{}) map[string]interface{}

ToStringMap casts an interface to a map[string]interface{} type.

func ToStringMapBool

func ToStringMapBool(i interface{}) map[string]bool

ToStringMapBool casts an interface to a map[string]bool type.

func ToStringMapBoolE

func ToStringMapBoolE(i interface{}) (map[string]bool, error)

ToStringMapBool casts an interface to a map[string]bool type.

func ToStringMapE

func ToStringMapE(i interface{}) (map[string]interface{}, error)

ToStringMap casts an interface to a map[string]interface{} type.

func ToStringMapInt

func ToStringMapInt(i interface{}) map[string]int

ToStringMapInt casts an interface to a map[string]int type.

func ToStringMapInt64

func ToStringMapInt64(i interface{}) map[string]int64

ToStringMapInt64 casts an interface to a map[string]int64 type.

func ToStringMapInt64E

func ToStringMapInt64E(i interface{}) (map[string]int64, error)

ToStringMapInt64 casts an interface to a map[string]int64 type.

func ToStringMapIntE

func ToStringMapIntE(i interface{}) (map[string]int, error)

ToStringMapInt casts an interface to a map[string]int type.

func ToStringMapString

func ToStringMapString(i interface{}) map[string]string

ToStringMapString casts an interface to a map[string]string type.

func ToStringMapStringE

func ToStringMapStringE(i interface{}) (map[string]string, error)

ToStringMapString casts an interface to a map[string]string type.

func ToStringMapStringSlice

func ToStringMapStringSlice(i interface{}) map[string][]string

ToStringMapStringSlice casts an interface to a map[string][]string type.

func ToStringMapStringSliceE

func ToStringMapStringSliceE(i interface{}) (map[string][]string, error)

ToStringMapStringSlice casts an interface to a map[string][]string type.

func ToStringSlice

func ToStringSlice(i interface{}) []string

ToStringSlice casts an interface to a []string type.

func ToStringSliceE

func ToStringSliceE(i interface{}) ([]string, error)

ToStringSlice casts an interface to a []string type.

func ToTime

func ToTime(i interface{}) time.Time

ToTime casts an interface to a time.Time type.

func ToTimeE

func ToTimeE(i interface{}) (time.Time, error)

ToTime casts an interface to a time.Time type.

func ToUint

func ToUint(i interface{}) uint

ToUint casts an interface to a uint type.

func ToUint16

func ToUint16(i interface{}) uint16

ToUint16 casts an interface to a uint16 type.

func ToUint16Default

func ToUint16Default(i interface{}, defaultValue uint16) uint16

ToUint16 casts an interface to a uint16 type.

func ToUint16E

func ToUint16E(i interface{}) (uint16, error)

ToUint16 casts an interface to a uint16 type.

func ToUint32

func ToUint32(i interface{}) uint32

ToUint32 casts an interface to a uint32 type.

func ToUint32Default

func ToUint32Default(i interface{}, defaultValue uint32) uint32

ToUint32 casts an interface to a uint32 type.

func ToUint32E

func ToUint32E(i interface{}) (uint32, error)

ToUint32 casts an interface to a uint32 type.

func ToUint64

func ToUint64(i interface{}) uint64

ToUint64 casts an interface to a uint64 type.

func ToUint64Default

func ToUint64Default(i interface{}, defaultValue uint64) uint64

ToUint64 casts an interface to a uint64 type.

func ToUint64E

func ToUint64E(i interface{}) (uint64, error)

ToUint64 casts an interface to a uint64 type.

func ToUint8

func ToUint8(i interface{}) uint8

ToUint8 casts an interface to a uint8 type.

func ToUint8Default

func ToUint8Default(i interface{}, defaultValue uint8) uint8

ToUint8 casts an interface to a uint8 type.

func ToUint8E

func ToUint8E(i interface{}) (uint8, error)

ToUint8 casts an interface to a uint8 type.

func ToUintDefault

func ToUintDefault(i interface{}, defaultValue uint) uint

ToUint casts an interface to a uint type.

func ToUintE

func ToUintE(i interface{}) (uint, error)

ToUint casts an interface to a uint type.

Types

This section is empty.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL