StringComparer

Compares strings using the specified case and cultural comparision rules.

Constructors

this
this(Culture culture, bool ignoreCase)

Creates an instance that compares strings using the rules of the specified culture.

Members

Functions

compare
int compare(const(char)[] strA, const(char)[] strB)

Compares two strings and returns the sort order.

equals
bool equals(const(char)[] strA, const(char)[] strB)

Indicates whether the two strings are equal.

Static functions

currentCulture
StringComparer currentCulture()

Property. Retrieves an instance that performs case-sensitive comparisons using the rules of the current culture.

currentCultureIgnoreCase
StringComparer currentCultureIgnoreCase()

Property. Retrieves an instance that performs case-insensitive comparisons using the rules of the current culture.

invariantCulture
StringComparer invariantCulture()

Property. Retrieves an instance that performs case-sensitive comparisons using the rules of the invariant culture.

invariantCultureIgnoreCase
StringComparer invariantCultureIgnoreCase()

Property. Retrieves an instance that performs case-insensitive comparisons using the rules of the invariant culture.

Meta