Method GetNaturalComparer
GetNaturalComparer<T>()
Get the natural
The comparer returned depends on the
- If the type is
, the comparer returned uses the to make the comparison to ensure that the current culture doesn't affect the results. This is the default string comparison used in Java, and what Lucene's design depends on. - If the type implements
, the comparer uses for the comparison. This allows the use of types with custom comparison schemes. - If neither of the above conditions are true, will default to
.
NOTE: This was naturalComparer() in Lucene
Declaration
public static IComparer<T> GetNaturalComparer<T>()
Returns
Type | Description |
---|---|
IComparer<T> |
Type Parameters
Name | Description |
---|---|
T |