Documentation
¶
Index ¶
- func Chunk(items []any, size int) [][]any
- func Concat(slices [][]any) []any
- func Contains(items []any, value any) bool
- func Drop(items []any, n int) []any
- func DropLast(items []any, n int) []any
- func Filter(items []any, predicate func(any) bool) []any
- func Find(items []any, predicate func(any) bool) (any, error)
- func FindIndex(items []any, predicate func(any) bool) int
- func FindLast(items []any, predicate func(any) bool) (any, error)
- func FindLastOr(items []any, predicate func(any) bool, defaultValue any) any
- func FindOr(items []any, predicate func(any) bool, defaultValue any) any
- func First(items []any, n int) []any
- func FirstOne(items []any) (any, error)
- func FirstOr(items []any, defaultValue any) any
- func Get(items []any, index int) (any, error)
- func GetOr(items []any, index int, defaultValue any) any
- func GroupBy[T any, K comparable](items []T, keyFunc func(T) K) map[K][]T
- func IndexOf(items []any, value any) int
- func IsEmpty(items []any) bool
- func IsNotEmpty(items []any) bool
- func Last(items []any, n int) []any
- func LastOne(items []any) (any, error)
- func LastOr(items []any, defaultValue any) any
- func Map(items []any, transform func(any) any) []any
- func Pop(items []any) (any, []any, error)
- func Reverse(items []any) []any
- func Shift(items []any) (any, []any, error)
- func Unique(items []any) []any
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GroupBy ¶
func GroupBy[T any, K comparable](items []T, keyFunc func(T) K) map[K][]T
func IsNotEmpty ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.