Class SignedZeroComparer
LUCENENET specific comparer to handle the special case of comparing negative zero with positive zero.
For IEEE floating-point numbers, there is a distinction of negative and positive zero. Reference: http://stackoverflow.com/a/3139636
Inheritance
System.Object
SignedZeroComparer
Implements
System.Collections.Generic.IComparer<System.Double>
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Lucene.Net.Support
Assembly: Lucene.Net.dll
Syntax
public class SignedZeroComparer : IComparer<double>
Methods
| Improve this Doc View SourceCompare(Double, Double)
Declaration
public int Compare(double v1, double v2)
Parameters
Type | Name | Description |
---|---|---|
System.Double | v1 | |
System.Double | v2 |
Returns
Type | Description |
---|---|
System.Int32 |
Implements
System.Collections.Generic.IComparer<T>