Provides a thread-safe set collection that mimics the behavior of HashSet<T> and will be keep insertion order
More...
|
void | UnionWith (IEnumerable< T > other) |
| Modifies the current set so that it contains all elements that are present in either the current set or the specified collection. More...
|
|
void | IntersectWith (IEnumerable< T > other) |
| Modifies the current set so that it contains only elements that are also in a specified collection. More...
|
|
void | ExceptWith (IEnumerable< T > other) |
| Removes all elements in the specified collection from the current set. More...
|
|
void | SymmetricExceptWith (IEnumerable< T > other) |
| Modifies the current set so that it contains only elements that are present either in the current set or in the specified collection, but not both. More...
|
|
bool | IsSubsetOf (IEnumerable< T > other) |
| Determines whether a set is a subset of a specified collection. More...
|
|
bool | IsSupersetOf (IEnumerable< T > other) |
| Determines whether the current set is a superset of a specified collection. More...
|
|
bool | IsProperSupersetOf (IEnumerable< T > other) |
| Determines whether the current set is a proper (strict) superset of a specified collection. More...
|
|
bool | IsProperSubsetOf (IEnumerable< T > other) |
| Determines whether the current set is a proper (strict) subset of a specified collection. More...
|
|
bool | Overlaps (IEnumerable< T > other) |
| Determines whether the current set overlaps with the specified collection. More...
|
|
bool | SetEquals (IEnumerable< T > other) |
| Determines whether the current set and the specified collection contain the same elements. More...
|
|
bool | Add (T item) |
| Adds an element to the current set and returns a value to indicate if the element was successfully added. More...
|
|
void | Clear () |
| Removes all items from the T:System.Collections.Generic.ICollection`1. More...
|
|
bool | Contains (T item) |
| Determines whether the T:System.Collections.Generic.ICollection`1 contains a specific value. More...
|
|
void | CopyTo (T[] array, int arrayIndex) |
| Copies the elements of the T:System.Collections.Generic.ICollection`1 to an T:System.Array, starting at a particular T:System.Array index. More...
|
|
bool | Remove (T item) |
| Removes the first occurrence of a specific object from the T:System.Collections.Generic.ICollection`1. More...
|
|
IEnumerator< T > | GetEnumerator () |
| Returns an enumerator that iterates through the collection. More...
|
|
|
bool | IsReadOnly => false |
| Gets a value indicating whether the T:System.Collections.Generic.ICollection`1 is read-only. More...
|
|
|
int | Count [get] |
| Gets the number of elements contained in the T:System.Collections.Generic.ICollection`1. More...
|
|
Provides a thread-safe set collection that mimics the behavior of HashSet<T> and will be keep insertion order
- Template Parameters
-
Definition at line 29 of file ConcurrentSet.cs.
◆ UnionWith()
Modifies the current set so that it contains all elements that are present in either the current set or the specified collection.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 74 of file ConcurrentSet.cs.
◆ IntersectWith()
Modifies the current set so that it contains only elements that are also in a specified collection.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 92 of file ConcurrentSet.cs.
◆ ExceptWith()
Removes all elements in the specified collection from the current set.
- Parameters
-
other | The collection of items to remove from the set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 114 of file ConcurrentSet.cs.
◆ SymmetricExceptWith()
Modifies the current set so that it contains only elements that are present either in the current set or in the specified collection, but not both.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 132 of file ConcurrentSet.cs.
◆ IsSubsetOf()
Determines whether a set is a subset of a specified collection.
- Returns
- true if the current set is a subset of other ; otherwise, false.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 154 of file ConcurrentSet.cs.
◆ IsSupersetOf()
Determines whether the current set is a superset of a specified collection.
- Returns
- true if the current set is a superset of other ; otherwise, false.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 177 of file ConcurrentSet.cs.
◆ IsProperSupersetOf()
Determines whether the current set is a proper (strict) superset of a specified collection.
- Returns
- true if the current set is a proper superset of other ; otherwise, false.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 200 of file ConcurrentSet.cs.
◆ IsProperSubsetOf()
Determines whether the current set is a proper (strict) subset of a specified collection.
- Returns
- true if the current set is a proper subset of other ; otherwise, false.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 226 of file ConcurrentSet.cs.
◆ Overlaps()
Determines whether the current set overlaps with the specified collection.
- Returns
- true if the current set and other share at least one common element; otherwise, false.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 252 of file ConcurrentSet.cs.
◆ SetEquals()
Determines whether the current set and the specified collection contain the same elements.
- Returns
- true if the current set is equal to other ; otherwise, false.
- Parameters
-
other | The collection to compare to the current set. |
- Exceptions
-
T:System.ArgumentNullException | other is null. |
Definition at line 275 of file ConcurrentSet.cs.
◆ Add()
Adds an element to the current set and returns a value to indicate if the element was successfully added.
- Returns
- true if the element is added to the set; false if the element is already in the set.
- Parameters
-
item | The element to add to the set. |
Definition at line 295 of file ConcurrentSet.cs.
◆ Clear()
Removes all items from the T:System.Collections.Generic.ICollection`1.
- Exceptions
-
T:System.NotSupportedException | The T:System.Collections.Generic.ICollection`1 is read-only. |
Definition at line 305 of file ConcurrentSet.cs.
◆ Contains()
Determines whether the T:System.Collections.Generic.ICollection`1 contains a specific value.
- Returns
- true if item is found in the T:System.Collections.Generic.ICollection`1; otherwise, false.
- Parameters
-
item | The object to locate in the T:System.Collections.Generic.ICollection`1. |
Definition at line 317 of file ConcurrentSet.cs.
◆ CopyTo()
Copies the elements of the T:System.Collections.Generic.ICollection`1 to an T:System.Array, starting at a particular T:System.Array index.
- Parameters
-
array | The one-dimensional T:System.Array that is the destination of the elements copied from T:System.Collections.Generic.ICollection`1. The T:System.Array must have zero-based indexing. |
arrayIndex | The zero-based index in array at which copying begins. |
- Exceptions
-
T:System.ArgumentNullException | array is null. |
T:System.ArgumentOutOfRangeException | arrayIndex is less than 0. |
T:System.ArgumentException | The number of elements in the source T:System.Collections.Generic.ICollection`1 is greater than the available space from arrayIndex to the end of the destination array . |
Definition at line 333 of file ConcurrentSet.cs.
◆ Remove()
Removes the first occurrence of a specific object from the T:System.Collections.Generic.ICollection`1.
- Returns
- true if item was successfully removed from the T:System.Collections.Generic.ICollection`1; otherwise, false. This method also returns false if item is not found in the original T:System.Collections.Generic.ICollection`1.
- Parameters
-
item | The object to remove from the T:System.Collections.Generic.ICollection`1. |
- Exceptions
-
T:System.NotSupportedException | The T:System.Collections.Generic.ICollection`1 is read-only. |
Definition at line 348 of file ConcurrentSet.cs.
◆ GetEnumerator()
Returns an enumerator that iterates through the collection.
For thread safety will return a snapshot of the collection
- Returns
- A T:System.Collections.Generic.IEnumerator`1 that can be used to iterate through the collection.
<filterpriority>1</filterpriority>
Definition at line 365 of file ConcurrentSet.cs.
◆ IsReadOnly
Gets a value indicating whether the T:System.Collections.Generic.ICollection`1 is read-only.
- Returns
- true if the T:System.Collections.Generic.ICollection`1 is read-only; otherwise, false.
Definition at line 52 of file ConcurrentSet.cs.
◆ Count
Gets the number of elements contained in the T:System.Collections.Generic.ICollection`1.
- Returns
- The number of elements contained in the T:System.Collections.Generic.ICollection`1.
Definition at line 40 of file ConcurrentSet.cs.
The documentation for this class was generated from the following file: