Enqueues a newly dispatched ack, arming it immediately when idle.
(&mut self, ack: PendingAck<B, A>)
| 145 | |
| 146 | /// Enqueues a newly dispatched ack, arming it immediately when idle. |
| 147 | fn enqueue(&mut self, ack: PendingAck<B, A>) { |
| 148 | if self.current.is_none() { |
| 149 | self.current.replace(ack); |
| 150 | return; |
| 151 | } |
| 152 | self.queue.push_back(ack); |
| 153 | } |
| 154 | |
| 155 | /// Returns metadata for a completed current ack and arms the next queued ack. |
| 156 | fn complete_current( |