public class LightWeightLinkedSet<T> extends LightWeightHashSet<T>
DEFAULT_MAX_LOAD_FACTOR, DEFAUT_MIN_LOAD_FACTOR, entries, MINIMUM_CAPACITY, modification, size| Constructor and Description | 
|---|
| LightWeightLinkedSet() | 
| LightWeightLinkedSet(int initCapacity,
                    float maxLoadFactor,
                    float minLoadFactor) | 
| Modifier and Type | Method and Description | 
|---|---|
| protected boolean | addElem(T element)Add given element to the hash table | 
| void | clear()Clear the set. | 
| Iterator<T> | getBookmark()Returns a new iterator starting at the bookmarked element. | 
| Iterator<T> | iterator() | 
| List<T> | pollAll()Remove all elements from the set and return them in order. | 
| T | pollFirst()Remove and return first element on the linked list of all elements. | 
| List<T> | pollN(int n)Remove and return n elements from the hashtable. | 
| protected org.apache.hadoop.hdfs.util.LightWeightLinkedSet.DoubleLinkedElement<T> | removeElem(T key)Remove the element corresponding to the key, given key.hashCode() == index. | 
| void | resetBookmark()Resets the bookmark to the beginning of the list. | 
| <U> U[] | toArray(U[] a) | 
add, addAll, contains, containsAll, expandIfNecessary, getCapacity, getContainedElem, getElement, getIndex, isEmpty, pollToArray, printDetails, remove, removeAll, retainAll, shrinkIfNecessary, size, toArray, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitequals, hashCode, parallelStream, removeIf, spliterator, streampublic LightWeightLinkedSet(int initCapacity,
                            float maxLoadFactor,
                            float minLoadFactor)
initCapacity - Recommended size of the internal array.maxLoadFactor - used to determine when to expand the internal arrayminLoadFactor - used to determine when to shrink the internal arraypublic LightWeightLinkedSet()
protected boolean addElem(T element)
addElem in class LightWeightHashSet<T>protected org.apache.hadoop.hdfs.util.LightWeightLinkedSet.DoubleLinkedElement<T> removeElem(T key)
removeElem in class LightWeightHashSet<T>public T pollFirst()
public List<T> pollN(int n)
pollN in class LightWeightHashSet<T>public List<T> pollAll()
pollAll in class LightWeightHashSet<T>public <U> U[] toArray(U[] a)
toArray in interface Collection<T>toArray in class LightWeightHashSet<T>public Iterator<T> iterator()
iterator in interface Iterable<T>iterator in interface Collection<T>iterator in class LightWeightHashSet<T>public void clear()
clear in interface Collection<T>clear in class LightWeightHashSet<T>public Iterator<T> getBookmark()
public void resetBookmark()
Copyright © 2008–2023 Apache Software Foundation. All rights reserved.