com.googlecode.n_orm.cache
Class LIFO<T>
java.lang.Object
com.googlecode.n_orm.cache.LIFO<T>
- All Implemented Interfaces:
- Iterable<T>
public class LIFO<T>
- extends Object
- implements Iterable<T>
|
Constructor Summary |
LIFO()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LIFO
public LIFO()
pop
public T pop()
push
public void push(T element)
pushAll
public void pushAll(LIFO<T> available)
iterator
public Iterator<T> iterator()
- An iterator starting from the tail of the LIFO.
Supports
Iterator.remove().
The iterator should be used by only one thread.
Won't throw ConcurrentModificationException even if LIFO is modified (for instance by calling push(Object), Iterator.remove()}.
However, it can iterate over popped or removed elements...
- Specified by:
iterator in interface Iterable<T>
clear
public void clear()
findWithCriterium
public com.googlecode.n_orm.cache.LIFO.Node<T> findWithCriterium(LIFO.Criterium c,
Object... args)
getFirstElement
public com.googlecode.n_orm.cache.LIFO.Node<T> getFirstElement()
contains
public boolean contains(T element)
Copyright © 2012. All Rights Reserved.