Documentation ¶
Index ¶
- func AOCFinish[T any](parts ...T)
- func BitCount32[T uint32 | int32](i T) T
- func CheckBit[T constraints.Integer](value, index T) bool
- func Clamp[T constraints.Ordered](value, lower, upper T) T
- func ClampLower[T constraints.Ordered](value, lower T) T
- func ClampUpper[T constraints.Ordered](value, upper T) T
- func ClearBit[T constraints.Integer](value T, index T) T
- func FileReadAll[T string | []byte](path string) T
- func FileReadAllLines(path string, f func(string))
- func GetMD5Hash(text string) string
- func IsHexChar[T byte | rune](c T) bool
- func IsHexString(s string) bool
- func SetBit[T constraints.Integer](value T, index T) T
- func ToggleBit[T constraints.Integer](value T, index T) T
- func Xor[T constraints.Integer](left, right T) T
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BitCount32 ¶
https://stackoverflow.com/questions/109023/count-the-number-of-set-bits-in-a-32-bit-integer https://en.wikipedia.org/wiki/Hamming_weight
func CheckBit ¶
func CheckBit[T constraints.Integer](value, index T) bool
func Clamp ¶
func Clamp[T constraints.Ordered](value, lower, upper T) T
func ClampLower ¶
func ClampLower[T constraints.Ordered](value, lower T) T
func ClampUpper ¶
func ClampUpper[T constraints.Ordered](value, upper T) T
func ClearBit ¶
func ClearBit[T constraints.Integer](value T, index T) T
func FileReadAll ¶
func FileReadAllLines ¶
func GetMD5Hash ¶
func IsHexString ¶
func SetBit ¶
func SetBit[T constraints.Integer](value T, index T) T
func ToggleBit ¶
func ToggleBit[T constraints.Integer](value T, index T) T
func Xor ¶
func Xor[T constraints.Integer](left, right T) T
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.