StringSegmentComparerOrdinal Property

Gets a StringSegmentComparer object that performs a case-sensitive ordinal string comparison.
The methods of the returned StringSegmentComparer instance can be called with string, StringSegment and ReadOnlySpan<char> parameter values, which will not allocate new strings on any platform.

Definition

Namespace: KGySoft.CoreLibraries
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 7.0.0-rc.1
C#
public static StringSegmentComparer Ordinal { get; }

Property Value

StringSegmentComparer

Remarks

  Note

The comparer returned by this property does not generate randomized hash codes for strings no longer than 32 characters (and for longer strings it is platform-dependent). Use the OrdinalRandomized property to get a comparer with randomized hash for any lengths on all platforms.

See Also