back property

T get back

Returns the back element of the queue without removing it. Throws a StateError if the queue is empty.

Implementation

T get back {
  if (empty) {
    throw StateError('Cannot access back of an empty Queue');
  }
  return _container.getRear();
}