org.apache.jetspeed.util
Class FIFOQueue

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.Vector
              extended by org.apache.jetspeed.util.FIFOQueue
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.List, java.util.RandomAccess, Queue

public class FIFOQueue
extends java.util.Vector
implements Queue

Simple FIFO implementation of Queue interface extending Vector as storage backend.

Version:
$Id: FIFOQueue.java 516448 2007-03-09 16:25:47Z ate $
Author:
Rapha?l Luta
See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.Vector
capacityIncrement, elementCount, elementData
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
FIFOQueue()
           
 
Method Summary
 java.lang.Object peek()
          Gets the first object in the queue without removing it from the queue
 java.lang.Object pop()
          Gets the first object in the queue and remove it from the queue
 void push(java.lang.Object obj)
          Adds a new object into the queue
 
Methods inherited from class java.util.Vector
add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize
 
Methods inherited from class java.util.AbstractList
iterator, listIterator, listIterator
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray
 

Constructor Detail

FIFOQueue

public FIFOQueue()
Method Detail

push

public void push(java.lang.Object obj)
Adds a new object into the queue

Specified by:
push in interface Queue

pop

public java.lang.Object pop()
Gets the first object in the queue and remove it from the queue

Specified by:
pop in interface Queue

peek

public java.lang.Object peek()
Gets the first object in the queue without removing it from the queue

Specified by:
peek in interface Queue


Copyright © 1999-2009 Apache Software Foundation. All Rights Reserved.