public class BoundedTreeSet<E> extends TreeSet<E>
last()
is removed if the size()
get's bigger then getMaxSize()
Constructor and Description |
---|
BoundedTreeSet(int maxSize) |
BoundedTreeSet(int maxSize,
Collection<? extends E> c) |
BoundedTreeSet(int maxSize,
Comparator<? super E> c) |
BoundedTreeSet(int maxSize,
SortedSet<E> s) |
Modifier and Type | Method and Description |
---|---|
boolean |
add(E item) |
boolean |
addAll(Collection<? extends E> c) |
int |
getMaxSize() |
void |
setMaxSize(int max) |
ceiling, clear, clone, comparator, contains, descendingIterator, descendingSet, first, floor, headSet, headSet, higher, isEmpty, iterator, last, lower, pollFirst, pollLast, remove, size, subSet, subSet, tailSet, tailSet
equals, hashCode, removeAll
containsAll, retainAll, toArray, toArray, toString
public BoundedTreeSet(int maxSize)
public BoundedTreeSet(int maxSize, Collection<? extends E> c)
public BoundedTreeSet(int maxSize, Comparator<? super E> c)
public int getMaxSize()
public void setMaxSize(int max)
public boolean add(E item)
Copyright © 2000-2014 Apache Software Foundation. All Rights Reserved.