// Swap is used internally for timeout data sort
Swap is used internally for timeout data sort
// Swap is used internally for timeout data sort
func (q *TimeoutQueue) Swap(i, j int) {
	q.index[q.data[i].Key], q.index[q.data[j].Key] = j, i
	q.data[i], q.data[j] = q.data[j], q.data[i]
}
func ( q * TimeoutQueue ) Swap ( i , j int ) { q . index [ q . data [ i ] . Key ] , q . index [ q . data [ j ] . Key ] = j , i q . data [ i ] , q . data [ j ] = q . data [ j ] , q . data [ i ] }
Swap is used internally for timeout data sort
Swap is used internally for timeout data sort
// swap index // swap data