Class HashSet<T>
A set collection class based on linear hashing
Inherited Members
Assembly: DistributedLucene.Net.dll
Syntax
public class HashSet<T> : CollectionBase<T>, ICollection<T>, IExtensible<T>, ICollectionValue<T>, Collections.Generic.IEnumerable<T>, IShowable, IFormattable, Collections.Generic.ICollection<T>
Type Parameters
Name | Description |
---|---|
T |
Constructors
Name | Description |
---|---|
HashSet() | |
HashSet(MemoryType) | Create a hash set with natural item equalityComparer and default fill threshold (66%) and initial table size (16). |
HashSet(Collections.Generic.IEqualityComparer<T>, MemoryType) | Create a hash set with external item equalityComparer and default fill threshold (66%) and initial table size (16). |
HashSet(Int32, Collections.Generic.IEqualityComparer<T>, MemoryType) | Create a hash set with external item equalityComparer and default fill threshold (66%) |
HashSet(Int32, Double, Collections.Generic.IEqualityComparer<T>, MemoryType) | Create a hash set with external item equalityComparer. |
Properties
Name | Description |
---|---|
AllowsDuplicates | Report if this is a set collection. |
ContainsSpeed | The complexity of the Contains operation |
DuplicatesByCounting | By convention this is true for any collection with set semantics. |
Features | Show which implementation features was chosen at compilation time |
ListenableEvents |
Methods
Name | Description |
---|---|
Add(T) | Add an item to this set. |
AddAll(Collections.Generic.IEnumerable<T>) | Add the elements from another collection with a more specialized item type to this collection. Since this collection has set semantics, only items not already in the collection will be added. |
BucketCostDistribution() | Produce statistics on distribution of bucket sizes. Current implementation is incomplete. |
Check() | Test internal structure of data (invariants) |
Choose() | Choose some item of this collection. |
Clear() | Remove all items from the set, resetting internal table to initial size. |
Contains(T) | Check if an item is in the set |
ContainsAll(Collections.Generic.IEnumerable<T>) | Check if all items in a supplied collection is in this set (ignoring multiplicities). |
ContainsCount(T) | Count the number of times an item is in this set (either 0 or 1). |
Find(ref T) | Check if an item (collection equal to a given one) is in the set and if so report the actual item object found. |
FindOrAdd(ref T) | Check if an item (collection equal to a given one) is in the set. If found, report the actual item object in the set, else add the supplied one. |
GetEnumerator() | Create an enumerator for this set. |
ItemMultiplicities() | |
Remove(T) | Remove an item from the set |
Remove(T, out T) | Remove an item from the set, reporting the actual matching item object. |
RemoveAll(Collections.Generic.IEnumerable<T>) | Remove all items in a supplied collection from this set. |
RemoveAllCopies(T) | Remove all (at most 1) copies of item from this set. |
RetainAll(Collections.Generic.IEnumerable<T>) | Remove all items not in a supplied collection from this set. |
ToArray() | Create an array containing all items in this set (in enumeration order). |
UniqueItems() | |
Update(T) | Check if an item (collection equal to a given one) is in the set and if so replace the item object in the set with the supplied one. |
Update(T, out T) | Check if an item (collection equal to a given one) is in the set and if so replace the item object in the set with the supplied one. |
UpdateOrAdd(T) | Check if an item (collection equal to a supplied one) is in the set and if so replace the item object in the set with the supplied one; else add the supplied one. |
UpdateOrAdd(T, out T) | Check if an item (collection equal to a supplied one) is in the set and if so replace the item object in the set with the supplied one; else add the supplied one. |