nonempty

package
v0.0.0-...-01ad037 Latest Latest
Warning

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

Go to latest
Published: Aug 13, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Byte

func Byte(value, def byte) byte

Byte if value == byte zero value, return def otherwise return value

func Duration

func Duration(value, def time.Duration) time.Duration

Duration if value == time.Duration zero value, return def otherwise return value

func Float32

func Float32(value, def float32) float32

Float32 if value == float32 zero value, return def otherwise return value

func Float64

func Float64(value, def float64) float64

Float64 if value == float64 zero value, return def otherwise return value

func Int

func Int(value, def int) int

Int if value == int zero value, return def otherwise return value

func Int16

func Int16(value, def int16) int16

Int16 if value == int16 zero value, return def otherwise return value

func Int32

func Int32(value, def int32) int32

Int32 if value == int32 zero value, return def otherwise return value

func Int64

func Int64(value, def int64) int64

Int64 if value == int64 zero value, return def otherwise return value

func Int8

func Int8(value, def int8) int8

Int8 if value == int8 zero value, return def otherwise return value

func Rune

func Rune(value, def rune) rune

Rune if value == rune zero value, return def otherwise return value

func String

func String(value, def string) string

String if value == string zero value, return def otherwise return value

func Struct

func Struct(value, def interface{}) interface{}

Struct if value == struct zero value, return def otherwise return value

func Time

func Time(value, def time.Time) time.Time

Time if value == time.Time zero value, return def otherwise return value

func Uint

func Uint(value, def uint) uint

Uint if value == uint zero value, return def otherwise return value

func Uint16

func Uint16(value, def uint16) uint16

Uint16 if value == uint16 zero value, return def otherwise return value

func Uint32

func Uint32(value, def uint32) uint32

Uint32 if value == uint32 zero value, return def otherwise return value

func Uint64

func Uint64(value, def uint64) uint64

Uint64 if value == uint64 zero value, return def otherwise return value

func Uint8

func Uint8(value, def uint8) uint8

Uint8 if value == uint8 zero value, return def otherwise return value

func Uintptr

func Uintptr(value, def uintptr) uintptr

Uintptr if value == uintptr zero value, return def otherwise return value

Types

This section is empty.

Jump to

Keyboard shortcuts

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