Class ArrayEqualityComparer<T>
An
The way to compare each element can be customized by specifying the ElementComparer.
Inheritance
Namespace: Libplanet.Common
Assembly: Libplanet.Common.dll
Syntax
public class ArrayEqualityComparer<T> : IEqualityComparer<T[]> where T : IEquatable<T>
Type Parameters
Name | Description |
---|---|
T | The element type of the array. |
Constructors
| Improve this Doc View SourceArrayEqualityComparer(Nullable<IEqualityComparer<T>>)
Creates a new instance of ArrayEqualityComparer<T>.
Declaration
public ArrayEqualityComparer(IEqualityComparer<T>? elementComparer = null)
Parameters
Type | Name | Description |
---|---|---|
System.Nullable<IEqualityComparer<T>> | elementComparer | Optionally customize the way to compare each element. |
Properties
| Improve this Doc View SourceElementComparer
Optionally customizes the way to compare each element.
Declaration
public IEqualityComparer<T>? ElementComparer { get; }
Property Value
Type | Description |
---|---|
System.Nullable<IEqualityComparer<T>> |
Methods
| Improve this Doc View SourceEquals(T[], T[])
An
The way to compare each element can be customized by specifying the ElementComparer.
Declaration
public bool Equals(T[] x, T[] y)
Parameters
Type | Name | Description |
---|---|---|
T[] | x | |
T[] | y |
Returns
Type | Description |
---|---|
System.Boolean |
GetHashCode(T[])
An
The way to compare each element can be customized by specifying the ElementComparer.
Declaration
public int GetHashCode(T[] obj)
Parameters
Type | Name | Description |
---|---|---|
T[] | obj |
Returns
Type | Description |
---|---|
System.Int32 |