add
Inserts the specified element into this queue if it is possible to do so immediately without violating capacity restrictions, returning true upon success and throwing an IllegalStateException if no space is currently available. When using a capacity-restricted queue, it is generally preferable to use .offer.
Return
true (as specified by Collection.add)
Parameters
e
the element to add
Throws
if the element cannot be added at this time due to capacity restrictions
if the class of the specified element prevents it from being added to this queue
if the specified element is null
if some property of the specified element prevents it from being added to this queue