This class provides skeletal implementations of some Queue
operations. The implementations in this class are appropriate when
the base implementation does not allow null
elements. Methods add, remove, and
element are based on offer, poll, and peek, respectively, but throw
exceptions instead of indicating failure via false or
null returns.
A Queue implementation that extends this class must
minimally define a method Queue.offer which does not permit
insertion of null elements, along with methods Queue.peek, Queue.poll, Collection.size, and
Collection.iterator. Typically, additional methods will be
overridden as well. If these requirements cannot be met, consider
instead subclassing AbstractCollection.
This class is a member of the Java Collections Framework.
extends
<E> | the type of elements held in this collection |