fanIn reads elements from channels `chans` into channel `out`
(chans []chan Tuple, out chan Tuple)
| 237 | |
| 238 | // fanIn reads elements from channels `chans` into channel `out` |
| 239 | func fanIn(chans []chan Tuple, out chan Tuple) { |
| 240 | wg := sync.WaitGroup{} |
| 241 | wg.Add(len(chans)) |
| 242 | for _, ch := range chans { |
| 243 | go func(ch chan Tuple) { |
| 244 | for t := range ch { |
| 245 | out <- t |
| 246 | } |
| 247 | wg.Done() |
| 248 | }(ch) |
| 249 | } |
| 250 | wg.Wait() |
| 251 | close(out) |
| 252 | } |
| 253 | |
| 254 | // Returns all items as map[string]interface{} |
| 255 | func (m ConcurrentHashMap) Items() map[string]interface{} { |
no outgoing calls
no test coverage detected