PushWithoutLock is no lock mode of Push
(node QueueNode)
| 91 | |
| 92 | // PushWithoutLock is no lock mode of Push |
| 93 | func (q *Queue) PushWithoutLock(node QueueNode) { |
| 94 | if q.tail == nil { |
| 95 | q.head = node |
| 96 | q.tail = node |
| 97 | q.count = 1 |
| 98 | } else { |
| 99 | q.tail.SetNext(node) |
| 100 | q.tail = node |
| 101 | q.count++ |
| 102 | } |
| 103 | } |
| 104 | |
| 105 | // PullWithOutLock is no lock mode of Pull |
| 106 | func (q *Queue) PullWithOutLock() QueueNode { |