Redigeeri

Jagamisviis:


EqualityComparer<T>.IEqualityComparer.GetHashCode(Object) Method

Definition

Returns a hash code for the specified object.

 virtual int System.Collections.IEqualityComparer.GetHashCode(System::Object ^ obj) = System::Collections::IEqualityComparer::GetHashCode;
int IEqualityComparer.GetHashCode (object obj);
abstract member System.Collections.IEqualityComparer.GetHashCode : obj -> int
override this.System.Collections.IEqualityComparer.GetHashCode : obj -> int
Function GetHashCode (obj As Object) As Integer Implements IEqualityComparer.GetHashCode

Parameters

obj
Object

The Object for which a hash code is to be returned.

Returns

A hash code for the specified object.

Implements

Exceptions

The type of obj is a reference type and obj is null.

-or-

obj is of a type that cannot be cast to type T.

Remarks

This method is a wrapper for the GetHashCode(T) method, so obj must be a type that can be cast to the type specified by the generic type argument T of the current instance.

Applies to