Documentation
¶
Index ¶
- func CallForByteArrayLineByLine(in []byte, f func(string, ...interface{}), prefix ...string)
- func CompareBoolPointers(ptr1 *bool, ptr2 *bool, bothNilReturnTrue ...bool) bool
- func CompareStringPointers(ptr1 *string, ptr2 *string, bothNilReturnTrue ...bool) bool
- func FirstDayOfISOWeek(reference time.Time) time.Time
- func FirstDayOfMonth(reference time.Time) time.Time
- func FirstDayOfYear(reference time.Time) time.Time
- func FirstHourOfDay(reference time.Time) *time.Time
- func FmtDuration(d time.Duration) string
- func FormatByteCountIEC(b int64) string
- func IsMatchingBoolPointerInMap(ptr1 *bool, rawMap interface{}, key string, bothNilReturnTrue ...bool) bool
- func IsMatchingStringPointerInMap(ptr1 *string, rawMap interface{}, key string, bothNilReturnTrue ...bool) bool
- func IsSameDayWithoutTimezoneSupport(t time.Time, other time.Time) bool
- func KeysFromMap[T any, K comparable](m map[K]T) []K
- func Must[T any](v T, err error) T
- func NewTimer() timer
- func Ptr[T any](in T) *T
- func StringIndexOf(slice []string, item string) (int, error)
- func SubtractSlice[T comparable](a []T, b []T) []T
- func TimeFromMonthAndYear(year int, month int, timeZone string) (*time.Time, error)
- func ToInterfaceSlice[T any](in []T) []interface{}
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CallForByteArrayLineByLine ¶ added in v1.0.17
func CompareBoolPointers ¶ added in v1.0.12
func CompareStringPointers ¶
func FirstDayOfISOWeek ¶ added in v1.0.9
Figure out which day is the first of an ISOWeek
func FirstDayOfMonth ¶ added in v1.0.9
Get the first day of the month
func FirstDayOfYear ¶ added in v1.0.9
Get the first day of a year
func FirstHourOfDay ¶ added in v1.0.9
Get first hour of a day
func FmtDuration ¶ added in v1.0.14
func FormatByteCountIEC ¶ added in v1.1.2
From https://yourbasic.org/golang/formatting-byte-size-to-human-readable-format/
func IsMatchingBoolPointerInMap ¶ added in v1.0.12
func IsSameDayWithoutTimezoneSupport ¶ added in v1.0.9
Check if two time.Time are on the same day
func KeysFromMap ¶ added in v1.1.2
func KeysFromMap[T any, K comparable](m map[K]T) []K
func SubtractSlice ¶ added in v1.1.2
func SubtractSlice[T comparable](a []T, b []T) []T
Returns a slice which contains all elements of a that are not in b
func TimeFromMonthAndYear ¶ added in v1.0.9
Generate a time.Time from year and mont
func ToInterfaceSlice ¶ added in v1.1.2
func ToInterfaceSlice[T any](in []T) []interface{}
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.