Files
27Aug2021-Cpp2IL-Dump/mscorlib/System/Collections/Generic/EqualityComparer.cs
T
niko c12fbe3fc6 m
2026-04-12 16:51:38 +02:00

115 lines
5.1 KiB
C#

using System;
using System.Runtime.CompilerServices;
using Cpp2IlInjected;
namespace System.Collections.Generic
{
/// <summary>Provides a base class for implementations of the <see cref="T:System.Collections.Generic.IEqualityComparer`1" /> generic interface.</summary>
/// <typeparam name="T">The type of objects to compare.</typeparam>
// Token: 0x02000621 RID: 1569
[Token(Token = "0x2000621")]
[TypeDependency("System.Collections.Generic.ObjectEqualityComparer`1")]
[Serializable]
public abstract class EqualityComparer<T> : IEqualityComparer, IEqualityComparer<T>
{
/// <summary>Returns a default equality comparer for the type specified by the generic argument.</summary>
/// <returns>The default instance of the <see cref="T:System.Collections.Generic.EqualityComparer`1" /> class for type <typeparamref name="T" />.</returns>
// Token: 0x170007C7 RID: 1991
// (get) Token: 0x060030D1 RID: 12497 RVA: 0x00002082 File Offset: 0x00000282
[Token(Token = "0x170007C7")]
public static EqualityComparer<T> Default
{
[Token(Token = "0x60030D1")]
[Address(RVA = "0x2274810", Offset = "0x2273810", VA = "0x182274810")]
get
{
return null;
}
}
// Token: 0x060030D2 RID: 12498 RVA: 0x00002082 File Offset: 0x00000282
[Token(Token = "0x60030D2")]
[Address(RVA = "0x364A250", Offset = "0x3649250", VA = "0x18364A250")]
private static EqualityComparer<T> CreateComparer()
{
return null;
}
/// <summary>When overridden in a derived class, determines whether two objects of type <typeparamref name="T" /> are equal.</summary>
/// <param name="x">The first object to compare.</param>
/// <param name="y">The second object to compare.</param>
/// <returns>
/// <see langword="true" /> if the specified objects are equal; otherwise, <see langword="false" />.</returns>
// Token: 0x060030D3 RID: 12499
[Token(Token = "0x60030D3")]
[Address(Slot = "8")]
public abstract bool Equals(T x, T y);
/// <summary>When overridden in a derived class, serves as a hash function for the specified object for hashing algorithms and data structures, such as a hash table.</summary>
/// <param name="obj">The object for which to get a hash code.</param>
/// <returns>A hash code for the specified object.</returns>
/// <exception cref="T:System.ArgumentNullException">The type of <paramref name="obj" /> is a reference type and <paramref name="obj" /> is <see langword="null" />.</exception>
// Token: 0x060030D4 RID: 12500
[Token(Token = "0x60030D4")]
[Address(Slot = "9")]
public abstract int GetHashCode(T obj);
// Token: 0x060030D5 RID: 12501 RVA: 0x0001AA48 File Offset: 0x00018C48
[Token(Token = "0x60030D5")]
[Address(RVA = "0x35FB380", Offset = "0x35FA380", VA = "0x1835FB380", Slot = "10")]
internal virtual int IndexOf(T[] array, T value, int startIndex, int count)
{
return 0;
}
// Token: 0x060030D6 RID: 12502 RVA: 0x0001AA60 File Offset: 0x00018C60
[Token(Token = "0x60030D6")]
[Address(RVA = "0x35FBFE0", Offset = "0x35FAFE0", VA = "0x1835FBFE0", Slot = "11")]
internal virtual int LastIndexOf(T[] array, T value, int startIndex, int count)
{
return 0;
}
/// <summary>Returns a hash code for the specified object.</summary>
/// <param name="obj">The <see cref="T:System.Object" /> for which a hash code is to be returned.</param>
/// <returns>A hash code for the specified object.</returns>
/// <exception cref="T:System.ArgumentNullException">The type of <paramref name="obj" /> is a reference type and <paramref name="obj" /> is <see langword="null" />.
/// -or-
/// <paramref name="obj" /> is of a type that cannot be cast to type <typeparamref name="T" />.</exception>
// Token: 0x060030D7 RID: 12503 RVA: 0x0001AA78 File Offset: 0x00018C78
[Token(Token = "0x60030D7")]
[Address(RVA = "0x35FE720", Offset = "0x35FD720", VA = "0x1835FE720", Slot = "5")]
int IEqualityComparer.GetHashCode(object obj)
{
return 0;
}
/// <summary>Determines whether the specified objects are equal.</summary>
/// <param name="x">The first object to compare.</param>
/// <param name="y">The second object to compare.</param>
/// <returns>
/// <see langword="true" /> if the specified objects are equal; otherwise, <see langword="false" />.</returns>
/// <exception cref="T:System.ArgumentException">
/// <paramref name="x" /> or <paramref name="y" /> is of a type that cannot be cast to type <typeparamref name="T" />.</exception>
// Token: 0x060030D8 RID: 12504 RVA: 0x0001AA90 File Offset: 0x00018C90
[Token(Token = "0x60030D8")]
[Address(RVA = "0x35FCDC0", Offset = "0x35FBDC0", VA = "0x1835FCDC0", Slot = "4")]
bool IEqualityComparer.Equals(object x, object y)
{
return default(bool);
}
/// <summary>Initializes a new instance of the <see cref="T:System.Collections.Generic.EqualityComparer`1" /> class.</summary>
// Token: 0x060030D9 RID: 12505 RVA: 0x00002050 File Offset: 0x00000250
[Token(Token = "0x60030D9")]
[Address(RVA = "0x1CC5E40", Offset = "0x1CC4E40", VA = "0x181CC5E40")]
protected EqualityComparer()
{
}
// Token: 0x04001B0F RID: 6927
[Token(Token = "0x4001B0F")]
private static EqualityComparer<T> defaultComparer;
}
}