summaryrefslogtreecommitdiff
path: root/sal
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@suse.com>2011-10-21 10:08:02 +0100
committerMichael Meeks <michael.meeks@suse.com>2011-10-21 10:08:58 +0100
commite31496c9382ebdaa6ed1c6889c0d6ecde6f57de7 (patch)
tree8f3fe2225a29a82faad01dc80160269c700931ba /sal
parent034350a5097c2138311999b87da5621fe0d9d96e (diff)
misc trivial tweaks, and documentation addition
Diffstat (limited to 'sal')
-rw-r--r--sal/inc/rtl/ustring.hxx20
1 files changed, 20 insertions, 0 deletions
diff --git a/sal/inc/rtl/ustring.hxx b/sal/inc/rtl/ustring.hxx
index 63bab1894122..edf7c9747962 100644
--- a/sal/inc/rtl/ustring.hxx
+++ b/sal/inc/rtl/ustring.hxx
@@ -343,6 +343,8 @@ public:
@return 0 - if both strings are equal
< 0 - if this string is less than the string argument
> 0 - if this string is greater than the string argument
+
+ @since UDK 3.2.7
*/
sal_Int32 compareTo( const OUString & str, sal_Int32 maxLength ) const SAL_THROW(())
{
@@ -598,6 +600,24 @@ public:
return rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength( pData->buffer, pData->length, asciiStr ) == 0;
}
+ /**
+ Compares two ASCII strings ignoring case
+
+ The comparison is based on the numeric value of each character in
+ the strings and return a value indicating their relationship.
+ Since this method is optimized for performance, the ASCII character
+ values are not converted in any way. The caller has to make sure that
+ all ASCII characters are in the allowed range between 0 and
+ 127. The ASCII string must be NULL-terminated.
+ This function can't be used for language specific sorting.
+
+ @param asciiStr the 8-Bit ASCII character string to be compared.
+ @return 0 - if both strings are equal
+ < 0 - if this string is less than the string argument
+ > 0 - if this string is greater than the string argument
+
+ @since LibreOffice 3.5
+ */
sal_Int32 compareToIgnoreAsciiCaseAscii( const sal_Char * asciiStr ) const SAL_THROW(())
{
return rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength( pData->buffer, pData->length, asciiStr );