Documentation
¶
Index ¶
- func Bool(v bool) *bool
- func BoolVal(ptr *bool) (val bool, ok bool)
- func Byte(v byte) *byte
- func ByteVal(ptr *byte) (val byte, ok bool)
- func Complex64(v complex64) *complex64
- func Complex64Val(ptr *complex64) (val complex64, ok bool)
- func Complex128(v complex128) *complex128
- func Complex128Val(ptr *complex128) (val complex128, ok bool)
- func Duration(v time.Duration) *time.Duration
- func DurationVal(ptr *time.Duration) (val time.Duration, ok bool)
- func Float32(v float32) *float32
- func Float32Val(ptr *float32) (val float32, ok bool)
- func Float64(v float64) *float64
- func Float64Val(ptr *float64) (val float64, ok bool)
- func Int(v int) *int
- func Int8(v int8) *int8
- func Int8Val(ptr *int8) (val int8, ok bool)
- func Int16(v int16) *int16
- func Int16Val(ptr *int16) (val int16, ok bool)
- func Int32(v int32) *int32
- func Int32Val(ptr *int32) (val int32, ok bool)
- func Int64(v int64) *int64
- func Int64Val(ptr *int64) (val int64, ok bool)
- func IntVal(ptr *int) (val int, ok bool)
- func Interface(v interface{}) *interface{}
- func InterfaceVal(ptr *interface{}) (val interface{}, ok bool)
- func Pointer[T any](val T) *T
- func Rune(v rune) *rune
- func RuneVal(ptr *rune) (val rune, ok bool)
- func String(v string) *string
- func StringVal(ptr *string) (val string, ok bool)
- func Time(v time.Time) *time.Time
- func TimeVal(ptr *time.Time) (val time.Time, ok bool)
- func Uint(v uint) *uint
- func Uint8(v uint8) *uint8
- func Uint8Val(ptr *uint8) (val uint8, ok bool)
- func Uint16(v uint16) *uint16
- func Uint16Val(ptr *uint16) (val uint16, ok bool)
- func Uint32(v uint32) *uint32
- func Uint32Val(ptr *uint32) (val uint32, ok bool)
- func Uint64(v uint64) *uint64
- func Uint64Val(ptr *uint64) (val uint64, ok bool)
- func UintVal(ptr *uint) (val uint, ok bool)
- func Uintptr(v uintptr) *uintptr
- func UintptrVal(ptr *uintptr) (val uintptr, ok bool)
- func Unpoint(v interface{}) interface{}
- func Value[T any](ptr *T) (T, bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BoolVal ¶
BoolVal returns the value of the boolean pointer and "true" or "false" and "false" if the pointer is nil
func ByteVal ¶
ByteVal returns the value of the byte pointer and "true" or 0 and "false" if the pointer is nil
func Complex64Val ¶
Complex64Val returns the value of the complex64 pointer and "true" or 0 and "false" if the pointer is nil
func Complex128 ¶
func Complex128(v complex128) *complex128
Complex128 creates a pointer to the provided complex128 value
func Complex128Val ¶
func Complex128Val(ptr *complex128) (val complex128, ok bool)
Complex128Val returns the value of the complex128 pointer and "true" or 0 and "false" if the pointer is nil
func DurationVal ¶
DurationVal returns the value of the time.Duration pointer and "true" or 0 and "false" if the pointer is nil
func Float32Val ¶
Float32Val returns the value of the float32 pointer and "true" or 0 and "false" if the pointer is nil
func Float64Val ¶
Float64Val returns the value of the float64 pointer and "true" or 0 and "false" if the pointer is nil
func Int8Val ¶
Int8Val returns the value of the int8 pointer and "true" or 0 and "false" if the pointer is nil
func Int16Val ¶
Int16Val returns the value of the int16 pointer and "true" or 0 and "false" if the pointer is nil
func Int32Val ¶
Int32Val returns the value of the int32 pointer and "true" or 0 and "false" if the pointer is nil
func Int64Val ¶
Int64Val returns the value of the int64 pointer and "true" or 0 and "false" if the pointer is nil
func IntVal ¶
IntVal returns the value of the int pointer and "true" or 0 and "false" if the pointer is nil
func Interface ¶
func Interface(v interface{}) *interface{}
Interface creates a pointer to the provided interface{} value
func InterfaceVal ¶
func InterfaceVal(ptr *interface{}) (val interface{}, ok bool)
InterfaceVal returns the value of the interface{} pointer and "true" or nil and "false" if the pointer is nil
func Pointer ¶ added in v1.1.0
func Pointer[T any](val T) *T
Pointer returns a pointer to provided value.
func RuneVal ¶
RuneVal returns the value of the rune pointer and "true" or 0 and "false" if the pointer is nil
func StringVal ¶
StringVal returns the value of the string pointer and "true" or an empty string
and "false" if the pointer is nil
func TimeVal ¶
TimeVal returns the value of the time.Time pointer and "true" or zero time.Time and "false" if the pointer is nil
func Uint8Val ¶
Uint8Val returns the value of the uint8 pointer and "true" or 0 and "false" if the pointer is nil
func Uint16Val ¶
Uint16Val returns the value of the uint16 pointer and "true" or 0 and "false" if the pointer is nil
func Uint32Val ¶
Uint32Val returns the value of the uint32 pointer and "true" or 0 and "false" if the pointer is nil
func Uint64Val ¶
Uint64Val returns the value of the uint64 pointer and "true" or 0 and "false" if the pointer is nil
func UintVal ¶
UintVal returns the value of the uint pointer and "true" or 0 and "false" if the pointer is nil
func UintptrVal ¶
UintptrVal returns the value of the uintptr pointer and "true" or 0 and "false" if the pointer is nil
Types ¶
This section is empty.