Interface QueueInterface

All Known Implementing Classes:
VectorQueue

public interface QueueInterface

Interface specifying the behavior for a queue.


Method Summary
 java.lang.Object dequeue()
          Dequeues and returns the next available element on this queue.
 void enqueue(java.lang.Object element)
          Enqueues the given element on this queue.
 java.lang.Object front()
          Returns the next available element on this queue.
 boolean isEmpty()
          Returns whether or not this queue structure is empty.
 int size()
          Returns the size of this queue structure.
 

Method Detail

enqueue

public void enqueue(java.lang.Object element)
Enqueues the given element on this queue.
Parameters:
element - the desired element to enqueue

dequeue

public java.lang.Object dequeue()
Dequeues and returns the next available element on this queue.

front

public java.lang.Object front()
Returns the next available element on this queue.

size

public int size()
Returns the size of this queue structure.

isEmpty

public boolean isEmpty()
Returns whether or not this queue structure is empty.