flect

package
v0.0.0-...-8f66fda Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ZeroVal = zeroVal{}

Functions

func IndirectInterface

func IndirectInterface(v interface{}) (indirect interface{}, ok bool)

func IndirectType

func IndirectType(v interface{}) reflect.Type

func IndirectValue

func IndirectValue(v interface{}, mustSet bool) (reflect.Value, gomerr.Gomerr)

func ReadableIndirectValue

func ReadableIndirectValue(v interface{}) (indirectValue reflect.Value, ok bool)

func SetValue

func SetValue(targetValue reflect.Value, value interface{}) gomerr.Gomerr

func StringToType

func StringToType(valueString string, targetType reflect.Type) (interface{}, gomerr.Gomerr)

StringToType returns a value corresponding to the provided targetType. If the targetType isn't recognized, this returns nil rather than an error. An error occurs if the targetType is recognized, but it's not possible to convert the string into that type.

Types

This section is empty.

Jump to

Keyboard shortcuts

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