validation

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2024 License: AGPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MaxDurationOrZeroPerTenant

func MaxDurationOrZeroPerTenant(tenantIDs []string, f func(string) time.Duration) time.Duration

MaxDurationOrZeroPerTenant is returning the maximum duration per tenant or zero if one tenant has time.Duration(0).

func SmallestPositiveNonZeroDurationPerTenant

func SmallestPositiveNonZeroDurationPerTenant(tenantIDs []string, f func(string) time.Duration) time.Duration

SmallestPositiveNonZeroDurationPerTenant is returning the minimal positive and non-zero value of the supplied limit function for all given tenants. In many limits a value of 0 means unlimited so the method will return 0 only if all inputs have a limit of 0 or an empty tenant list is given.

func SmallestPositiveNonZeroIntPerTenant

func SmallestPositiveNonZeroIntPerTenant(tenantIDs []string, f func(string) int) int

SmallestPositiveNonZeroIntPerTenant is returning the minimal positive and non-zero value of the supplied limit function for all given tenants. In many limits a value of 0 means unlimited so the method will return 0 only if all inputs have a limit of 0 or an empty tenant list is given.

Types

This section is empty.

Jump to

Keyboard shortcuts

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