diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2020-09-11 22:05:12 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-09-12 13:36:42 +0200 |
commit | 04203a26757d26814a18c3251d1a97f6ded64a62 (patch) | |
tree | 80962f43d3b46e8670ad49068a1a6e8459c22f39 /include/rtl | |
parent | 05d5062dca095f2e53de26db41edeb0b1279138b (diff) |
Replace remaining uses of sal_Char
+ remove sal_Char check on compilerplugins
Change-Id: I0f7da14e620f0c3d031d038aa8345ba4080fb3e9
Change-Id: Ia6dba4f27b47bc9e0c89159182ad80a5aee17166
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102499
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/rtl')
-rw-r--r-- | include/rtl/math.h | 10 | ||||
-rw-r--r-- | include/rtl/math.hxx | 18 | ||||
-rw-r--r-- | include/rtl/strbuf.h | 4 | ||||
-rw-r--r-- | include/rtl/strbuf.hxx | 42 | ||||
-rw-r--r-- | include/rtl/string.h | 98 | ||||
-rw-r--r-- | include/rtl/string.hxx | 40 | ||||
-rw-r--r-- | include/rtl/tencinfo.h | 8 | ||||
-rw-r--r-- | include/rtl/textcvt.h | 4 | ||||
-rw-r--r-- | include/rtl/ustrbuf.h | 2 | ||||
-rw-r--r-- | include/rtl/ustrbuf.hxx | 4 | ||||
-rw-r--r-- | include/rtl/ustring.h | 24 | ||||
-rw-r--r-- | include/rtl/ustring.hxx | 26 |
12 files changed, 140 insertions, 140 deletions
diff --git a/include/rtl/math.h b/include/rtl/math.h index 8d23ce22a8b4..1132fe27bd5d 100644 --- a/include/rtl/math.h +++ b/include/rtl/math.h @@ -222,9 +222,9 @@ SAL_DLLPUBLIC void SAL_CALL rtl_math_doubleToString(rtl_String ** pResult, sal_Int32 nResultOffset, double fValue, enum rtl_math_StringFormat eFormat, sal_Int32 nDecPlaces, - sal_Char cDecSeparator, + char cDecSeparator, sal_Int32 const * pGroups, - sal_Char cGroupSeparator, + char cGroupSeparator, sal_Bool bEraseTrailingDecZeros) SAL_THROW_EXTERN_C(); @@ -339,9 +339,9 @@ SAL_DLLPUBLIC void SAL_CALL rtl_math_doubleToUString(rtl_uString ** pResult, whitespace. */ SAL_DLLPUBLIC double SAL_CALL rtl_math_stringToDouble( - sal_Char const * pBegin, sal_Char const * pEnd, sal_Char cDecSeparator, - sal_Char cGroupSeparator, enum rtl_math_ConversionStatus * pStatus, - sal_Char const ** pParsedEnd) SAL_THROW_EXTERN_C(); + char const * pBegin, char const * pEnd, char cDecSeparator, + char cGroupSeparator, enum rtl_math_ConversionStatus * pStatus, + char const ** pParsedEnd) SAL_THROW_EXTERN_C(); /** Conversion analogous to strtod(), convert a string representing a decimal number into a double value. diff --git a/include/rtl/math.hxx b/include/rtl/math.hxx index a965c7b38bca..c6633edddd0b 100644 --- a/include/rtl/math.hxx +++ b/include/rtl/math.hxx @@ -39,9 +39,9 @@ namespace math { */ inline rtl::OString doubleToString(double fValue, rtl_math_StringFormat eFormat, sal_Int32 nDecPlaces, - sal_Char cDecSeparator, + char cDecSeparator, sal_Int32 const * pGroups, - sal_Char cGroupSeparator, + char cGroupSeparator, bool bEraseTrailingDecZeros = false) { rtl::OString aResult; @@ -55,7 +55,7 @@ inline rtl::OString doubleToString(double fValue, rtl_math_StringFormat eFormat, */ inline rtl::OString doubleToString(double fValue, rtl_math_StringFormat eFormat, sal_Int32 nDecPlaces, - sal_Char cDecSeparator, + char cDecSeparator, bool bEraseTrailingDecZeros = false) { rtl::OString aResult; @@ -71,8 +71,8 @@ inline rtl::OString doubleToString(double fValue, rtl_math_StringFormat eFormat, */ inline void doubleToStringBuffer( rtl::OStringBuffer& rBuffer, double fValue, rtl_math_StringFormat eFormat, - sal_Int32 nDecPlaces, sal_Char cDecSeparator, sal_Int32 const * pGroups, - sal_Char cGroupSeparator, bool bEraseTrailingDecZeros = false) + sal_Int32 nDecPlaces, char cDecSeparator, sal_Int32 const * pGroups, + char cGroupSeparator, bool bEraseTrailingDecZeros = false) { rtl_String ** pData; sal_Int32 * pCapacity; @@ -89,7 +89,7 @@ inline void doubleToStringBuffer( */ inline void doubleToStringBuffer( rtl::OStringBuffer& rBuffer, double fValue, rtl_math_StringFormat eFormat, - sal_Int32 nDecPlaces, sal_Char cDecSeparator, + sal_Int32 nDecPlaces, char cDecSeparator, bool bEraseTrailingDecZeros = false) { rtl_String ** pData; @@ -170,12 +170,12 @@ inline void doubleToUStringBuffer( rtl::OUStringBuffer& rBuffer, double fValue, /** A wrapper around rtl_math_stringToDouble. */ inline double stringToDouble(rtl::OString const & rString, - sal_Char cDecSeparator, sal_Char cGroupSeparator, + char cDecSeparator, char cGroupSeparator, rtl_math_ConversionStatus * pStatus = NULL, sal_Int32 * pParsedEnd = NULL) { - sal_Char const * pBegin = rString.getStr(); - sal_Char const * pEnd; + char const * pBegin = rString.getStr(); + char const * pEnd; double fResult = rtl_math_stringToDouble(pBegin, pBegin + rString.getLength(), cDecSeparator, cGroupSeparator, diff --git a/include/rtl/strbuf.h b/include/rtl/strbuf.h index 7bd11e895085..872abb90b7cb 100644 --- a/include/rtl/strbuf.h +++ b/include/rtl/strbuf.h @@ -42,7 +42,7 @@ extern "C" { */ SAL_DLLPUBLIC void SAL_CALL rtl_stringbuffer_newFromStr_WithLength( rtl_String ** newStr, - const sal_Char * value, + const char * value, sal_Int32 count); /** @@ -110,7 +110,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_stringbuffer_insert( rtl_String ** This, sal_Int32 * capacity, sal_Int32 offset, - const sal_Char * str, + const char * str, sal_Int32 len); /** diff --git a/include/rtl/strbuf.hxx b/include/rtl/strbuf.hxx index e7e6cc01a2d0..83144a74afab 100644 --- a/include/rtl/strbuf.hxx +++ b/include/rtl/strbuf.hxx @@ -199,7 +199,7 @@ public: The character array length must be greater or equal than this value. */ - OStringBuffer(const sal_Char * value, sal_Int32 length) + OStringBuffer(const char * value, sal_Int32 length) : pData(NULL) , nCapacity( length + 16 ) { @@ -429,7 +429,7 @@ public: @return the character at the specified index of this string buffer. */ SAL_DEPRECATED("use rtl::OStringBuffer::operator [] instead") - sal_Char charAt( sal_Int32 index ) + char charAt( sal_Int32 index ) { assert(index >= 0 && index < pData->length); return pData->buffer[ index ]; @@ -446,7 +446,7 @@ public: @param ch the new character. */ SAL_DEPRECATED("use rtl::OStringBuffer::operator [] instead") - OStringBuffer & setCharAt(sal_Int32 index, sal_Char ch) + OStringBuffer & setCharAt(sal_Int32 index, char ch) { assert(index >= 0 && index < pData->length); pData->buffer[ index ] = ch; @@ -456,7 +456,7 @@ public: /** Return a null terminated character array. */ - const sal_Char* getStr() const SAL_RETURNS_NONNULL { return pData->buffer; } + const char* getStr() const SAL_RETURNS_NONNULL { return pData->buffer; } /** Access to individual characters. @@ -467,7 +467,7 @@ public: @since LibreOffice 3.5 */ - sal_Char & operator [](sal_Int32 index) + char & operator [](sal_Int32 index) { assert(index >= 0 && index < pData->length); return pData->buffer[index]; @@ -549,7 +549,7 @@ public: @param len the number of characters to append; must be non-negative @return this string buffer. */ - OStringBuffer & append( const sal_Char * str, sal_Int32 len) + OStringBuffer & append( const char * str, sal_Int32 len) { assert( len == 0 || str != NULL ); // cannot assert that in rtl_stringbuffer_insert rtl_stringbuffer_insert( &pData, &nCapacity, getLength(), str, len ); @@ -600,7 +600,7 @@ public: */ OStringBuffer & append(sal_Bool b) { - sal_Char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; + char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; return append( sz, rtl_str_valueOfBoolean( sz, b ) ); } @@ -619,7 +619,7 @@ public: */ OStringBuffer & append(bool b) { - sal_Char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; + char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; return append( sz, rtl_str_valueOfBoolean( sz, b ) ); } @@ -643,7 +643,7 @@ public: @param c a <code>char</code>. @return this string buffer. */ - OStringBuffer & append(sal_Char c) + OStringBuffer & append(char c) { return append( &c, 1 ); } @@ -662,7 +662,7 @@ public: */ OStringBuffer & append(sal_Int32 i, sal_Int16 radix = 10 ) { - sal_Char sz[RTL_STR_MAX_VALUEOFINT32]; + char sz[RTL_STR_MAX_VALUEOFINT32]; return append( sz, rtl_str_valueOfInt32( sz, i, radix ) ); } @@ -680,7 +680,7 @@ public: */ OStringBuffer & append(sal_Int64 l, sal_Int16 radix = 10 ) { - sal_Char sz[RTL_STR_MAX_VALUEOFINT64]; + char sz[RTL_STR_MAX_VALUEOFINT64]; return append( sz, rtl_str_valueOfInt64( sz, l, radix ) ); } @@ -697,7 +697,7 @@ public: */ OStringBuffer & append(float f) { - sal_Char sz[RTL_STR_MAX_VALUEOFFLOAT]; + char sz[RTL_STR_MAX_VALUEOFFLOAT]; return append( sz, rtl_str_valueOfFloat( sz, f ) ); } @@ -714,7 +714,7 @@ public: */ OStringBuffer & append(double d) { - sal_Char sz[RTL_STR_MAX_VALUEOFDOUBLE]; + char sz[RTL_STR_MAX_VALUEOFDOUBLE]; return append( sz, rtl_str_valueOfDouble( sz, d ) ); } @@ -823,7 +823,7 @@ public: @param len the number of characters to append. @return this string buffer. */ - OStringBuffer & insert( sal_Int32 offset, const sal_Char * str, sal_Int32 len) + OStringBuffer & insert( sal_Int32 offset, const char * str, sal_Int32 len) { assert( len == 0 || str != NULL ); // cannot assert that in rtl_stringbuffer_insert rtl_stringbuffer_insert( &pData, &nCapacity, offset, str, len ); @@ -849,7 +849,7 @@ public: */ OStringBuffer & insert(sal_Int32 offset, sal_Bool b) { - sal_Char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; + char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; return insert( offset, sz, rtl_str_valueOfBoolean( sz, b ) ); } @@ -874,7 +874,7 @@ public: */ OStringBuffer & insert(sal_Int32 offset, bool b) { - sal_Char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; + char sz[RTL_STR_MAX_VALUEOFBOOLEAN]; return insert( offset, sz, rtl_str_valueOfBoolean( sz, b ) ); } @@ -894,7 +894,7 @@ public: @param c a <code>char</code>. @return this string buffer. */ - OStringBuffer & insert(sal_Int32 offset, sal_Char c) + OStringBuffer & insert(sal_Int32 offset, char c) { return insert( offset, &c, 1 ); } @@ -919,7 +919,7 @@ public: */ OStringBuffer & insert(sal_Int32 offset, sal_Int32 i, sal_Int16 radix = 10 ) { - sal_Char sz[RTL_STR_MAX_VALUEOFINT32]; + char sz[RTL_STR_MAX_VALUEOFINT32]; return insert( offset, sz, rtl_str_valueOfInt32( sz, i, radix ) ); } @@ -943,7 +943,7 @@ public: */ OStringBuffer & insert(sal_Int32 offset, sal_Int64 l, sal_Int16 radix = 10 ) { - sal_Char sz[RTL_STR_MAX_VALUEOFINT64]; + char sz[RTL_STR_MAX_VALUEOFINT64]; return insert( offset, sz, rtl_str_valueOfInt64( sz, l, radix ) ); } @@ -966,7 +966,7 @@ public: */ OStringBuffer insert(sal_Int32 offset, float f) { - sal_Char sz[RTL_STR_MAX_VALUEOFFLOAT]; + char sz[RTL_STR_MAX_VALUEOFFLOAT]; return insert( offset, sz, rtl_str_valueOfFloat( sz, f ) ); } @@ -989,7 +989,7 @@ public: */ OStringBuffer & insert(sal_Int32 offset, double d) { - sal_Char sz[RTL_STR_MAX_VALUEOFDOUBLE]; + char sz[RTL_STR_MAX_VALUEOFDOUBLE]; return insert( offset, sz, rtl_str_valueOfDouble( sz, d ) ); } diff --git a/include/rtl/string.h b/include/rtl/string.h index 81322b186875..465f1b001b54 100644 --- a/include/rtl/string.h +++ b/include/rtl/string.h @@ -46,7 +46,7 @@ extern "C" { excluding the terminating NUL character. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_getLength( - const sal_Char * str ) SAL_THROW_EXTERN_C(); + const char * str ) SAL_THROW_EXTERN_C(); /** Compare two strings. @@ -67,7 +67,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_getLength( string is greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compare( - const sal_Char * first, const sal_Char * second ) SAL_THROW_EXTERN_C(); + const char * first, const char * second ) SAL_THROW_EXTERN_C(); /** Compare two strings. @@ -95,7 +95,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compare( string is greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compare_WithLength( - const sal_Char * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); + const char * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); /** Compare two strings with a maximum count of characters. @@ -127,7 +127,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compare_WithLength( substring is greater than the second substring. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_shortenedCompare_WithLength( - const sal_Char * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 secondLen, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); + const char * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); /** Compare two strings from back to front. @@ -155,7 +155,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_shortenedCompare_WithLength( first string compares greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_reverseCompare_WithLength( - const sal_Char * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); + const char * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); /** Compare two strings, ignoring the case of ASCII characters. @@ -177,7 +177,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_reverseCompare_WithLength( string is greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compareIgnoreAsciiCase( - const sal_Char * first, const sal_Char * second ) SAL_THROW_EXTERN_C(); + const char * first, const char * second ) SAL_THROW_EXTERN_C(); /** Compare two strings, ignoring the case of ASCII characters. @@ -207,7 +207,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compareIgnoreAsciiCase( string is greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compareIgnoreAsciiCase_WithLength( - const sal_Char * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); + const char * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); /** Compare two strings with a maximum count of characters, ignoring the case of ASCII characters. @@ -242,7 +242,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_compareIgnoreAsciiCase_WithLength( substring is greater than the second substring. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_shortenedCompareIgnoreAsciiCase_WithLength( - const sal_Char * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 secondLen, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); + const char * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); /** Return a hash code for a string. @@ -257,7 +257,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_shortenedCompareIgnoreAsciiCase_WithLen a hash code for the given string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_hashCode( - const sal_Char * str ) SAL_THROW_EXTERN_C(); + const char * str ) SAL_THROW_EXTERN_C(); /** Return a hash code for a string. @@ -275,7 +275,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_hashCode( a hash code for the given string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_hashCode_WithLength( - const sal_Char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); /** Search for the first occurrence of a character within a string. @@ -292,7 +292,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_hashCode_WithLength( string, or -1 if the character does not occur. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfChar( - const sal_Char * str, sal_Char ch ) SAL_THROW_EXTERN_C(); + const char * str, char ch ) SAL_THROW_EXTERN_C(); /** Search for the first occurrence of a character within a string. @@ -311,7 +311,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfChar( string, or -1 if the character does not occur. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfChar_WithLength( - const sal_Char * str, sal_Int32 len, sal_Char ch ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int32 len, char ch ) SAL_THROW_EXTERN_C(); /** Search for the last occurrence of a character within a string. @@ -329,7 +329,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfChar_WithLength( always smaller than the string length. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfChar( - const sal_Char * str, sal_Char ch ) SAL_THROW_EXTERN_C(); + const char * str, char ch ) SAL_THROW_EXTERN_C(); /** Search for the last occurrence of a character within a string. @@ -349,7 +349,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfChar( always smaller than the string length. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfChar_WithLength( - const sal_Char * str, sal_Int32 len, sal_Char ch ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int32 len, char ch ) SAL_THROW_EXTERN_C(); /** Search for the first occurrence of a substring within a string. @@ -367,7 +367,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfChar_WithLength( of the substring within the string, or -1 if the substring does not occur. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfStr( - const sal_Char * str, const sal_Char * subStr ) SAL_THROW_EXTERN_C(); + const char * str, const char * subStr ) SAL_THROW_EXTERN_C(); /** Search for the first occurrence of a substring within a string. @@ -392,7 +392,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfStr( of the substring within the string, or -1 if the substring does not occur. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfStr_WithLength( - const sal_Char * str, sal_Int32 len, const sal_Char * subStr, sal_Int32 subLen ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int32 len, const char * subStr, sal_Int32 subLen ) SAL_THROW_EXTERN_C(); /** Search for the last occurrence of a substring within a string. @@ -410,7 +410,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_indexOfStr_WithLength( of the substring within the string, or -1 if the substring does not occur. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfStr( - const sal_Char * str, const sal_Char * subStr ) SAL_THROW_EXTERN_C(); + const char * str, const char * subStr ) SAL_THROW_EXTERN_C(); /** Search for the last occurrence of a substring within a string. @@ -435,7 +435,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfStr( of the substring within the string, or -1 if the substring does not occur. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfStr_WithLength( - const sal_Char * str, sal_Int32 len, const sal_Char * subStr, sal_Int32 subLen ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int32 len, const char * subStr, sal_Int32 subLen ) SAL_THROW_EXTERN_C(); /** Replace all occurrences of a single character within a string. @@ -452,7 +452,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_lastIndexOfStr_WithLength( the new character. */ SAL_DLLPUBLIC void SAL_CALL rtl_str_replaceChar( - sal_Char * str, sal_Char oldChar, sal_Char newChar ) SAL_THROW_EXTERN_C(); + char * str, char oldChar, char newChar ) SAL_THROW_EXTERN_C(); /** Replace all occurrences of a single character within a string. @@ -472,7 +472,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_str_replaceChar( the new character. */ SAL_DLLPUBLIC void SAL_CALL rtl_str_replaceChar_WithLength( - sal_Char * str, sal_Int32 len, sal_Char oldChar, sal_Char newChar ) SAL_THROW_EXTERN_C(); + char * str, sal_Int32 len, char oldChar, char newChar ) SAL_THROW_EXTERN_C(); /** Convert all ASCII uppercase letters to lowercase within a string. @@ -484,7 +484,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_str_replaceChar_WithLength( a null-terminated string. */ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiLowerCase( - sal_Char * str ) SAL_THROW_EXTERN_C(); + char * str ) SAL_THROW_EXTERN_C(); /** Convert all ASCII uppercase letters to lowercase within a string. @@ -499,7 +499,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiLowerCase( the length of the string. */ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiLowerCase_WithLength( - sal_Char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); + char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); /** Convert all ASCII lowercase letters to uppercase within a string. @@ -511,7 +511,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiLowerCase_WithLength( a null-terminated string. */ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiUpperCase( - sal_Char * str ) SAL_THROW_EXTERN_C(); + char * str ) SAL_THROW_EXTERN_C(); /** Convert all ASCII lowercase letters to uppercase within a string. @@ -526,7 +526,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiUpperCase( the length of the string. */ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiUpperCase_WithLength( - sal_Char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); + char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); /** Remove white space from both ends of a string. @@ -541,7 +541,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_str_toAsciiUpperCase_WithLength( the new length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_trim( - sal_Char * str ) SAL_THROW_EXTERN_C(); + char * str ) SAL_THROW_EXTERN_C(); /** Remove white space from both ends of the string. @@ -560,7 +560,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_trim( the new length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_trim_WithLength( - sal_Char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); + char * str, sal_Int32 len ) SAL_THROW_EXTERN_C(); /** Create the string representation of a boolean. @@ -581,7 +581,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_trim_WithLength( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfBoolean( - sal_Char * str, sal_Bool b ) SAL_THROW_EXTERN_C(); + char * str, sal_Bool b ) SAL_THROW_EXTERN_C(); #define RTL_STR_MAX_VALUEOFBOOLEAN 6 /** Create the string representation of a character. @@ -598,7 +598,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfBoolean( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfChar( - sal_Char * str, sal_Char ch ) SAL_THROW_EXTERN_C(); + char * str, char ch ) SAL_THROW_EXTERN_C(); #define RTL_STR_MAX_VALUEOFCHAR 2 /** Create the string representation of an integer. @@ -621,7 +621,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfChar( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfInt32( - sal_Char * str, sal_Int32 i, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + char * str, sal_Int32 i, sal_Int16 radix ) SAL_THROW_EXTERN_C(); #define RTL_STR_MIN_RADIX 2 #define RTL_STR_MAX_RADIX 36 #define RTL_STR_MAX_VALUEOFINT32 33 @@ -646,7 +646,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfInt32( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfInt64( - sal_Char * str, sal_Int64 l, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + char * str, sal_Int64 l, sal_Int16 radix ) SAL_THROW_EXTERN_C(); #define RTL_STR_MAX_VALUEOFINT64 65 /** Create the string representation of an unsigned long integer. @@ -669,7 +669,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfInt64( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfUInt64( - sal_Char * str, sal_uInt64 l, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + char * str, sal_uInt64 l, sal_Int16 radix ) SAL_THROW_EXTERN_C(); #define RTL_STR_MAX_VALUEOFUINT64 65 /** Create the string representation of a float. @@ -688,7 +688,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfUInt64( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfFloat( - sal_Char * str, float f ) SAL_THROW_EXTERN_C(); + char * str, float f ) SAL_THROW_EXTERN_C(); #define RTL_STR_MAX_VALUEOFFLOAT 15 /** Create the string representation of a double. @@ -707,7 +707,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfFloat( the length of the string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfDouble( - sal_Char * str, double d ) SAL_THROW_EXTERN_C(); + char * str, double d ) SAL_THROW_EXTERN_C(); #define RTL_STR_MAX_VALUEOFDOUBLE 25 /** Interpret a string as a boolean. @@ -722,7 +722,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_valueOfDouble( true if the string is "1" or "true" in any ASCII case, false otherwise. */ SAL_DLLPUBLIC sal_Bool SAL_CALL rtl_str_toBoolean( - const sal_Char * str ) SAL_THROW_EXTERN_C(); + const char * str ) SAL_THROW_EXTERN_C(); /** Interpret a string as an integer. @@ -741,7 +741,7 @@ SAL_DLLPUBLIC sal_Bool SAL_CALL rtl_str_toBoolean( represent an integer. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_toInt32( - const sal_Char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); /** Interpret a string as an unsigned integer. @@ -762,7 +762,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_str_toInt32( @since LibreOffice 4.2 */ SAL_DLLPUBLIC sal_uInt32 SAL_CALL rtl_str_toUInt32( - const sal_Char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); /** Interpret a string as a long integer. @@ -781,7 +781,7 @@ SAL_DLLPUBLIC sal_uInt32 SAL_CALL rtl_str_toUInt32( not represent a long integer. */ SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64( - const sal_Char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); /** Interpret a string as a long integer. @@ -796,7 +796,7 @@ SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64( (36), inclusive. @param nStrLength - number of sal_Chars to process + number of chars to process @return the long integer value represented by the string, or 0 if the string does @@ -806,7 +806,7 @@ SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64( @since LibreOffice 6.4 */ SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64_WithLength( - const sal_Char * str, sal_Int16 radix, sal_Int32 nStrLength ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int16 radix, sal_Int32 nStrLength ) SAL_THROW_EXTERN_C(); /** Interpret a string as an unsigned long integer. @@ -827,7 +827,7 @@ SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_str_toInt64_WithLength( @since LibreOffice 4.1 */ SAL_DLLPUBLIC sal_uInt64 SAL_CALL rtl_str_toUInt64( - const sal_Char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); + const char * str, sal_Int16 radix ) SAL_THROW_EXTERN_C(); /** Interpret a string as a float. @@ -842,7 +842,7 @@ SAL_DLLPUBLIC sal_uInt64 SAL_CALL rtl_str_toUInt64( represent a float. */ SAL_DLLPUBLIC float SAL_CALL rtl_str_toFloat( - const sal_Char * str ) SAL_THROW_EXTERN_C(); + const char * str ) SAL_THROW_EXTERN_C(); /** Interpret a string as a double. @@ -857,7 +857,7 @@ SAL_DLLPUBLIC float SAL_CALL rtl_str_toFloat( represent a double. */ SAL_DLLPUBLIC double SAL_CALL rtl_str_toDouble( - const sal_Char * str ) SAL_THROW_EXTERN_C(); + const char * str ) SAL_THROW_EXTERN_C(); /* ======================================================================= */ @@ -872,7 +872,7 @@ typedef struct _rtl_String { oslInterlockedCount refCount; /* opaque */ sal_Int32 length; - sal_Char buffer[1]; + char buffer[1]; } rtl_String; /** @endcond */ @@ -973,7 +973,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromString( rtl_String ** newStr, cons @param value a null-terminated character array. */ -SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromStr( rtl_String ** newStr, const sal_Char * value ) SAL_THROW_EXTERN_C(); +SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromStr( rtl_String ** newStr, const char * value ) SAL_THROW_EXTERN_C(); /** Allocate a new string that contains a copy of a character array. @@ -992,7 +992,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromStr( rtl_String ** newStr, const s @param len the length of the character array. */ -SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromStr_WithLength( rtl_String ** newStr, const sal_Char * value, sal_Int32 len ) SAL_THROW_EXTERN_C(); +SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromStr_WithLength( rtl_String ** newStr, const char * value, sal_Int32 len ) SAL_THROW_EXTERN_C(); /** Allocate a new string that is a substring of this string. @@ -1016,7 +1016,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromSubString( @internal @since LibreOffice 3.6 */ -SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromLiteral( rtl_String ** newStr, const sal_Char * value, sal_Int32 len, sal_Int32 allocExtra ) SAL_THROW_EXTERN_C(); +SAL_DLLPUBLIC void SAL_CALL rtl_string_newFromLiteral( rtl_String ** newStr, const char * value, sal_Int32 len, sal_Int32 allocExtra ) SAL_THROW_EXTERN_C(); /** Assign a new value to a string. @@ -1052,7 +1052,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_string_getLength( const rtl_String * str ) @return a pointer to the null-terminated character array. */ -SAL_DLLPUBLIC sal_Char * SAL_CALL rtl_string_getStr( rtl_String * str ) SAL_THROW_EXTERN_C(); +SAL_DLLPUBLIC char * SAL_CALL rtl_string_getStr( rtl_String * str ) SAL_THROW_EXTERN_C(); /** Create a new string that is the concatenation of two other strings. @@ -1130,7 +1130,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_string_newReplaceStrAt( the new character. */ SAL_DLLPUBLIC void SAL_CALL rtl_string_newReplace( - rtl_String ** newStr, rtl_String * str, sal_Char oldChar, sal_Char newChar ) SAL_THROW_EXTERN_C(); + rtl_String ** newStr, rtl_String * str, char oldChar, char newChar ) SAL_THROW_EXTERN_C(); /** Create a new string by replacing the first occurrence of a given substring with another substring. @@ -1303,7 +1303,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_string_newTrim( the index of the next token, or -1 if no more tokens follow. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_string_getToken( - rtl_String ** newStr , rtl_String * str, sal_Int32 token, sal_Char cTok, sal_Int32 idx ) SAL_THROW_EXTERN_C(); + rtl_String ** newStr , rtl_String * str, sal_Int32 token, char cTok, sal_Int32 idx ) SAL_THROW_EXTERN_C(); /* ======================================================================= */ diff --git a/include/rtl/string.hxx b/include/rtl/string.hxx index 3a95b807c3a0..e59ffba83a62 100644 --- a/include/rtl/string.hxx +++ b/include/rtl/string.hxx @@ -218,7 +218,7 @@ public: @param value a character. */ - explicit OString( sal_Char value ) + explicit OString( char value ) : pData (NULL) { rtl_string_newFromStr_WithLength( &pData, &value, 1 ); @@ -284,7 +284,7 @@ public: The character array length must be greater or equal than this value. */ - OString( const sal_Char * value, sal_Int32 length ) + OString( const char * value, sal_Int32 length ) { pData = NULL; rtl_string_newFromStr_WithLength( &pData, value, length ); @@ -529,7 +529,7 @@ public: @return a pointer to a null-terminated byte string representing the characters of this string object. */ - const sal_Char * getStr() const SAL_RETURNS_NONNULL { return pData->buffer; } + const char * getStr() const SAL_RETURNS_NONNULL { return pData->buffer; } /** Access to individual characters. @@ -540,7 +540,7 @@ public: @since LibreOffice 3.5 */ - sal_Char operator [](sal_Int32 index) const { + char operator [](sal_Int32 index) const { // silence spurious -Werror=strict-overflow warnings from GCC 4.8.2 assert(index >= 0 && static_cast<sal_uInt32>(index) < static_cast<sal_uInt32>(getLength())); return getStr()[index]; @@ -637,7 +637,7 @@ public: @return true if the strings are equal; false, otherwise. */ - bool equalsL( const sal_Char* value, sal_Int32 length ) const + bool equalsL( const char* value, sal_Int32 length ) const { if ( pData->length != length ) return false; @@ -744,7 +744,7 @@ public: @return true if the strings are equal; false, otherwise. */ - bool equalsIgnoreAsciiCaseL( const sal_Char * asciiStr, sal_Int32 asciiStrLength ) const + bool equalsIgnoreAsciiCaseL( const char * asciiStr, sal_Int32 asciiStrLength ) const { if ( pData->length != asciiStrLength ) return false; @@ -1185,7 +1185,7 @@ public: greater than or equal to fromIndex, or -1 if the character does not occur. */ - sal_Int32 indexOf( sal_Char ch, sal_Int32 fromIndex = 0 ) const + sal_Int32 indexOf( char ch, sal_Int32 fromIndex = 0 ) const { sal_Int32 ret = rtl_str_indexOfChar_WithLength( pData->buffer+fromIndex, pData->length-fromIndex, ch ); return (ret < 0 ? ret : ret+fromIndex); @@ -1200,7 +1200,7 @@ public: character sequence represented by this string, or -1 if the character does not occur. */ - sal_Int32 lastIndexOf( sal_Char ch ) const + sal_Int32 lastIndexOf( char ch ) const { return rtl_str_lastIndexOfChar_WithLength( pData->buffer, pData->length, ch ); } @@ -1217,7 +1217,7 @@ public: is less than fromIndex, or -1 if the character does not occur before that point. */ - sal_Int32 lastIndexOf( sal_Char ch, sal_Int32 fromIndex ) const + sal_Int32 lastIndexOf( char ch, sal_Int32 fromIndex ) const { return rtl_str_lastIndexOfChar_WithLength( pData->buffer, fromIndex, ch ); } @@ -1429,7 +1429,7 @@ public: @return a string derived from this string by replacing every occurrence of oldChar with newChar. */ - SAL_WARN_UNUSED_RESULT OString replace( sal_Char oldChar, sal_Char newChar ) const + SAL_WARN_UNUSED_RESULT OString replace( char oldChar, char newChar ) const { rtl_String* pNew = NULL; rtl_string_newReplace( &pNew, pData, oldChar, newChar ); @@ -1562,7 +1562,7 @@ public: @return the token; if either token or index is negative, an empty token is returned (and index is set to -1) */ - OString getToken( sal_Int32 token, sal_Char cTok, sal_Int32& index ) const + OString getToken( sal_Int32 token, char cTok, sal_Int32& index ) const { rtl_String * pNew = NULL; index = rtl_string_getToken( &pNew, pData, token, cTok, index ); @@ -1572,7 +1572,7 @@ public: /** Returns a token from the string. - The same as getToken(sal_Int32, sal_Char, sal_Int32 &), but always passing + The same as getToken(sal_Int32, char, sal_Int32 &), but always passing in 0 as the start index in the third argument. @param count the number of the token to return, starting with 0 @@ -1606,7 +1606,7 @@ public: @return the first character from this string or 0, if this string is empty. */ - sal_Char toChar() const + char toChar() const { return pData->buffer[0]; } @@ -1748,7 +1748,7 @@ public: */ static OString number( int i, sal_Int16 radix = 10 ) { - sal_Char aBuf[RTL_STR_MAX_VALUEOFINT32]; + char aBuf[RTL_STR_MAX_VALUEOFINT32]; return OString(aBuf, rtl_str_valueOfInt32(aBuf, i, radix)); } /// @overload @@ -1773,14 +1773,14 @@ public: /// @since LibreOffice 4.1 static OString number( long long ll, sal_Int16 radix = 10 ) { - sal_Char aBuf[RTL_STR_MAX_VALUEOFINT64]; + char aBuf[RTL_STR_MAX_VALUEOFINT64]; return OString(aBuf, rtl_str_valueOfInt64(aBuf, ll, radix)); } /// @overload /// @since LibreOffice 4.1 static OString number( unsigned long long ll, sal_Int16 radix = 10 ) { - sal_Char aBuf[RTL_STR_MAX_VALUEOFUINT64]; + char aBuf[RTL_STR_MAX_VALUEOFUINT64]; return OString(aBuf, rtl_str_valueOfUInt64(aBuf, ll, radix)); } @@ -1795,7 +1795,7 @@ public: */ static OString number( float f ) { - sal_Char aBuf[RTL_STR_MAX_VALUEOFFLOAT]; + char aBuf[RTL_STR_MAX_VALUEOFFLOAT]; return OString(aBuf, rtl_str_valueOfFloat(aBuf, f)); } @@ -1810,7 +1810,7 @@ public: */ static OString number( double d ) { - sal_Char aBuf[RTL_STR_MAX_VALUEOFDOUBLE]; + char aBuf[RTL_STR_MAX_VALUEOFDOUBLE]; return OString(aBuf, rtl_str_valueOfDouble(aBuf, d)); } #endif @@ -1844,7 +1844,7 @@ public: */ static OString boolean( bool b ) { - sal_Char aBuf[RTL_STR_MAX_VALUEOFBOOLEAN]; + char aBuf[RTL_STR_MAX_VALUEOFBOOLEAN]; return OString(aBuf, rtl_str_valueOfBoolean(aBuf, b)); } @@ -1855,7 +1855,7 @@ public: @return a string with the string representation of the argument. @deprecated use operator, function or constructor taking char or sal_Unicode argument */ - SAL_DEPRECATED("convert to OString or use directly") static OString valueOf( sal_Char c ) + SAL_DEPRECATED("convert to OString or use directly") static OString valueOf( char c ) { return OString( &c, 1 ); } diff --git a/include/rtl/tencinfo.h b/include/rtl/tencinfo.h index 74c3bb04f071..b1870854173a 100644 --- a/include/rtl/tencinfo.h +++ b/include/rtl/tencinfo.h @@ -186,7 +186,7 @@ SAL_DLLPUBLIC rtl_TextEncoding SAL_CALL rtl_getTextEncodingFromWindowsCharset( no mapping is applicable. */ SAL_DLLPUBLIC rtl_TextEncoding SAL_CALL rtl_getTextEncodingFromMimeCharset( - const sal_Char* pMimeCharset ); + const char* pMimeCharset ); /** Map from a Unix charset to a text encoding. @@ -198,7 +198,7 @@ SAL_DLLPUBLIC rtl_TextEncoding SAL_CALL rtl_getTextEncodingFromMimeCharset( no mapping is applicable. */ SAL_DLLPUBLIC rtl_TextEncoding SAL_CALL rtl_getTextEncodingFromUnixCharset( - const sal_Char* pUnixCharset ); + const char* pUnixCharset ); /** Map from a text encoding to the best matching numeric Windows charset. @@ -232,7 +232,7 @@ SAL_DLLPUBLIC char const * SAL_CALL rtl_getMimeCharsetFromTextEncoding( @return The best matching MIME charset string, or null if none matches. */ -SAL_DLLPUBLIC const sal_Char* SAL_CALL rtl_getBestMimeCharsetFromTextEncoding( +SAL_DLLPUBLIC const char* SAL_CALL rtl_getBestMimeCharsetFromTextEncoding( rtl_TextEncoding eTextEncoding ); /** Map from a text encoding to the best matching Unix charset. @@ -243,7 +243,7 @@ SAL_DLLPUBLIC const sal_Char* SAL_CALL rtl_getBestMimeCharsetFromTextEncoding( @return The best matching Unix charset string, or null if none matches. */ -SAL_DLLPUBLIC const sal_Char* SAL_CALL rtl_getBestUnixCharsetFromTextEncoding( +SAL_DLLPUBLIC const char* SAL_CALL rtl_getBestUnixCharsetFromTextEncoding( rtl_TextEncoding eTextEncoding ); /** Map from a Windows code page to a text encoding. diff --git a/include/rtl/textcvt.h b/include/rtl/textcvt.h index 67e9f55e0f65..dc6db0be7302 100644 --- a/include/rtl/textcvt.h +++ b/include/rtl/textcvt.h @@ -105,7 +105,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_resetTextToUnicodeContext( rtl_TextToUnicodeConv SAL_DLLPUBLIC sal_Size SAL_CALL rtl_convertTextToUnicode( rtl_TextToUnicodeConverter hConverter, rtl_TextToUnicodeContext hContext, - const sal_Char* pSrcBuf, sal_Size nSrcBytes, + const char* pSrcBuf, sal_Size nSrcBytes, sal_Unicode* pDestBuf, sal_Size nDestChars, sal_uInt32 nFlags, sal_uInt32* pInfo, sal_Size* pSrcCvtBytes ); @@ -177,7 +177,7 @@ SAL_DLLPUBLIC sal_Size SAL_CALL rtl_convertUnicodeToText( rtl_UnicodeToTextConverter hConverter, rtl_UnicodeToTextContext hContext, const sal_Unicode* pSrcBuf, sal_Size nSrcChars, - sal_Char* pDestBuf, sal_Size nDestBytes, + char* pDestBuf, sal_Size nDestBytes, sal_uInt32 nFlags, sal_uInt32* pInfo, sal_Size* pSrcCvtChars ); diff --git a/include/rtl/ustrbuf.h b/include/rtl/ustrbuf.h index 9c24724f540e..d2cc2f752fc6 100644 --- a/include/rtl/ustrbuf.h +++ b/include/rtl/ustrbuf.h @@ -157,7 +157,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_uStringbuffer_insert_ascii( /*inout*/rtl_uString ** This, /*inout*/sal_Int32 * capacity, sal_Int32 offset, - const sal_Char * str, + const char * str, sal_Int32 len); /** diff --git a/include/rtl/ustrbuf.hxx b/include/rtl/ustrbuf.hxx index a4936b8fd186..9800ba8d3020 100644 --- a/include/rtl/ustrbuf.hxx +++ b/include/rtl/ustrbuf.hxx @@ -710,7 +710,7 @@ public: @param str the 8-Bit ASCII characters to be appended. @return this string buffer. */ - OUStringBuffer & appendAscii( const sal_Char * str ) + OUStringBuffer & appendAscii( const char * str ) { return appendAscii( str, rtl_str_getLength( str ) ); } @@ -733,7 +733,7 @@ public: @param len the number of characters to append; must be non-negative @return this string buffer. */ - OUStringBuffer & appendAscii( const sal_Char * str, sal_Int32 len) + OUStringBuffer & appendAscii( const char * str, sal_Int32 len) { rtl_uStringbuffer_insert_ascii( &pData, &nCapacity, getLength(), str, len ); return *this; diff --git a/include/rtl/ustring.h b/include/rtl/ustring.h index 1595cdf4f3ab..abd33bb77f15 100644 --- a/include/rtl/ustring.h +++ b/include/rtl/ustring.h @@ -180,7 +180,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_reverseCompare_WithLength( */ SAL_DLLPUBLIC sal_Bool SAL_CALL rtl_ustr_asciil_reverseEquals_WithLength( - const sal_Unicode * first, const sal_Char * second, sal_Int32 len ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, const char * second, sal_Int32 len ) SAL_THROW_EXTERN_C(); /** Compare two strings, ignoring the case of ASCII characters. @@ -293,7 +293,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_shortenedCompareIgnoreAsciiCase_WithLe substring is greater than the second substring. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compare( - const sal_Unicode * first, const sal_Char * second ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, const char * second ) SAL_THROW_EXTERN_C(); /** Compare two strings. @@ -322,7 +322,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compare( substring is greater than the second substring. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compare_WithLength( - const sal_Unicode * first, sal_Int32 firstLen, const sal_Char * second ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, sal_Int32 firstLen, const char * second ) SAL_THROW_EXTERN_C(); /** Compare two strings with a maximum count of characters. @@ -355,7 +355,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compare_WithLength( substring is greater than the second substring. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_shortenedCompare_WithLength( - const sal_Unicode * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, sal_Int32 firstLen, const char * second, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); /** Compare two strings from back to front. @@ -387,7 +387,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_shortenedCompare_WithLength( first string compares greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_asciil_reverseCompare_WithLength( - const sal_Unicode * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C(); /** Compare two strings, ignoring the case of ASCII characters. @@ -414,7 +414,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_asciil_reverseCompare_WithLength( string is greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase( - const sal_Unicode * first, const sal_Char * second ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, const char * second ) SAL_THROW_EXTERN_C(); /** Compare two strings, ignoring the case of ASCII characters. @@ -445,7 +445,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase( string is greater than the second string. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength( - const sal_Unicode * first, sal_Int32 firstLen, const sal_Char * second ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, sal_Int32 firstLen, const char * second ) SAL_THROW_EXTERN_C(); /** Compare two strings, ignoring the case of ASCII characters. @@ -516,7 +516,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase_WithLengt substring is greater than the second substring. */ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength( - const sal_Unicode * first, sal_Int32 firstLen, const sal_Char * second, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); + const sal_Unicode * first, sal_Int32 firstLen, const char * second, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C(); /** Return a hash code for a string. @@ -1368,14 +1368,14 @@ SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromSubString( a null-terminated ASCII character array. */ SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromAscii( - rtl_uString ** newStr, const sal_Char * value ) SAL_THROW_EXTERN_C(); + rtl_uString ** newStr, const char * value ) SAL_THROW_EXTERN_C(); /** @internal @since LibreOffice 3.6 */ SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromLiteral( - rtl_uString ** newStr, const sal_Char * value, sal_Int32 len, + rtl_uString ** newStr, const char * value, sal_Int32 len, sal_Int32 allocExtra ) SAL_THROW_EXTERN_C(); /** Allocate a new string from an array of Unicode code points. @@ -2216,7 +2216,7 @@ SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_uString_getToken( details. */ SAL_DLLPUBLIC void SAL_CALL rtl_string2UString( - rtl_uString ** newStr, const sal_Char * str, sal_Int32 len, rtl_TextEncoding encoding, sal_uInt32 convertFlags ) SAL_THROW_EXTERN_C(); + rtl_uString ** newStr, const char * str, sal_Int32 len, rtl_TextEncoding encoding, sal_uInt32 convertFlags ) SAL_THROW_EXTERN_C(); /* ======================================================================= */ /* Interning methods */ @@ -2280,7 +2280,7 @@ SAL_DLLPUBLIC void SAL_CALL rtl_uString_intern( */ SAL_DLLPUBLIC void SAL_CALL rtl_uString_internConvert( rtl_uString ** newStr, - const sal_Char * str, + const char * str, sal_Int32 len, rtl_TextEncoding encoding, sal_uInt32 convertFlags, diff --git a/include/rtl/ustring.hxx b/include/rtl/ustring.hxx index 035f407c7672..eebdc261e4f1 100644 --- a/include/rtl/ustring.hxx +++ b/include/rtl/ustring.hxx @@ -378,7 +378,7 @@ public: @exception std::bad_alloc is thrown if an out-of-memory condition occurs */ - OUString( const sal_Char * value, sal_Int32 length, + OUString( const char * value, sal_Int32 length, rtl_TextEncoding encoding, sal_uInt32 convertFlags = OSTRING_TO_OUSTRING_CVTFLAGS ) { @@ -1067,7 +1067,7 @@ public: < 0 - if this string is less than the string argument > 0 - if this string is greater than the string argument */ - sal_Int32 compareToAscii( const sal_Char* asciiStr ) const + sal_Int32 compareToAscii( const char* asciiStr ) const { return rtl_ustr_ascii_compare_WithLength( pData->buffer, pData->length, asciiStr ); } @@ -1096,7 +1096,7 @@ public: */ SAL_DEPRECATED( "replace s1.compareToAscii(s2, strlen(s2)) == 0 with s1.startsWith(s2)") - sal_Int32 compareToAscii( const sal_Char * asciiStr, sal_Int32 maxLength ) const + sal_Int32 compareToAscii( const char * asciiStr, sal_Int32 maxLength ) const { return rtl_ustr_ascii_shortenedCompare_WithLength( pData->buffer, pData->length, asciiStr, maxLength ); @@ -1121,7 +1121,7 @@ public: < 0 - if this string is less than the string argument > 0 - if this string is greater than the string argument */ - sal_Int32 reverseCompareToAsciiL( const sal_Char * asciiStr, sal_Int32 asciiStrLength ) const + sal_Int32 reverseCompareToAsciiL( const char * asciiStr, sal_Int32 asciiStrLength ) const { return rtl_ustr_asciil_reverseCompare_WithLength( pData->buffer, pData->length, asciiStr, asciiStrLength ); @@ -1142,7 +1142,7 @@ public: @return true if the strings are equal; false, otherwise. */ - bool equalsAscii( const sal_Char* asciiStr ) const + bool equalsAscii( const char* asciiStr ) const { return rtl_ustr_ascii_compare_WithLength( pData->buffer, pData->length, asciiStr ) == 0; @@ -1165,7 +1165,7 @@ public: @return true if the strings are equal; false, otherwise. */ - bool equalsAsciiL( const sal_Char* asciiStr, sal_Int32 asciiStrLength ) const + bool equalsAsciiL( const char* asciiStr, sal_Int32 asciiStrLength ) const { if ( pData->length != asciiStrLength ) return false; @@ -1192,7 +1192,7 @@ public: @return true if the strings are equal; false, otherwise. */ - bool equalsIgnoreAsciiCaseAscii( const sal_Char * asciiStr ) const + bool equalsIgnoreAsciiCaseAscii( const char * asciiStr ) const { return rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength( pData->buffer, pData->length, asciiStr ) == 0; } @@ -1215,7 +1215,7 @@ public: @since LibreOffice 3.5 */ - sal_Int32 compareToIgnoreAsciiCaseAscii( const sal_Char * asciiStr ) const + sal_Int32 compareToIgnoreAsciiCaseAscii( const char * asciiStr ) const { return rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength( pData->buffer, pData->length, asciiStr ); } @@ -1240,7 +1240,7 @@ public: @return true if the strings are equal; false, otherwise. */ - bool equalsIgnoreAsciiCaseAsciiL( const sal_Char * asciiStr, sal_Int32 asciiStrLength ) const + bool equalsIgnoreAsciiCaseAsciiL( const char * asciiStr, sal_Int32 asciiStrLength ) const { if ( pData->length != asciiStrLength ) return false; @@ -1269,7 +1269,7 @@ public: at the given position; false, otherwise. */ - bool matchAsciiL( const sal_Char* asciiStr, sal_Int32 asciiStrLength, sal_Int32 fromIndex = 0 ) const + bool matchAsciiL( const char* asciiStr, sal_Int32 asciiStrLength, sal_Int32 fromIndex = 0 ) const { return rtl_ustr_ascii_shortenedCompare_WithLength( pData->buffer+fromIndex, pData->length-fromIndex, asciiStr, asciiStrLength ) == 0; @@ -1307,7 +1307,7 @@ public: at the given position; false, otherwise. */ - bool matchIgnoreAsciiCaseAsciiL( const sal_Char* asciiStr, sal_Int32 asciiStrLength, sal_Int32 fromIndex = 0 ) const + bool matchIgnoreAsciiCaseAsciiL( const char* asciiStr, sal_Int32 asciiStrLength, sal_Int32 fromIndex = 0 ) const { return rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength( pData->buffer+fromIndex, pData->length-fromIndex, asciiStr, asciiStrLength ) == 0; @@ -2826,7 +2826,7 @@ public: @since UDK 3.2.7 */ - static OUString intern( const sal_Char * value, sal_Int32 length, + static OUString intern( const char * value, sal_Int32 length, rtl_TextEncoding encoding, sal_uInt32 convertFlags = OSTRING_TO_OUSTRING_CVTFLAGS, sal_uInt32 *pInfo = NULL ) @@ -3206,7 +3206,7 @@ public: @param value the 8-Bit ASCII character string @return a string with the string representation of the argument. */ - static OUString createFromAscii( const sal_Char * value ) + static OUString createFromAscii( const char * value ) { rtl_uString* pNew = NULL; rtl_uString_newFromAscii( &pNew, value ); |