HashingStrategy Enumeration

Represents a hashing strategy for some hash-based dictionaries and caches.

Definition

Namespace: KGySoft.Collections
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 8.2.0
C#
public enum HashingStrategy

Members

Auto0 The hashing strategy is determined by the type of the key in the storage. For string keys and sealed key types without an overloaded GetHashCode the And hashing strategy will be used, while for any other key types the Modulo hashing strategy will be used.
Modulo1 Represents the modulo division hashing strategy. This is quite robust even for poor GetHashCode implementations but is a bit slower than the bitwise AND hashing strategy.
And2 Represents the bitwise AND hashing strategy. While the hashing itself is very fast, this solution is quite sensitive for poorer GetHashCode implementations that may cause many key collisions, which may end up in a poorer performance.

See Also