util

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2025 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FloatPtr added in v0.1.1

func FloatPtr(f float64) *float64

func GetBool

func GetBool(value bool, defaultValue bool) bool

Returns the true if value or defaultValue are true

func GetFloat

func GetFloat(values ...float64) float64

Returns the first non-zero float

func GetFloatPtr added in v0.1.1

func GetFloatPtr(values ...*float64) *float64

func GetInt

func GetInt(values ...int) int

Returns the first non-zero int

func GetString

func GetString(values ...string) string

Returns the first non-empty string

func MaxInt

func MaxInt(a ...int) int

MaxInt returns the highest value int in a variadic list of ints

func MinInt

func MinInt(a ...int) int

MinInt returns the lowest value int in a variadic list of ints

func Round added in v0.1.1

func Round(x, unit float64) float64

Types

This section is empty.

Jump to

Keyboard shortcuts

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