Documentation
¶
Index ¶
- func Cast[T any, U any](from Map[string, *Data[T]], to Map[string, *Data[U]]) (err error)
- func SortData[T any](data []*Data[T])
- type CollectiveProcess
- type CollectiveProcessor
- type Data
- type ErrorGroup
- type FileSet
- type IndividualProcess
- type IndividualProcessor
- type Map
- func Collective[I, O any](cxt context.Context, options ProcessingOptions, ...) (output Map[string, *Data[O]], err error)
- func NewConcurrentMap[K comparable, V any]() Map[K, V]
- func NewConcurrentMapPresized[K comparable, V any](size int) Map[K, V]
- func NewMap[K comparable, V any]() Map[K, V]
- func NewMapPresized[K comparable, V any](size int) Map[K, V]
- func Parallel[I, O any](cxt context.Context, options ProcessingOptions, ...) (output Map[string, *Data[O]], err error)
- type Once
- type Paths
- type ProcessingOptions
- type Processor
- type StringSet
- type Targeter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type CollectiveProcess ¶
type CollectiveProcessor ¶
type CollectiveProcessor[I, O any] interface { Processor Process(cxt context.Context, inputs []*Data[I]) (outputs []*Data[O], err error) }
func CollectiveFunc ¶
func CollectiveFunc[I, O any](name string, process CollectiveProcess[I, O]) CollectiveProcessor[I, O]
type ErrorGroup ¶
type ErrorGroup []error
func (ErrorGroup) Error ¶
func (eg ErrorGroup) Error() string
type IndividualProcess ¶
type IndividualProcessor ¶
type IndividualProcessor[I, O any] interface { Processor Process(cxt context.Context, input *Data[I], index int32, total int32) (outputs []*Data[O], extra []*Data[I], err error) }
func ParallelFunc ¶
func ParallelFunc[I, O any](name string, process IndividualProcess[I, O]) IndividualProcessor[I, O]
type Map ¶
type Map[K comparable, V any] interface { Load(key K) (value V, ok bool) Store(key K, value V) LoadOrStore(key K, value V) (actual V, loaded bool) LoadAndStore(key K, value V) (actual V, loaded bool) Delete(key K) Size() int Range(f func(key K, value V) bool) }
func Collective ¶
func NewConcurrentMap ¶
func NewConcurrentMap[K comparable, V any]() Map[K, V]
func NewConcurrentMapPresized ¶
func NewConcurrentMapPresized[K comparable, V any](size int) Map[K, V]
func NewMap ¶
func NewMap[K comparable, V any]() Map[K, V]
func NewMapPresized ¶
func NewMapPresized[K comparable, V any](size int) Map[K, V]
type ProcessingOptions ¶
Click to show internal directories.
Click to hide internal directories.