empty

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package empty provides functions for checking empty/nil variables.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsEmpty

func IsEmpty(value any, traceSource ...bool) bool

IsEmpty checks whether given `value` empty. It returns true if `value` is in: 0, nil, false, "", len(slice/map/chan) == 0, or else it returns false.

func IsEmptyOrZero added in v0.0.7

func IsEmptyOrZero(value any, traceSource ...bool) bool

IsEmptyOrZero checks whether given `value` is empty or zero.

func IsNil

func IsNil(value any, _ ...bool) bool

IsNil checks whether given `value` is nil.

func IsZero added in v0.0.7

func IsZero(value any, _ ...bool) bool

IsZero checks whether given `value` is zero value.

Types

This section is empty.

Jump to

Keyboard shortcuts

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