Class Utils.ObjectReferenceEqualityComparer<T>
public class Utils.ObjectReferenceEqualityComparer<T> : IEqualityComparer<T> where T : notnull
Type Parameters
T
- Inheritance
-
Utils.ObjectReferenceEqualityComparer<T>
- Implements
- Extension Methods
Fields
Default
public static IEqualityComparer<T> Default
Field Value
Methods
Equals(T?, T?)
Determines whether the specified objects are equal.
public bool Equals(T? x, T? y)
Parameters
xTThe first object of type
Tto compare.yTThe second object of type
Tto compare.
Returns
- bool
true if the specified objects are equal; otherwise, false.
GetHashCode(T)
Returns a hash code for the specified object.
public int GetHashCode(T obj)
Parameters
objTThe object for which a hash code is to be returned.
Returns
- int
A hash code for the specified object.
Exceptions
- ArgumentNullException
The type of
objis a reference type andobjis null.