AddFirst adds tasks to the front of the queue
(tasks ...task.Task)
| 135 | |
| 136 | // AddFirst adds tasks to the front of the queue |
| 137 | func (ts *TaskStorage) AddFirst(tasks ...task.Task) { |
| 138 | ts.mu.Lock() |
| 139 | defer ts.mu.Unlock() |
| 140 | |
| 141 | ts.addFirst(tasks...) |
| 142 | } |
| 143 | |
| 144 | // RemoveFirst removes and returns the first task |
| 145 | func (ts *TaskStorage) RemoveFirst() task.Task { |