reflectutils

package
v1.5.11 Latest Latest
Warning

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

Go to latest
Published: May 15, 2024 License: GPL-3.0 Imports: 3 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssignBoolValue

func AssignBoolValue(data any, val reflect.Value) error

AssignBoolValue 将any类型的值进行转化,赋值给bool类型的reflect.Value

func AssignFloat64Value added in v1.5.6

func AssignFloat64Value(data any, val reflect.Value) error

AssignFloat64Value 将any类型的值进行转化,赋值给float64类型的reflect.Value

func AssignInt64Value added in v1.5.6

func AssignInt64Value(data any, val reflect.Value) error

AssignInt64Value 将any类型的值进行转化,赋值给int64类型的reflect.Value

func AssignStringValue

func AssignStringValue(data any, val reflect.Value) error

AssignStringValue 将any类型的值进行转化,赋值给string的reflect.Value

func AssignUint64Value added in v1.5.6

func AssignUint64Value(data any, val reflect.Value) error

AssignUint64Value 将any类型的值进行转化,赋值给uint64类型的reflect.Value

func GroupTypeKind added in v1.5.8

func GroupTypeKind(t reflect.Type) reflect.Kind

GroupTypeKind 将反射的Kind值进行聚集

func GroupValueKind

func GroupValueKind(v reflect.Value) reflect.Kind

GroupValueKind 将反射的Kind值进行聚集

func IsSliceTypeOf added in v1.5.8

func IsSliceTypeOf(t reflect.Type, elementKind reflect.Kind) bool

func IsSliceValueOf added in v1.5.8

func IsSliceValueOf(v reflect.Value, elementKind reflect.Kind) bool

func IsTypeFloat added in v1.5.8

func IsTypeFloat(t reflect.Type) bool

func IsTypeInteger added in v1.5.8

func IsTypeInteger(t reflect.Type) bool

func IsTypeStructOrStructPointer added in v1.5.8

func IsTypeStructOrStructPointer(t reflect.Type) bool

func IsTypeStructPointer added in v1.5.8

func IsTypeStructPointer(t reflect.Type) bool

func IsTypeStructSliceOrStructSlicePointer added in v1.5.9

func IsTypeStructSliceOrStructSlicePointer(t reflect.Type) bool

func IsTypeTime added in v1.5.8

func IsTypeTime(t reflect.Type) bool

func IsTypeTimePointer added in v1.5.8

func IsTypeTimePointer(t reflect.Type) bool

func IsTypeUnsignedInteger added in v1.5.8

func IsTypeUnsignedInteger(t reflect.Type) bool

func IsValueFloat added in v1.5.8

func IsValueFloat(v reflect.Value) bool

func IsValueInteger added in v1.5.8

func IsValueInteger(v reflect.Value) bool

func IsValueStructOrStructPointer added in v1.5.8

func IsValueStructOrStructPointer(v reflect.Value) bool

func IsValueStructPointer added in v1.5.8

func IsValueStructPointer(v reflect.Value) bool

func IsValueStructSliceOrStructSlicePointer added in v1.5.9

func IsValueStructSliceOrStructSlicePointer(v reflect.Value) bool

func IsValueTime added in v1.5.8

func IsValueTime(v reflect.Value) bool

func IsValueTimePointer added in v1.5.8

func IsValueTimePointer(v reflect.Value) bool

func IsValueUnsignedInteger added in v1.5.8

func IsValueUnsignedInteger(v reflect.Value) bool

func PointerTypeElem added in v1.5.8

func PointerTypeElem(t reflect.Type) reflect.Type

func PointerValueElem added in v1.5.8

func PointerValueElem(v reflect.Value) reflect.Value

func SliceTypeElem added in v1.5.8

func SliceTypeElem(t reflect.Type) reflect.Type

func SliceValueElem added in v1.5.8

func SliceValueElem(v reflect.Value) reflect.Value

func ToBool added in v1.5.6

func ToBool(data any) (bool, error)

ToBool 将any类型的值进行转化为bool类型

func ToFloat64 added in v1.5.6

func ToFloat64(data any) (float64, error)

ToFloat64 将any类型的值进行转化为float64类型

func ToInt64 added in v1.5.6

func ToInt64(data any) (int64, error)

ToInt64 将any类型的值进行转化为int64类型

func ToString added in v1.5.6

func ToString(data any) (string, error)

ToString 将any类型的值进行转化为string类型

func ToUint64 added in v1.5.6

func ToUint64(data any) (uint64, error)

ToUint64 将any类型的值进行转化为uint64类型

func Zero added in v1.5.10

func Zero(v *reflect.Value)

Types

This section is empty.

Jump to

Keyboard shortcuts

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