asd_library.queue
Interface Queue_adt

All Known Implementing Classes:
Queue

public interface Queue_adt

The abstract data type queue.


Method Summary
 java.lang.Object dequeue()
          Retrieves the item from the queue head and removes it.
 void enqueue(java.lang.Object el)
          Stores an item at the queue end.
 java.lang.Object firstEl()
          Retrieves the item from the queue head but doesn't remove it.
 boolean isEmpty()
          Verifies if the queue is empty.
 

Method Detail

enqueue

public void enqueue(java.lang.Object el)
Stores an item at the queue end.

Parameters:
el - the object to store.

dequeue

public java.lang.Object dequeue()
Retrieves the item from the queue head and removes it.

Returns:
the object deleted from the queue.

firstEl

public java.lang.Object firstEl()
Retrieves the item from the queue head but doesn't remove it.

Returns:
the object at the head of the queue.

isEmpty

public boolean isEmpty()
Verifies if the queue is empty.

Returns:
true if the queue is empty, false otherwise.