collectorkit

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertItem added in v1.2.0

func ConvertItem[T any, U any](ts []T, covert func(T) U) []U

func GetMapKeys

func GetMapKeys[K comparable, V any](m map[K]V) []K

func GetMapKeysByOrder

func GetMapKeysByOrder[K comparable, V any](m map[K]V, order int) K

func GetMapValues

func GetMapValues[K comparable, V any](m map[K]V) []V

func GetMapValuesByOrder

func GetMapValuesByOrder[K comparable, V any](m map[K]V, order int) V

func NewSlice added in v1.1.0

func NewSlice(ts ...any) []any

func PickRandom added in v1.2.0

func PickRandom[T any](arrays []T) T

func ToPointerSlice added in v1.1.0

func ToPointerSlice[T any](ts []T) []*T

func ToValueSlice added in v1.1.0

func ToValueSlice[T any](ts []*T) []T

Types

This section is empty.

Jump to

Keyboard shortcuts

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