Table of Contents

Class ValueHashSet<T>

Namespace
GuildWars2.Collections
Assembly
GW2SDK.dll

Represents a set collection with value semantics, meaning two ValueHashSet<T> instances are considered equal if their contents are equal. Value equality is determined by the set of items in the collection, not by reference.

public sealed class ValueHashSet<T> : HashSet<T>, IReadOnlyCollection<T>, ISet<T>, ICollection<T>, IEnumerable<T>, IEnumerable, IDeserializationCallback, ISerializable, IEquatable<ValueHashSet<T>>

Type Parameters

T
Inheritance
ValueHashSet<T>
Implements
ISet<T>
Inherited Members

Remarks

Adding items to the set changes its hash code. Do not use this type in dictionaries or hash sets.

Constructors

ValueHashSet()

Initializes a new instance of the ValueHashSet<T> class that is empty.

ValueHashSet(IEnumerable<T>)

Initializes a new instance of the ValueHashSet<T> class that contains elements copied from the specified collection.

Methods

Equals(ValueHashSet<T>?)

Determines whether the current ValueHashSet<T> is equal to another ValueHashSet<T> based on value semantics.

Equals(object?)
GetHashCode()

Returns a hash code based on the values of the items in the set.

Operators

operator ==(ValueHashSet<T>?, ValueHashSet<T>?)

Determines whether two ValueHashSet<T> instances are equal by value.

operator !=(ValueHashSet<T>?, ValueHashSet<T>?)

Determines whether two ValueHashSet<T> instances are not equal by value.