sentinel

package module
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2026 License: MIT Imports: 1 Imported by: 0

README

go-sentinel

CircleCI GoDoc

Package sentinel is a standardization of sentinel values set aside as NULL representations.

Documentation

Overview

Package sentinel is a standardization of sentinel values set aside as NULL representations.

Index

Constants

View Source
const (
	Int    int    = math.MaxInt
	Int64  int64  = math.MaxInt64
	Int32  int32  = math.MaxInt32
	Int16  int16  = math.MaxInt16
	Int8   int8   = math.MaxInt8
	Uint   uint   = math.MaxUint
	Uint64 uint64 = math.MaxUint64
	Uint32 uint32 = math.MaxUint32
	Uint16 uint16 = math.MaxUint16
	Uint8  uint8  = math.MaxUint8
	String string = ""
)

Constant sentinel values. Excludes float64 and float32 values, as NaN is not a constant.

Variables

This section is empty.

Functions

func IsNull

func IsNull(i interface{}) bool

IsNull tests input i for equality with the NULL sentinel value for the type of i.

func NullFloat32

func NullFloat32() float32

NullFloat32 returns the NULL sentinel value for type float32.

func NullFloat64

func NullFloat64() float64

NullFloat64 returns the NULL sentinel value for type float64.

func NullInt added in v1.0.3

func NullInt() int

NullInt returns the NULL sentinel value for type int.

func NullInt8

func NullInt8() int8

NullInt8 returns the NULL sentinel value for type int8.

func NullInt16

func NullInt16() int16

NullInt16 returns the NULL sentinel value for type int16.

func NullInt32

func NullInt32() int32

NullInt32 returns the NULL sentinel value for type int32.

func NullInt64

func NullInt64() int64

NullInt64 returns the NULL sentinel value for type int64.

func NullString

func NullString() string

NullString returns the NULL sentinel value for type string.

func NullUint added in v1.0.3

func NullUint() uint

NullUint returns the NULL sentinel value for type uint.

func NullUint8

func NullUint8() uint8

NullUint8 returns the NULL sentinel value for type uint8.

func NullUint16

func NullUint16() uint16

NullUint16 returns the NULL sentinel value for type uint16.

func NullUint32

func NullUint32() uint32

NullUint32 returns the NULL sentinel value for type uint32.

func NullUint64

func NullUint64() uint64

NullUint64 returns the NULL sentinel value for type uint64.

Types

This section is empty.

Jump to

Keyboard shortcuts

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