@Deprecated public class THashSet<E> extends TObjectHash<E> implements java.util.Set<E>
Created: Sat Nov 3 10:38:17 2001
_hashingStrategy, _set, NULL, REMOVED_deadkeys, _free, _loadFactor, _maxSize, _size, DEFAULT_INITIAL_CAPACITY, DEFAULT_LOAD_FACTOR, EMPTY_OBJECT_ARRAY, JUST_CREATED_CAPACITYCANONICAL| Constructor and Description |
|---|
THashSet()
Deprecated.
Creates a new
THashSet instance with the default
capacity and load factor. |
THashSet(java.util.Collection<? extends E> collection)
Deprecated.
Creates a new
THashSet instance containing the
elements of collection. |
THashSet(java.util.Collection<? extends E> collection,
TObjectHashingStrategy<E> strategy)
Deprecated.
Creates a new
THashSet instance containing the
elements of collection. |
THashSet(int initialCapacity)
Deprecated.
Creates a new
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the default load factor. |
THashSet(int initialCapacity,
float loadFactor)
Deprecated.
Creates a new
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the specified load factor. |
THashSet(int initialCapacity,
float loadFactor,
TObjectHashingStrategy<E> strategy)
Deprecated.
Creates a new
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the specified load factor. |
THashSet(int initialCapacity,
TObjectHashingStrategy<E> strategy)
Deprecated.
Creates a new
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the default load factor. |
THashSet(TObjectHashingStrategy<E> strategy)
Deprecated.
Creates a new
THashSet instance with the default
capacity and load factor. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(E obj)
Deprecated.
Inserts a value into the set.
|
boolean |
addAll(java.util.Collection<? extends E> collection)
Deprecated.
Adds all of the elements in collection to the set.
|
void |
clear()
Deprecated.
Empties the set.
|
boolean |
containsAll(java.util.Collection<?> collection)
Deprecated.
Tests the set to determine if all of the elements in
collection are present.
|
boolean |
equals(java.lang.Object other)
Deprecated.
|
int |
hashCode()
Deprecated.
|
java.util.Iterator<E> |
iterator()
Deprecated.
Creates an iterator over the values of the set.
|
protected void |
rehash(int newCapacity)
Deprecated.
Expands the set to accomodate new values.
|
boolean |
remove(java.lang.Object obj)
Deprecated.
Removes obj from the set.
|
boolean |
removeAll(java.util.Collection<?> collection)
Deprecated.
Removes all of the elements in collection from the set.
|
boolean |
retainAll(java.util.Collection<?> collection)
Deprecated.
Removes any values in the set which are not contained in
collection.
|
java.lang.Object[] |
toArray()
Deprecated.
Returns a new array containing the objects in the set.
|
<T> T[] |
toArray(T[] a)
Deprecated.
Returns a typed array of the objects in the set.
|
java.lang.String |
toString()
Deprecated.
|
capacity, clone, computeHashCode, contains, equals, forEach, index, insertionIndex, removeAt, setUp, throwObjectContractViolationcalculateGrownCapacity, compact, ensureCapacity, isEmpty, postInsertHook, size, startCompactingOnRemove, stopCompactingOnRemove, trimToSizepublic THashSet()
THashSet instance with the default
capacity and load factor.public THashSet(TObjectHashingStrategy<E> strategy)
THashSet instance with the default
capacity and load factor.strategy - used to compute hash codes and to compare objects.public THashSet(int initialCapacity)
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the default load factor.initialCapacity - an int valuepublic THashSet(int initialCapacity,
TObjectHashingStrategy<E> strategy)
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the default load factor.initialCapacity - an int valuestrategy - used to compute hash codes and to compare objects.public THashSet(int initialCapacity,
float loadFactor)
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the specified load factor.initialCapacity - an int valueloadFactor - a float valuepublic THashSet(int initialCapacity,
float loadFactor,
TObjectHashingStrategy<E> strategy)
THashSet instance with a prime
capacity equal to or greater than initialCapacity and
with the specified load factor.initialCapacity - an int valueloadFactor - a float valuestrategy - used to compute hash codes and to compare objects.public THashSet(java.util.Collection<? extends E> collection)
THashSet instance containing the
elements of collection.collection - a Collection valuepublic THashSet(java.util.Collection<? extends E> collection, TObjectHashingStrategy<E> strategy)
THashSet instance containing the
elements of collection.collection - a Collection valuestrategy - used to compute hash codes and to compare objects.public boolean add(E obj)
public boolean equals(java.lang.Object other)
public int hashCode()
protected void rehash(int newCapacity)
public java.lang.Object[] toArray()
public <T> T[] toArray(T[] a)
public void clear()
public boolean remove(java.lang.Object obj)
public java.util.Iterator<E> iterator()
public boolean containsAll(java.util.Collection<?> collection)
public boolean addAll(java.util.Collection<? extends E> collection)
public boolean removeAll(java.util.Collection<?> collection)
public boolean retainAll(java.util.Collection<?> collection)
public java.lang.String toString()
toString in class java.lang.Object