Slicey
Collection of slice modifier in Golang (Go)
Install
go get -u github.com/codenoid/slicey
Usage
bigSlice := []interface{}{"a", "b", "c", ".... so on"}
splitted := slicey.Splitl(bigSlice, 13)
c := make(chan bool)
for _, child := range splitted {
// len(splitted) goroutine
go DoTheJob(child, c)
}
var chans [len(splitted)]bool
for i := range chans {
chans[i] = <- c
}
Features
- Split left
- Split fill all
- Value sorting
- Auto split dynamically
- Request feature