Popularity
1.6
Growing
Activity
0.0
Stable
13
2
4
Programming language: Go
License: MIT License
Tags:
Data Structures
Latest version: v0.3.0
goterator alternatives and similar packages
Based on the "Data Structures" category.
Alternatively, view goterator alternatives based on common mentions on social networks and blogs.
-
gods
GoDS (Go Data Structures) - Sets, Lists, Stacks, Maps, Trees, Queues, and much more -
go-datastructures
A collection of useful, performant, and threadsafe Go datastructures. -
golang-set
A simple, battle-tested and generic set type for the Go language. Trusted by Docker, 1Password, Ethereum and Hashicorp. -
gocache
☔️ A complete Go cache library that brings you multiple ways of managing your caches -
boomfilters
Probabilistic data structures for processing continuous, unbounded streams. -
gostl
Data structure and algorithm library for go, designed to provide functions similar to C++ STL -
hyperloglog
HyperLogLog with lots of sugar (Sparse, LogLog-Beta bias correction and TailCut space reduction) brought to you by Axiom -
trie
Data structure and relevant algorithms for extremely fast prefix/fuzzy string searching. -
ttlcache
An in-memory cache with item expiration and generics [Moved to: https://github.com/jellydator/ttlcache] -
go-geoindex
Go native library for fast point tracking and K-Nearest queries -
hilbert
Go package for mapping values to and from space-filling curves, such as Hilbert and Peano curves. -
Bloomfilter
Face-meltingly fast, thread-safe, marshalable, unionable, probability- and optimal-size-calculating Bloom filter in go -
go-adaptive-radix-tree
Adaptive Radix Trees implemented in Go -
goconcurrentqueue
Go concurrent-safe, goroutine-safe, thread-safe queue -
cuckoo-filter
Cuckoo Filter go implement, better than Bloom Filter, configurable and space optimized 布谷鸟过滤器的Go实现,优于布隆过滤器,可以定制化过滤器参数,并进行了空间优化 -
ring
Package ring provides a high performance and thread safe Go implementation of a bloom filter. -
go-rquad
:pushpin: State of the art point location and neighbour finding algorithms for region quadtrees, in Go -
set
A simple Set data structure implementation in Go (Golang) using LinkedHashMap. -
nan
Zero allocation Nullable structures in one library with handy conversion functions, marshallers and unmarshallers -
goset
Set is a useful collection but there is no built-in implementation in Go lang. -
hide
ID type with marshalling to/from hash to prevent sending IDs to clients.
Access the most powerful time series database as a service
Ingest, store, & analyze all types of time series data in a fully-managed, purpose-built database. Keep data forever with low-cost storage and superior data compression.
Promo
www.influxdata.com
Do you think we are missing an alternative of goterator or a related project?
README
Goterator
Iterator implementation for Golang to provide map and reduce functionalities.
Package
import (
"github.com/yaa110/goterator"
"github.com/yaa110/goterator/generator"
)
Getting Started
- Create a generator from slices
words := []interface{}{"an", "example", "of", "goterator"}
gen := generator.NewSlice(words)
- Create a generator from channels
chn := make(chan interface{}, 4)
chn <- "an"
chn <- "example"
chn <- "of"
chn <- "goterator"
close(chn)
gen := generator.NewChannel(chn)
- Create custom generators
type TestGenerator struct {
words []string
i int
value string
}
func (g *TestGenerator) Next() bool {
if g.i == len(g.words) {
return false
}
g.value = g.words[g.i]
g.i++
return true
}
func (g *TestGenerator) Value() interface{} {
return g.value
}
gen := &TestGenerator{
words: []string{"an", "example", "of", "goterator"},
i: 0,
value: "",
}
- Iterate over generators
lengths := goterator.New(gen).Map(func(word interface{}) interface{} {
return len(word.(string))
}).Collect()
assert.Equal([]interface{}{2, 7, 2, 9}, lengths)
Please for more information about mappers and reducers (consumers) check the documentation.