Documentation
¶
Index ¶
- Variables
- func AbsPercentDifference(current float64, previous float64) (difference float64)
- func AllSequentialIncreasesLessThan[T Number](elements []T, limit float64) (bool, float64)
- func ApproximatelyEqual[T float32 | float64](truth T, maybe T, fudge T) bool
- func CalculateAverage[T Number](elements []T) float64
- func CalculatePercentile[T Number](elements []T, p uint) (result T)
- func CalculateStandardDeviation[T constraints.Float | constraints.Integer](elements []T) float64
- func ChannelToSlice[S any](channel <-chan S) (slice []S)
- func Conditional[T any](condition bool, t T, f T) T
- func ContextSignaler(ctxt context.Context, st time.Duration, condition *func() bool, c *sync.Cond)
- func FilenameAppend(filename, appendage string) string
- func Filter[S any](elements []S, filterer func(S) bool) []S
- func Fmap[S any, F any](elements []S, mapper func(S) F) []F
- func GetSome[S any](optional Optional[S]) S
- func IndentOutput(output string, depth uint, character string) string
- func Iota(low int, high int) (made []int)
- func IsInterfaceNil(ifc interface{}) bool
- func IsNone[S any](optional Optional[S]) bool
- func IsSome[S any](optional Optional[S]) bool
- func Max(x, y uint64) uint64
- func OrTimeout(f func(), timeout time.Duration)
- func OverrideHostTransport(transport *http.Transport, connectToAddr string)
- func PerSecondToInterval(rate int64) time.Duration
- func RandBetween(max int) int
- func Reverse[T any](elements []T) []T
- func SeekForAppend(file *os.File) (err error)
- func SignedPercentDifference[T constraints.Float | constraints.Integer](current T, previous T) (difference float64)
- func ToMBps(bytes float64) float64
- func ToMbps(bytes float64) float64
- func TrimBy[T Number](elements []T, trim int) []T
- func TrimmedMean[T Number](elements []T, trim int) (float64, []T)
- func UserAgent() string
- func WaitWithContext(ctxt context.Context, condition *func() bool, mu *sync.Mutex, c *sync.Cond) bool
- type MeasurementResult
- type Number
- type Optional
- type Pair
Constants ¶
This section is empty.
Variables ¶
View Source
var GenerateUniqueId func() uint64 = func() func() uint64 { var nextConnectionId uint64 = 0 return func() uint64 { return atomic.AddUint64(&nextConnectionId, 1) } }()
View Source
var GitVersion = "dev"
GitVersion is the Git revision hash
Functions ¶
func AbsPercentDifference ¶
func ApproximatelyEqual ¶
func CalculateAverage ¶
func CalculatePercentile ¶
func CalculateStandardDeviation ¶
func CalculateStandardDeviation[T constraints.Float | constraints.Integer](elements []T) float64
func ChannelToSlice ¶
func ChannelToSlice[S any](channel <-chan S) (slice []S)
func Conditional ¶
func ContextSignaler ¶
func FilenameAppend ¶
func IsInterfaceNil ¶
func IsInterfaceNil(ifc interface{}) bool
func OverrideHostTransport ¶
func PerSecondToInterval ¶
func RandBetween ¶
func SeekForAppend ¶
func SignedPercentDifference ¶
func SignedPercentDifference[T constraints.Float | constraints.Integer]( current T, previous T, ) (difference float64)
func TrimmedMean ¶
Types ¶
type MeasurementResult ¶
type Number ¶
type Number interface { constraints.Float | constraints.Integer }
Click to show internal directories.
Click to hide internal directories.