utils

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyParallel added in v1.4.1

func ApplyParallel(start, end int, fnc func(start, end int))

ApplyParallel is apply each funcs parallelly

func GetContentTypeByReadSeeker added in v1.3.1

func GetContentTypeByReadSeeker(reader io.ReadSeeker) (string, error)

GetContentTypeByReadSeeker is get content type by Readseeker

func GetOsEnv added in v1.1.1

func GetOsEnv(key, defaultdata string) string

GetOsEnv is get os env with default value

func GetOsEnvInt added in v1.1.1

func GetOsEnvInt(key string, defaultdata int) int

GetOsEnvInt is get os env with default value converting to int

func InRanged added in v1.4.0

func InRanged(value, min, max float64) float64

InRanged return value in range

func IntArrayContains

func IntArrayContains(arr []int, num int) bool

IntArrayContains checks contains int in int array

func RoundFloat

func RoundFloat(input float64, decimals int) float64

RoundFloat rounds input float64 with decimals

func StringArrayContains

func StringArrayContains(arr []string, str string) bool

StringArrayContains checks contains string in string array

func StringArrayContainsForwardMatch

func StringArrayContainsForwardMatch(arr []string, str string) bool

StringArrayContainsForwardMatch checks contains string in string array with forward match

Types

This section is empty.

Jump to

Keyboard shortcuts

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