types

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bool

func Bool(value interface{}) bool

将值转换成bool类型

func Byte

func Byte(value interface{}) byte

将值转换成byte

func Compare

func Compare(value1 interface{}, value2 interface{}) bool

比较两个值大小

func Float32

func Float32(value interface{}) float32

将值转换成float32

func Float64

func Float64(value interface{}) float64

将值转换成float64

func Int

func Int(value interface{}) int

将值转换成int

func Int8

func Int8(value interface{}) int8

将值转换成int8

func Int16

func Int16(value interface{}) int16

将值转换成int16

func Int32

func Int32(value interface{}) int32

将值转换成int32

func Int64

func Int64(value interface{}) int64

将值转换成int64

func IsFloat

func IsFloat(value interface{}) bool

判断是否为浮点型数字

func IsInteger

func IsInteger(value interface{}) bool

判断是否为整形数字

func IsMap

func IsMap(value interface{}) bool

判断是否为Map

func IsNil

func IsNil(value interface{}) bool

判断是否为nil

func IsNumber

func IsNumber(value interface{}) bool

判断是否为数字

func IsSlice

func IsSlice(value interface{}) bool

判断是否为Slice

func Slice

func Slice(fromSlice interface{}, toSliceType reflect.Type) (interface{}, error)

转换Slice类型

func String

func String(value interface{}) string

将值转换成字符串

func Uint

func Uint(value interface{}) uint

将值转换成uint

func Uint8

func Uint8(value interface{}) uint8

将值转换成uint8

func Uint16

func Uint16(value interface{}) uint16

将值转换成uint16

func Uint32

func Uint32(value interface{}) uint32

将值转换成uint32

func Uint64

func Uint64(value interface{}) uint64

将值转换成uint64

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址