//  Copyright 2016 The Sawdust Open Source Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

package datastructure.queue;

import java.util.NoSuchElementException;

public interface FIFOQueue<E> {
    /**
     * @throws IllegalStateException if the element cannot be added at this
     * @throws NullPointerException  if the specified element is null
     */
    boolean add(E e);

    /**
     * @return <tt>true</tt> if the element was added to this queue, else  <tt>false</tt>
     * @throws NullPointerException if the specified element is null
     */
    boolean offer(E e);

    /**
     * @return the head of this queue
     * @throws NoSuchElementException if this queue is empty
     */
    E remove();

    /**
     * Retrieves and removes the head of this queue,  or returns <tt>null</tt> if this queue is empty.
     *
     * @return the head of this queue, or <tt>null</tt> if this queue is empty
     */
    E poll();

    /**
     * Retrieves, but does not remove, the head of this queue.
     *
     * @return the head of this queue
     * @throws NoSuchElementException if this queue is empty
     */
    E element();

    /**
     * @return the head of this queue, or <tt>null</tt> if this queue is empty
     */
    E peek();

    boolean isEmpty();

    int size();
}

@@ -793,16 +793,22 @@
  at this
+ queue
 %0A     * 
@@ -928,21 +928,12 @@
 urn 
-%3Ctt%3Etrue%3C/tt%3E
+true
  if 
@@ -978,23 +978,13 @@
 lse 
- %3Ctt%3Efalse%3C/tt%3E
+false
 %0A   
@@ -1287,29 +1287,20 @@
 returns 
-%3Ctt%3Enull%3C/tt%3E
+null
  if this
@@ -1361,37 +1361,28 @@
 s queue, or 
-%3Ctt%3Enull%3C/tt%3E
+null
  if this que
@@ -1673,21 +1673,12 @@
  or 
-%3Ctt%3Enull%3C/tt%3E
+null
  if 

Update the interface FIFOQueue