System.UnicodeString.Compare

From RAD Studio API Documentation
Jump to: navigation, search

C++

int  Compare(const UnicodeString& rhs) const;
static int Compare(System::UnicodeString StrA, System::UnicodeString StrB);
static int Compare(System::UnicodeString StrA, System::UnicodeString StrB, unsigned int LocaleID);
static int Compare(System::UnicodeString StrA, System::UnicodeString StrB, bool IgnoreCase);
static int Compare(System::UnicodeString StrA, System::UnicodeString StrB, bool IgnoreCase, unsigned int LocaleID);
static int Compare(System::UnicodeString StrA, int IndexA, System::UnicodeString StrB, int IndexB, int Length);
static int Compare(System::UnicodeString StrA, int IndexA, System::UnicodeString StrB, int IndexB, int Length, unsigned int LocaleID);
static int Compare(System::UnicodeString StrA, int IndexA, System::UnicodeString StrB, int IndexB, int Length, bool IgnoreCase);
static int Compare(System::UnicodeString StrA, int IndexA, System::UnicodeString StrB, int IndexB, int Length, bool IgnoreCase, unsigned int LocaleID);

Properties

Type Visibility Source Unit Parent
function public ustring.h System UnicodeString

Description

Compares the UnicodeString to another specified string case-sensitively.

Compares a UnicodeString instance to rhs, with case-sensitivity. Use CompareIC to compare without case-sensitivity. The comparison operation should be the same as using the UnicodeString comparison operators. Compare is based on a locale-specific collating order. The return value is shown in the following table.



Condition Return Value

S1 > S2

> 0

S1 < S2

< 0

S1 = S2

= 0



See Also