Documentation
¶
Overview ¶
Package ds provides some utilities relating to data structures.
Index ¶
- func FlatMap[T any, R any, ST ~[]T, SR ~[]R](arr ST, iteratee func(T) SR) SR
- func FlatMapError[T any, R any, ST ~[]T, SR ~[]R](arr ST, iteratee func(T) (SR, error)) (SR, error)
- func Limit[T any, ST ~[]T](arr ST, limit int) ST
- func Map[T any, R any, ST ~[]T](arr ST, iteratee func(T) R) []R
- func MapError[T any, R any, ST ~[]T](arr ST, iteratee func(T) (R, error)) ([]R, error)
- func SortAsc[E any, K constraints.Ordered](key func(e E) K) func(e1, e2 E) int
- func SortCompose[E any](comparators ...func(e1, e2 E) int) func(e1, e2 E) int
- func SortDesc[E any, K constraints.Ordered](key func(e E) K) func(e1, e2 E) int
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FlatMapError ¶
func SortCompose ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.