Put add the item to the queue.
(items ...interface{})
| 12 | |
| 13 | // Put add the item to the queue. |
| 14 | func (q *Queue) Put(items ...interface{}) { |
| 15 | if len(items) == 0 { |
| 16 | return |
| 17 | } |
| 18 | |
| 19 | q.lock.Lock() |
| 20 | q.items = append(q.items, items...) |
| 21 | q.lock.Unlock() |
| 22 | } |
| 23 | |
| 24 | // Pop returns the head of items. |
| 25 | func (q *Queue) Pop() interface{} { |
nothing calls this directly
no outgoing calls
no test coverage detected