E element
) Adds value
at the beginning of the queue.
Source
void addFirst(E element) {
_head = (_head - 1) & (_table.length - 1);
_table[_head] = element;
if (_head == _tail) _grow();
_modificationCount++;
}
Adds value
at the beginning of the queue.
void addFirst(E element) {
_head = (_head - 1) & (_table.length - 1);
_table[_head] = element;
if (_head == _tail) _grow();
_modificationCount++;
}