FloatEqualityComparer

Class in Zigurous.Math

Declaration

public sealed class FloatEqualityComparer : IEqualityComparer<float>

Description

Compares the equality of float values using a specified amount of decimal digits to compare.

Properties

digitsThe number of decimal digits to compare when determining equality.

Constructors

FloatEqualityComparerCreates a new FloatEqualityComparer with a default of 3 decimal digits to compare when determining equality.

Methods

EqualsChecks the equality of two float values.
GetHashCodeReturns a hash code for the float value.