Represents bitwise comparer for the arbitrary value type.
InheritanceBitwiseComparer<T>
Namespace: DotNext Assembly: DotNext.dll Syntaxpublic sealed class BitwiseComparer<T> : IEqualityComparer<T>, IComparer<T> where T : unmanaged
Type Parameters Name Description T
The value type.
Properties | Edit this page View Source InstanceGets instance of this comparer.
Declarationpublic static BitwiseComparer<T> Instance { get; }
Property Value Methods | Edit this page View Source Compare<TOther>(in T, in TOther)
Compares bits of two values of the different type.
Declarationpublic static int Compare<TOther>(in T first, in TOther second) where TOther : unmanaged
Parameters Type Name Description T first
The first value to compare.
TOther secondThe second value to compare.
Returns Type Description intA value that indicates the relative order of the objects being compared.
Type Parameters Name Description TOtherType of the second value.
| Edit this page View Source Equals<TOther>(in T, in TOther)Checks bitwise equality between two values of different value types.
Declarationpublic static bool Equals<TOther>(in T first, in TOther second) where TOther : unmanaged
Parameters Type Name Description T first
The first value to check.
TOther secondThe second value to check.
Returns Type Description booltrue, if both values are equal; otherwise, false.
Type Parameters Name Description TOtherType of second value.
| Edit this page View Source GetHashCode(in T, bool)Computes hash code for the structure content.
Declarationpublic static int GetHashCode(in T value, bool salted = true)
Parameters Type Name Description T value
Value to be hashed.
bool saltedtrue to include randomized salt data into hashing; false to use data from memory only.
Returns Type Description intContent hash code.
Implements Extension MethodsRetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4