LibreOffice LibreOffice 24.2 SDK C/C++ API Reference

Loading...
Searching...
No Matches
ustring.h
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20/*
21 * This file is part of LibreOffice published API.
22 */
23
24#ifndef INCLUDED_RTL_USTRING_H
25#define INCLUDED_RTL_USTRING_H
26
27#include "sal/config.h"
28
29#include "osl/interlck.h"
30#include "rtl/string.h"
31#include "rtl/textenc.h"
32#include "sal/saldllapi.h"
33#include "sal/types.h"
34
35#ifdef __cplusplus
36 extern "C" {
37#endif
38
39/* ======================================================================= */
40
53 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_getLength(
54 const sal_Unicode * str ) SAL_THROW_EXTERN_C();
55
74 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_compare(
75 const sal_Unicode * first, const sal_Unicode * second ) SAL_THROW_EXTERN_C();
76
102 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_compare_WithLength(
103 const sal_Unicode * first, sal_Int32 firstLen, const sal_Unicode * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C();
104
134 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_shortenedCompare_WithLength(
135 const sal_Unicode * first, sal_Int32 firstLen, const sal_Unicode * second, sal_Int32 secondLen, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C();
136
162 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_reverseCompare_WithLength(
163 const sal_Unicode * first, sal_Int32 firstLen, const sal_Unicode * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C();
164
186 SAL_DLLPUBLIC sal_Bool SAL_CALL rtl_ustr_asciil_reverseEquals_WithLength(
187 const sal_Unicode * first, const char * second, sal_Int32 len ) SAL_THROW_EXTERN_C();
188
208 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_compareIgnoreAsciiCase(
209 const sal_Unicode * first, const sal_Unicode * second ) SAL_THROW_EXTERN_C();
210
238 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_compareIgnoreAsciiCase_WithLength(
239 const sal_Unicode * first, sal_Int32 firstLen, const sal_Unicode * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C();
240
273 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_shortenedCompareIgnoreAsciiCase_WithLength(
274 const sal_Unicode * first, sal_Int32 firstLen, const sal_Unicode * second, sal_Int32 secondLen, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C();
275
299 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compare(
300 const sal_Unicode * first, const char * second ) SAL_THROW_EXTERN_C();
301
328 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compare_WithLength(
329 const sal_Unicode * first, sal_Int32 firstLen, const char * second ) SAL_THROW_EXTERN_C();
330
361 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_shortenedCompare_WithLength(
362 const sal_Unicode * first, sal_Int32 firstLen, const char * second, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C();
363
393 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_asciil_reverseCompare_WithLength(
394 const sal_Unicode * first, sal_Int32 firstLen, const char * second, sal_Int32 secondLen ) SAL_THROW_EXTERN_C();
395
420 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase(
421 const sal_Unicode * first, const char * second ) SAL_THROW_EXTERN_C();
422
451 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength(
452 const sal_Unicode * first, sal_Int32 firstLen, const char * second ) SAL_THROW_EXTERN_C();
453
485 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_compareIgnoreAsciiCase_WithLengths(
486 sal_Unicode const * first, sal_Int32 firstLen,
487 char const * second, sal_Int32 secondLen) SAL_THROW_EXTERN_C();
488
522 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength(
523 const sal_Unicode * first, sal_Int32 firstLen, const char * second, sal_Int32 shortenedLen ) SAL_THROW_EXTERN_C();
524
537 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_hashCode(
538 const sal_Unicode * str ) SAL_THROW_EXTERN_C();
539
555 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_hashCode_WithLength(
556 const sal_Unicode * str, sal_Int32 len ) SAL_THROW_EXTERN_C();
557
572 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_indexOfChar(
573 const sal_Unicode * str, sal_Unicode ch ) SAL_THROW_EXTERN_C();
574
591 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_indexOfChar_WithLength(
592 const sal_Unicode * str, sal_Int32 len, sal_Unicode ch ) SAL_THROW_EXTERN_C();
593
609 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_lastIndexOfChar(
610 const sal_Unicode * str, sal_Unicode ch ) SAL_THROW_EXTERN_C();
611
629 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_lastIndexOfChar_WithLength(
630 const sal_Unicode * str, sal_Int32 len, sal_Unicode ch ) SAL_THROW_EXTERN_C();
631
647 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_indexOfStr(
648 const sal_Unicode * str, const sal_Unicode * subStr ) SAL_THROW_EXTERN_C();
649
672 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_indexOfStr_WithLength(
673 const sal_Unicode * str, sal_Int32 len, const sal_Unicode * subStr, sal_Int32 subLen ) SAL_THROW_EXTERN_C();
674
699 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_indexOfAscii_WithLength(
700 sal_Unicode const * str, sal_Int32 len,
701 char const * subStr, sal_Int32 subLen) SAL_THROW_EXTERN_C();
702
718 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_lastIndexOfStr(
719 const sal_Unicode * str, const sal_Unicode * subStr ) SAL_THROW_EXTERN_C();
720
743 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_lastIndexOfStr_WithLength(
744 const sal_Unicode * str, sal_Int32 len, const sal_Unicode * subStr, sal_Int32 subLen ) SAL_THROW_EXTERN_C();
745
770 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_lastIndexOfAscii_WithLength(
771 sal_Unicode const * str, sal_Int32 len,
772 char const * subStr, sal_Int32 subLen) SAL_THROW_EXTERN_C();
773
788 SAL_DLLPUBLIC void SAL_CALL rtl_ustr_replaceChar(
789 sal_Unicode * str, sal_Unicode oldChar, sal_Unicode newChar ) SAL_THROW_EXTERN_C();
790
808 SAL_DLLPUBLIC void SAL_CALL rtl_ustr_replaceChar_WithLength(
809 sal_Unicode * str, sal_Int32 len, sal_Unicode oldChar, sal_Unicode newChar ) SAL_THROW_EXTERN_C();
810
820 SAL_DLLPUBLIC void SAL_CALL rtl_ustr_toAsciiLowerCase(
821 sal_Unicode * str ) SAL_THROW_EXTERN_C();
822
835 SAL_DLLPUBLIC void SAL_CALL rtl_ustr_toAsciiLowerCase_WithLength(
836 sal_Unicode * str, sal_Int32 len ) SAL_THROW_EXTERN_C();
837
847 SAL_DLLPUBLIC void SAL_CALL rtl_ustr_toAsciiUpperCase(
848 sal_Unicode * str ) SAL_THROW_EXTERN_C();
849
862 SAL_DLLPUBLIC void SAL_CALL rtl_ustr_toAsciiUpperCase_WithLength(
863 sal_Unicode * str, sal_Int32 len ) SAL_THROW_EXTERN_C();
864
877 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_trim(
878 sal_Unicode * str ) SAL_THROW_EXTERN_C();
879
896 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_trim_WithLength(
897 sal_Unicode * str, sal_Int32 len ) SAL_THROW_EXTERN_C();
898
917 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfBoolean(
918 sal_Unicode * str, sal_Bool b ) SAL_THROW_EXTERN_C();
919#define RTL_USTR_MAX_VALUEOFBOOLEAN RTL_STR_MAX_VALUEOFBOOLEAN
920
934 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfChar(
935 sal_Unicode * str, sal_Unicode ch ) SAL_THROW_EXTERN_C();
936#define RTL_USTR_MAX_VALUEOFCHAR RTL_STR_MAX_VALUEOFCHAR
937
957 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfInt32(
958 sal_Unicode * str, sal_Int32 i, sal_Int16 radix ) SAL_THROW_EXTERN_C();
959#define RTL_USTR_MIN_RADIX RTL_STR_MIN_RADIX
960#define RTL_USTR_MAX_RADIX RTL_STR_MAX_RADIX
961#define RTL_USTR_MAX_VALUEOFINT32 RTL_STR_MAX_VALUEOFINT32
962
982 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfInt64(
983 sal_Unicode * str, sal_Int64 l, sal_Int16 radix ) SAL_THROW_EXTERN_C();
984#define RTL_USTR_MAX_VALUEOFINT64 RTL_STR_MAX_VALUEOFINT64
985
1005 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfUInt64(
1006 sal_Unicode * str, sal_uInt64 l, sal_Int16 radix ) SAL_THROW_EXTERN_C();
1007#define RTL_USTR_MAX_VALUEOFUINT64 RTL_STR_MAX_VALUEOFUINT64
1008
1024 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfFloat(
1025 sal_Unicode * str, float f ) SAL_THROW_EXTERN_C();
1026#define RTL_USTR_MAX_VALUEOFFLOAT RTL_STR_MAX_VALUEOFFLOAT
1027
1043 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_valueOfDouble(
1044 sal_Unicode * str, double d ) SAL_THROW_EXTERN_C();
1045#define RTL_USTR_MAX_VALUEOFDOUBLE RTL_STR_MAX_VALUEOFDOUBLE
1046
1058 SAL_DLLPUBLIC sal_Bool SAL_CALL rtl_ustr_toBoolean(
1059 const sal_Unicode * str ) SAL_THROW_EXTERN_C();
1060
1077 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_ustr_toInt32(
1078 const sal_Unicode * str, sal_Int16 radix ) SAL_THROW_EXTERN_C();
1079
1098 SAL_DLLPUBLIC sal_uInt32 SAL_CALL rtl_ustr_toUInt32(
1099 const sal_Unicode * str, sal_Int16 radix ) SAL_THROW_EXTERN_C();
1100
1117 SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_ustr_toInt64(
1118 const sal_Unicode * str, sal_Int16 radix ) SAL_THROW_EXTERN_C();
1119
1141 SAL_DLLPUBLIC sal_Int64 SAL_CALL rtl_ustr_toInt64_WithLength(
1142 const sal_Unicode * str, sal_Int16 radix, sal_Int32 nStrLength ) SAL_THROW_EXTERN_C();
1143
1162 SAL_DLLPUBLIC sal_uInt64 SAL_CALL rtl_ustr_toUInt64(
1163 const sal_Unicode * str, sal_Int16 radix ) SAL_THROW_EXTERN_C();
1164
1177 SAL_DLLPUBLIC float SAL_CALL rtl_ustr_toFloat(
1178 const sal_Unicode * str ) SAL_THROW_EXTERN_C();
1179
1192 SAL_DLLPUBLIC double SAL_CALL rtl_ustr_toDouble(
1193 const sal_Unicode * str ) SAL_THROW_EXTERN_C();
1194
1195/* ======================================================================= */
1196
1200 typedef struct SAL_DLLPUBLIC_RTTI _rtl_uString
1201{
1202 oslInterlockedCount refCount; /* opaque */
1203 sal_Int32 length;
1204 sal_Unicode buffer[1];
1205} rtl_uString;
1208/* ----------------------------------------------------------------------- */
1209
1215 SAL_DLLPUBLIC void SAL_CALL rtl_uString_acquire(
1216 rtl_uString * str ) SAL_THROW_EXTERN_C() SAL_HOT;
1217
1225 SAL_DLLPUBLIC void SAL_CALL rtl_uString_release(
1226 rtl_uString * str ) SAL_THROW_EXTERN_C() SAL_HOT;
1227
1234 SAL_DLLPUBLIC void SAL_CALL rtl_uString_new(
1235 rtl_uString ** newStr ) SAL_THROW_EXTERN_C();
1236
1259 SAL_DLLPUBLIC rtl_uString * SAL_CALL rtl_uString_alloc(sal_Int32 nLen) SAL_THROW_EXTERN_C();
1260
1274 SAL_DLLPUBLIC void SAL_CALL rtl_uString_new_WithLength(
1275 rtl_uString ** newStr, sal_Int32 nLen ) SAL_THROW_EXTERN_C();
1276
1290 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromString(
1291 rtl_uString ** newStr, const rtl_uString * value ) SAL_THROW_EXTERN_C();
1292
1306 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromStr(
1307 rtl_uString ** newStr, const sal_Unicode * value ) SAL_THROW_EXTERN_C();
1308
1326 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromStr_WithLength(
1327 rtl_uString ** newStr, const sal_Unicode * value, sal_Int32 len ) SAL_THROW_EXTERN_C();
1328
1343 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromSubString(
1344 rtl_uString ** newStr, const rtl_uString * from,
1345 sal_Int32 beginIndex, sal_Int32 count ) SAL_THROW_EXTERN_C();
1346
1364 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromAscii(
1365 rtl_uString ** newStr, const char * value ) SAL_THROW_EXTERN_C();
1366
1371 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromLiteral(
1372 rtl_uString ** newStr, const char * value, sal_Int32 len,
1373 sal_Int32 allocExtra ) SAL_THROW_EXTERN_C();
1374
1394 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newFromCodePoints(
1395 rtl_uString ** newString, sal_uInt32 const * codePoints,
1396 sal_Int32 codePointCount) SAL_THROW_EXTERN_C();
1397
1410 SAL_DLLPUBLIC void SAL_CALL rtl_uString_assign(
1411 rtl_uString ** str, rtl_uString * rightValue ) SAL_THROW_EXTERN_C();
1412
1423 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_uString_getLength(
1424 const rtl_uString * str ) SAL_THROW_EXTERN_C();
1425
1434 SAL_DLLPUBLIC sal_Unicode * SAL_CALL rtl_uString_getStr(
1435 rtl_uString * str ) SAL_THROW_EXTERN_C();
1436
1454 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newConcat(
1455 rtl_uString ** newStr, rtl_uString * left, rtl_uString * right ) SAL_THROW_EXTERN_C();
1456
1477 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newConcatAsciiL(
1478 rtl_uString ** newString, rtl_uString * left, char const * right,
1479 sal_Int32 rightLength);
1480
1499 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newConcatUtf16L(
1500 rtl_uString ** newString, rtl_uString * left, sal_Unicode const * right,
1501 sal_Int32 rightLength);
1502
1532 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceStrAt(
1533 rtl_uString ** newStr, rtl_uString * str, sal_Int32 idx, sal_Int32 count, rtl_uString * subStr ) SAL_THROW_EXTERN_C();
1534
1535#ifdef LIBO_INTERNAL_ONLY
1536 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceStrAtUtf16L(
1537 rtl_uString ** newStr, rtl_uString * str, sal_Int32 idx, sal_Int32 count, sal_Unicode const * subStr, sal_Int32 substrLen ) SAL_THROW_EXTERN_C();
1538#endif
1539
1564 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplace(
1565 rtl_uString ** newStr, rtl_uString * str, sal_Unicode oldChar, sal_Unicode newChar ) SAL_THROW_EXTERN_C();
1566
1588 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirst(
1589 rtl_uString ** newStr, rtl_uString * str, rtl_uString const * from,
1590 rtl_uString const * to, sal_Int32 * index) SAL_THROW_EXTERN_C();
1591
1616 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirstAsciiL(
1617 rtl_uString ** newStr, rtl_uString * str, char const * from,
1618 sal_Int32 fromLength, rtl_uString const * to, sal_Int32 * index)
1619 SAL_THROW_EXTERN_C();
1620
1645 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirstToAsciiL(
1646 rtl_uString ** newStr, rtl_uString * str, rtl_uString const * from,
1647 char const * to, sal_Int32 toLength, sal_Int32 * index)
1648 SAL_THROW_EXTERN_C();
1649
1677 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirstAsciiLAsciiL(
1678 rtl_uString ** newStr, rtl_uString * str, char const * from,
1679 sal_Int32 fromLength, char const * to, sal_Int32 toLength,
1680 sal_Int32 * index) SAL_THROW_EXTERN_C();
1681
1713 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirstAsciiLUtf16L(
1714 rtl_uString ** newStr, rtl_uString * str, char const * from,
1715 sal_Int32 fromLength, sal_Unicode const * to, sal_Int32 toLength,
1716 sal_Int32 * index) SAL_THROW_EXTERN_C();
1717
1749 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirstUtf16LAsciiL(
1750 rtl_uString ** newStr, rtl_uString * str, sal_Unicode const * from,
1751 sal_Int32 fromLength, char const * to, sal_Int32 toLength,
1752 sal_Int32 * index) SAL_THROW_EXTERN_C();
1753
1785 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceFirstUtf16LUtf16L(
1786 rtl_uString ** newStr, rtl_uString * str, sal_Unicode const * from,
1787 sal_Int32 fromLength, sal_Unicode const * to, sal_Int32 toLength,
1788 sal_Int32 * index) SAL_THROW_EXTERN_C();
1789
1807 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAll(
1808 rtl_uString ** newStr, rtl_uString * str, rtl_uString const * from,
1809 rtl_uString const * to) SAL_THROW_EXTERN_C();
1810
1830 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllFromIndex(
1831 rtl_uString ** newStr, rtl_uString * str, rtl_uString const * from,
1832 rtl_uString const * to, sal_Int32 fromIndex) SAL_THROW_EXTERN_C();
1833
1854 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllAsciiL(
1855 rtl_uString ** newStr, rtl_uString * str, char const * from,
1856 sal_Int32 fromLength, rtl_uString const * to) SAL_THROW_EXTERN_C();
1857
1878 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllToAsciiL(
1879 rtl_uString ** newStr, rtl_uString * str, rtl_uString const * from,
1880 char const * to, sal_Int32 toLength) SAL_THROW_EXTERN_C();
1881
1905 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllAsciiLAsciiL(
1906 rtl_uString ** newStr, rtl_uString * str, char const * from,
1907 sal_Int32 fromLength, char const * to, sal_Int32 toLength)
1908 SAL_THROW_EXTERN_C();
1909
1936 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllAsciiLUtf16L(
1937 rtl_uString ** newStr, rtl_uString * str, char const * from,
1938 sal_Int32 fromLength, sal_Unicode const * to, sal_Int32 toLength)
1939 SAL_THROW_EXTERN_C();
1940
1967 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllUtf16LAsciiL(
1968 rtl_uString ** newStr, rtl_uString * str, sal_Unicode const * from,
1969 sal_Int32 fromLength, char const * to, sal_Int32 toLength)
1970 SAL_THROW_EXTERN_C();
1971
1998 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllUtf16LUtf16L(
1999 rtl_uString ** newStr, rtl_uString * str, sal_Unicode const * from,
2000 sal_Int32 fromLength, sal_Unicode const * to, sal_Int32 toLength)
2001 SAL_THROW_EXTERN_C();
2002
2003#if defined LIBO_INTERNAL_ONLY
2032 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newReplaceAllFromIndexUtf16LUtf16L(
2033 rtl_uString ** newStr, rtl_uString * str, sal_Unicode const * from,
2034 sal_Int32 fromLength, sal_Unicode const * to, sal_Int32 toLength, sal_Int32 fromIndex)
2035 SAL_THROW_EXTERN_C();
2036#endif
2037
2057 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newToAsciiLowerCase(
2058 rtl_uString ** newStr, rtl_uString * str ) SAL_THROW_EXTERN_C();
2059
2079 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newToAsciiUpperCase(
2080 rtl_uString ** newStr, rtl_uString * str ) SAL_THROW_EXTERN_C();
2081
2103 SAL_DLLPUBLIC void SAL_CALL rtl_uString_newTrim(
2104 rtl_uString ** newStr, rtl_uString * str ) SAL_THROW_EXTERN_C();
2105
2150 SAL_DLLPUBLIC sal_Int32 SAL_CALL rtl_uString_getToken(
2151 rtl_uString ** newStr , rtl_uString * str, sal_Int32 token, sal_Unicode cTok, sal_Int32 idx ) SAL_THROW_EXTERN_C();
2152
2153/* ======================================================================= */
2154
2168// The &foo[0] trick is intentional, it makes sure the type is char* or const char*
2169// (plain cast to const char* would not work with non-const char foo[]="a", which seems to be allowed).
2170// This is to avoid mistaken use with functions that accept string literals
2171// (i.e. const char (&)[N]) where usage of this macro otherwise could match
2172// the argument and a following int argument with a default value (e.g. OUString::match()).
2173#define RTL_CONSTASCII_USTRINGPARAM( constAsciiStr ) (&(constAsciiStr)[0]), \
2174 ((sal_Int32)(SAL_N_ELEMENTS(constAsciiStr)-1)), RTL_TEXTENCODING_ASCII_US
2175
2176/* ======================================================================= */
2177
2178/* predefined constants for String-Conversion */
2179#define OSTRING_TO_OUSTRING_CVTFLAGS (RTL_TEXTTOUNICODE_FLAGS_UNDEFINED_MAPTOPRIVATE |\
2180 RTL_TEXTTOUNICODE_FLAGS_MBUNDEFINED_DEFAULT |\
2181 RTL_TEXTTOUNICODE_FLAGS_INVALID_DEFAULT)
2182
2183/* ----------------------------------------------------------------------- */
2184
2217 SAL_DLLPUBLIC void SAL_CALL rtl_string2UString(
2218 rtl_uString ** newStr, const char * str, sal_Int32 len, rtl_TextEncoding encoding, sal_uInt32 convertFlags ) SAL_THROW_EXTERN_C();
2219
2220/* ======================================================================= */
2221/* Interning methods */
2222
2242 SAL_DLLPUBLIC void SAL_CALL rtl_uString_intern(
2243 rtl_uString ** newStr, rtl_uString * str) SAL_THROW_EXTERN_C();
2244
2280 SAL_DLLPUBLIC void SAL_CALL rtl_uString_internConvert(
2281 rtl_uString ** newStr,
2282 const char * str,
2283 sal_Int32 len,
2284 rtl_TextEncoding encoding,
2285 sal_uInt32 convertFlags,
2286 sal_uInt32 *pInfo) SAL_THROW_EXTERN_C();
2287
2340 SAL_DLLPUBLIC sal_uInt32 SAL_CALL rtl_uString_iterateCodePoints(
2341 rtl_uString const * string, sal_Int32 * indexUtf16,
2342 sal_Int32 incrementCodePoints);
2343
2377 SAL_DLLPUBLIC sal_Bool SAL_CALL rtl_convertStringToUString(
2378 rtl_uString ** target, char const * source, sal_Int32 length,
2379 rtl_TextEncoding encoding, sal_uInt32 flags) SAL_THROW_EXTERN_C();
2380
2397 SAL_DLLPUBLIC void SAL_CALL rtl_uString_ensureCapacity( rtl_uString ** str, sal_Int32 size ) SAL_THROW_EXTERN_C();
2398
2399#ifdef __cplusplus
2400}
2401#endif
2402
2403#endif // INCLUDED_RTL_USTRING_H
2404
2405/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
saldllapi.h
SAL_DLLPUBLIC
#define SAL_DLLPUBLIC
Definition saldllapi.h:34
types.h
sal_Bool
unsigned char sal_Bool
Definition types.h:38
SAL_THROW_EXTERN_C
#define SAL_THROW_EXTERN_C()
Nothrow specification for C functions.
Definition types.h:334
sal_Unicode
sal_uInt16 sal_Unicode
Definition types.h:123
config.h
rtl_ustr_ascii_compareIgnoreAsciiCase_WithLengths
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_compareIgnoreAsciiCase_WithLengths(sal_Unicode const *first, sal_Int32 firstLen, char const *second, sal_Int32 secondLen) SAL_THROW_EXTERN_C()
Compare two strings, ignoring the case of ASCII characters.
rtl_uString_assign
SAL_DLLPUBLIC void rtl_uString_assign(rtl_uString **str, rtl_uString *rightValue) SAL_THROW_EXTERN_C()
Assign a new value to a string.
rtl_uString_newReplaceFirstUtf16LUtf16L
SAL_DLLPUBLIC void rtl_uString_newReplaceFirstUtf16LUtf16L(rtl_uString **newStr, rtl_uString *str, sal_Unicode const *from, sal_Int32 fromLength, sal_Unicode const *to, sal_Int32 toLength, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_ustr_toFloat
SAL_DLLPUBLIC float rtl_ustr_toFloat(const sal_Unicode *str) SAL_THROW_EXTERN_C()
Interpret a string as a float.
rtl_ustr_ascii_shortenedCompare_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_shortenedCompare_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const char *second, sal_Int32 shortenedLen) SAL_THROW_EXTERN_C()
Compare two strings with a maximum count of characters.
rtl_uString_new
SAL_DLLPUBLIC void rtl_uString_new(rtl_uString **newStr) SAL_THROW_EXTERN_C()
Allocate a new string containing no characters.
rtl_ustr_compare_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_compare_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const sal_Unicode *second, sal_Int32 secondLen) SAL_THROW_EXTERN_C()
Compare two strings.
rtl_uString_newConcatUtf16L
SAL_DLLPUBLIC void rtl_uString_newConcatUtf16L(rtl_uString **newString, rtl_uString *left, sal_Unicode const *right, sal_Int32 rightLength)
Create a new string that is the concatenation of two other strings.
rtl_uString_newReplaceAllAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceAllAsciiL(rtl_uString **newStr, rtl_uString *str, char const *from, sal_Int32 fromLength, rtl_uString const *to) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_uString_newReplaceAllFromIndex
SAL_DLLPUBLIC void rtl_uString_newReplaceAllFromIndex(rtl_uString **newStr, rtl_uString *str, rtl_uString const *from, rtl_uString const *to, sal_Int32 fromIndex) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_uString_newFromString
SAL_DLLPUBLIC void rtl_uString_newFromString(rtl_uString **newStr, const rtl_uString *value) SAL_THROW_EXTERN_C()
Allocate a new string that contains a copy of another string.
rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const char *second, sal_Int32 shortenedLen) SAL_THROW_EXTERN_C()
Compare two strings with a maximum count of characters, ignoring the case of ASCII characters.
rtl_uString_getToken
SAL_DLLPUBLIC sal_Int32 rtl_uString_getToken(rtl_uString **newStr, rtl_uString *str, sal_Int32 token, sal_Unicode cTok, sal_Int32 idx) SAL_THROW_EXTERN_C()
Create a new string by extracting a single token from another string.
rtl_uString_newFromStr_WithLength
SAL_DLLPUBLIC void rtl_uString_newFromStr_WithLength(rtl_uString **newStr, const sal_Unicode *value, sal_Int32 len) SAL_THROW_EXTERN_C()
Allocate a new string that contains a copy of a character array.
rtl_ustr_compareIgnoreAsciiCase
SAL_DLLPUBLIC sal_Int32 rtl_ustr_compareIgnoreAsciiCase(const sal_Unicode *first, const sal_Unicode *second) SAL_THROW_EXTERN_C()
Compare two strings, ignoring the case of ASCII characters.
rtl_ustr_asciil_reverseEquals_WithLength
SAL_DLLPUBLIC sal_Bool rtl_ustr_asciil_reverseEquals_WithLength(const sal_Unicode *first, const char *second, sal_Int32 len) SAL_THROW_EXTERN_C()
Compare two strings from back to front for equality.
rtl_uString_newFromLiteral
SAL_DLLPUBLIC void rtl_uString_newFromLiteral(rtl_uString **newStr, const char *value, sal_Int32 len, sal_Int32 allocExtra) SAL_THROW_EXTERN_C()
rtl_ustr_toInt64_WithLength
SAL_DLLPUBLIC sal_Int64 rtl_ustr_toInt64_WithLength(const sal_Unicode *str, sal_Int16 radix, sal_Int32 nStrLength) SAL_THROW_EXTERN_C()
Interpret a string as a long integer.
rtl_uString_newReplaceAllAsciiLUtf16L
SAL_DLLPUBLIC void rtl_uString_newReplaceAllAsciiLUtf16L(rtl_uString **newStr, rtl_uString *str, char const *from, sal_Int32 fromLength, sal_Unicode const *to, sal_Int32 toLength) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_ustr_trim_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_trim_WithLength(sal_Unicode *str, sal_Int32 len) SAL_THROW_EXTERN_C()
Remove white space from both ends of the string.
rtl_ustr_valueOfBoolean
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfBoolean(sal_Unicode *str, sal_Bool b) SAL_THROW_EXTERN_C()
Create the string representation of a boolean.
rtl_ustr_toDouble
SAL_DLLPUBLIC double rtl_ustr_toDouble(const sal_Unicode *str) SAL_THROW_EXTERN_C()
Interpret a string as a double.
rtl_ustr_hashCode
SAL_DLLPUBLIC sal_Int32 rtl_ustr_hashCode(const sal_Unicode *str) SAL_THROW_EXTERN_C()
Return a hash code for a string.
rtl_ustr_replaceChar_WithLength
SAL_DLLPUBLIC void rtl_ustr_replaceChar_WithLength(sal_Unicode *str, sal_Int32 len, sal_Unicode oldChar, sal_Unicode newChar) SAL_THROW_EXTERN_C()
Replace all occurrences of a single character within a string.
rtl_ustr_valueOfFloat
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfFloat(sal_Unicode *str, float f) SAL_THROW_EXTERN_C()
Create the string representation of a float.
rtl_ustr_ascii_compare
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_compare(const sal_Unicode *first, const char *second) SAL_THROW_EXTERN_C()
Compare two strings.
rtl_uString_newReplaceFirstUtf16LAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceFirstUtf16LAsciiL(rtl_uString **newStr, rtl_uString *str, sal_Unicode const *from, sal_Int32 fromLength, char const *to, sal_Int32 toLength, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_ustr_toAsciiLowerCase
SAL_DLLPUBLIC void rtl_ustr_toAsciiLowerCase(sal_Unicode *str) SAL_THROW_EXTERN_C()
Convert all ASCII uppercase letters to lowercase within a string.
rtl_uString_newReplaceFirstToAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceFirstToAsciiL(rtl_uString **newStr, rtl_uString *str, rtl_uString const *from, char const *to, sal_Int32 toLength, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_ustr_valueOfDouble
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfDouble(sal_Unicode *str, double d) SAL_THROW_EXTERN_C()
Create the string representation of a double.
rtl_uString_newReplaceAll
SAL_DLLPUBLIC void rtl_uString_newReplaceAll(rtl_uString **newStr, rtl_uString *str, rtl_uString const *from, rtl_uString const *to) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_ustr_lastIndexOfStr
SAL_DLLPUBLIC sal_Int32 rtl_ustr_lastIndexOfStr(const sal_Unicode *str, const sal_Unicode *subStr) SAL_THROW_EXTERN_C()
Search for the last occurrence of a substring within a string.
rtl_ustr_replaceChar
SAL_DLLPUBLIC void rtl_ustr_replaceChar(sal_Unicode *str, sal_Unicode oldChar, sal_Unicode newChar) SAL_THROW_EXTERN_C()
Replace all occurrences of a single character within a string.
rtl_uString_newConcat
SAL_DLLPUBLIC void rtl_uString_newConcat(rtl_uString **newStr, rtl_uString *left, rtl_uString *right) SAL_THROW_EXTERN_C()
Create a new string that is the concatenation of two other strings.
rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_compareIgnoreAsciiCase_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const char *second) SAL_THROW_EXTERN_C()
Compare two strings, ignoring the case of ASCII characters.
rtl_ustr_lastIndexOfChar
SAL_DLLPUBLIC sal_Int32 rtl_ustr_lastIndexOfChar(const sal_Unicode *str, sal_Unicode ch) SAL_THROW_EXTERN_C()
Search for the last occurrence of a character within a string.
rtl_ustr_valueOfChar
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfChar(sal_Unicode *str, sal_Unicode ch) SAL_THROW_EXTERN_C()
Create the string representation of a character.
rtl_ustr_indexOfStr
SAL_DLLPUBLIC sal_Int32 rtl_ustr_indexOfStr(const sal_Unicode *str, const sal_Unicode *subStr) SAL_THROW_EXTERN_C()
Search for the first occurrence of a substring within a string.
rtl_ustr_ascii_compareIgnoreAsciiCase
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_compareIgnoreAsciiCase(const sal_Unicode *first, const char *second) SAL_THROW_EXTERN_C()
Compare two strings, ignoring the case of ASCII characters.
rtl_ustr_indexOfStr_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_indexOfStr_WithLength(const sal_Unicode *str, sal_Int32 len, const sal_Unicode *subStr, sal_Int32 subLen) SAL_THROW_EXTERN_C()
Search for the first occurrence of a substring within a string.
rtl_uString_internConvert
SAL_DLLPUBLIC void rtl_uString_internConvert(rtl_uString **newStr, const char *str, sal_Int32 len, rtl_TextEncoding encoding, sal_uInt32 convertFlags, sal_uInt32 *pInfo) SAL_THROW_EXTERN_C()
Return a canonical representation for a string.
rtl_uString_acquire
SAL_DLLPUBLIC void rtl_uString_acquire(rtl_uString *str) SAL_THROW_EXTERN_C() SAL_HOT
Increment the reference count of a string.
rtl_ustr_trim
SAL_DLLPUBLIC sal_Int32 rtl_ustr_trim(sal_Unicode *str) SAL_THROW_EXTERN_C()
Remove white space from both ends of a string.
rtl_ustr_toInt64
SAL_DLLPUBLIC sal_Int64 rtl_ustr_toInt64(const sal_Unicode *str, sal_Int16 radix) SAL_THROW_EXTERN_C()
Interpret a string as a long integer.
rtl_ustr_toAsciiLowerCase_WithLength
SAL_DLLPUBLIC void rtl_ustr_toAsciiLowerCase_WithLength(sal_Unicode *str, sal_Int32 len) SAL_THROW_EXTERN_C()
Convert all ASCII uppercase letters to lowercase within a string.
rtl_uString_newReplaceStrAt
SAL_DLLPUBLIC void rtl_uString_newReplaceStrAt(rtl_uString **newStr, rtl_uString *str, sal_Int32 idx, sal_Int32 count, rtl_uString *subStr) SAL_THROW_EXTERN_C()
Create a new string by replacing a substring of another string.
rtl_convertStringToUString
SAL_DLLPUBLIC sal_Bool rtl_convertStringToUString(rtl_uString **target, char const *source, sal_Int32 length, rtl_TextEncoding encoding, sal_uInt32 flags) SAL_THROW_EXTERN_C()
Converts a byte string to a Unicode string, signalling failure.
rtl_uString_newReplaceAllToAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceAllToAsciiL(rtl_uString **newStr, rtl_uString *str, rtl_uString const *from, char const *to, sal_Int32 toLength) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_uString_iterateCodePoints
SAL_DLLPUBLIC sal_uInt32 rtl_uString_iterateCodePoints(rtl_uString const *string, sal_Int32 *indexUtf16, sal_Int32 incrementCodePoints)
Iterate through a string based on code points instead of UTF-16 code units.
rtl_uString_newToAsciiLowerCase
SAL_DLLPUBLIC void rtl_uString_newToAsciiLowerCase(rtl_uString **newStr, rtl_uString *str) SAL_THROW_EXTERN_C()
Create a new string by converting all ASCII uppercase letters to lowercase within another string.
rtl_uString_ensureCapacity
SAL_DLLPUBLIC void rtl_uString_ensureCapacity(rtl_uString **str, sal_Int32 size) SAL_THROW_EXTERN_C()
Ensure a string has enough space for a given number of characters.
rtl_ustr_toAsciiUpperCase_WithLength
SAL_DLLPUBLIC void rtl_ustr_toAsciiUpperCase_WithLength(sal_Unicode *str, sal_Int32 len) SAL_THROW_EXTERN_C()
Convert all ASCII lowercase letters to uppercase within a string.
rtl_uString_release
SAL_DLLPUBLIC void rtl_uString_release(rtl_uString *str) SAL_THROW_EXTERN_C() SAL_HOT
Decrement the reference count of a string.
rtl_ustr_getLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_getLength(const sal_Unicode *str) SAL_THROW_EXTERN_C()
Return the length of a string.
rtl_uString_newFromAscii
SAL_DLLPUBLIC void rtl_uString_newFromAscii(rtl_uString **newStr, const char *value) SAL_THROW_EXTERN_C()
Allocate a new string that contains a copy of a character array.
rtl_ustr_compare
SAL_DLLPUBLIC sal_Int32 rtl_ustr_compare(const sal_Unicode *first, const sal_Unicode *second) SAL_THROW_EXTERN_C()
Compare two strings.
rtl_ustr_valueOfInt64
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfInt64(sal_Unicode *str, sal_Int64 l, sal_Int16 radix) SAL_THROW_EXTERN_C()
Create the string representation of a long integer.
rtl_ustr_lastIndexOfAscii_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_lastIndexOfAscii_WithLength(sal_Unicode const *str, sal_Int32 len, char const *subStr, sal_Int32 subLen) SAL_THROW_EXTERN_C()
Search for the last occurrence of an ASCII substring within a string.
rtl_uString_newReplaceFirstAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceFirstAsciiL(rtl_uString **newStr, rtl_uString *str, char const *from, sal_Int32 fromLength, rtl_uString const *to, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_ustr_indexOfAscii_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_indexOfAscii_WithLength(sal_Unicode const *str, sal_Int32 len, char const *subStr, sal_Int32 subLen) SAL_THROW_EXTERN_C()
Search for the first occurrence of an ASCII substring within a string.
rtl_uString_alloc
SAL_DLLPUBLIC rtl_uString * rtl_uString_alloc(sal_Int32 nLen) SAL_THROW_EXTERN_C()
Allocate a new string containing space for a given number of characters.
rtl_ustr_toUInt64
SAL_DLLPUBLIC sal_uInt64 rtl_ustr_toUInt64(const sal_Unicode *str, sal_Int16 radix) SAL_THROW_EXTERN_C()
Interpret a string as an unsigned long integer.
rtl_uString_newReplaceAllUtf16LAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceAllUtf16LAsciiL(rtl_uString **newStr, rtl_uString *str, sal_Unicode const *from, sal_Int32 fromLength, char const *to, sal_Int32 toLength) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_ustr_shortenedCompareIgnoreAsciiCase_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_shortenedCompareIgnoreAsciiCase_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const sal_Unicode *second, sal_Int32 secondLen, sal_Int32 shortenedLen) SAL_THROW_EXTERN_C()
Compare two strings with a maximum count of characters, ignoring the case of ASCII characters.
rtl_uString_new_WithLength
SAL_DLLPUBLIC void rtl_uString_new_WithLength(rtl_uString **newStr, sal_Int32 nLen) SAL_THROW_EXTERN_C()
Allocate a new string containing space for a given number of characters.
rtl_uString_newTrim
SAL_DLLPUBLIC void rtl_uString_newTrim(rtl_uString **newStr, rtl_uString *str) SAL_THROW_EXTERN_C()
Create a new string by removing white space from both ends of another string.
rtl_uString_newReplaceAllUtf16LUtf16L
SAL_DLLPUBLIC void rtl_uString_newReplaceAllUtf16LUtf16L(rtl_uString **newStr, rtl_uString *str, sal_Unicode const *from, sal_Int32 fromLength, sal_Unicode const *to, sal_Int32 toLength) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_ustr_lastIndexOfChar_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_lastIndexOfChar_WithLength(const sal_Unicode *str, sal_Int32 len, sal_Unicode ch) SAL_THROW_EXTERN_C()
Search for the last occurrence of a character within a string.
rtl_uString_newReplaceFirstAsciiLAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceFirstAsciiLAsciiL(rtl_uString **newStr, rtl_uString *str, char const *from, sal_Int32 fromLength, char const *to, sal_Int32 toLength, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_ustr_toUInt32
SAL_DLLPUBLIC sal_uInt32 rtl_ustr_toUInt32(const sal_Unicode *str, sal_Int16 radix) SAL_THROW_EXTERN_C()
Interpret a string as an unsigned integer.
rtl_uString_intern
SAL_DLLPUBLIC void rtl_uString_intern(rtl_uString **newStr, rtl_uString *str) SAL_THROW_EXTERN_C()
Return a canonical representation for a string.
rtl_string2UString
SAL_DLLPUBLIC void rtl_string2UString(rtl_uString **newStr, const char *str, sal_Int32 len, rtl_TextEncoding encoding, sal_uInt32 convertFlags) SAL_THROW_EXTERN_C()
Create a new Unicode string by converting a byte string, using a specific text encoding.
rtl_uString_newFromStr
SAL_DLLPUBLIC void rtl_uString_newFromStr(rtl_uString **newStr, const sal_Unicode *value) SAL_THROW_EXTERN_C()
Allocate a new string that contains a copy of a character array.
rtl_ustr_asciil_reverseCompare_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_asciil_reverseCompare_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const char *second, sal_Int32 secondLen) SAL_THROW_EXTERN_C()
Compare two strings from back to front.
rtl_ustr_ascii_compare_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_ascii_compare_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const char *second) SAL_THROW_EXTERN_C()
Compare two strings.
rtl_uString_getLength
SAL_DLLPUBLIC sal_Int32 rtl_uString_getLength(const rtl_uString *str) SAL_THROW_EXTERN_C()
Return the length of a string.
rtl_ustr_indexOfChar
SAL_DLLPUBLIC sal_Int32 rtl_ustr_indexOfChar(const sal_Unicode *str, sal_Unicode ch) SAL_THROW_EXTERN_C()
Search for the first occurrence of a character within a string.
rtl_ustr_toInt32
SAL_DLLPUBLIC sal_Int32 rtl_ustr_toInt32(const sal_Unicode *str, sal_Int16 radix) SAL_THROW_EXTERN_C()
Interpret a string as an integer.
rtl_uString_newReplaceAllAsciiLAsciiL
SAL_DLLPUBLIC void rtl_uString_newReplaceAllAsciiLAsciiL(rtl_uString **newStr, rtl_uString *str, char const *from, sal_Int32 fromLength, char const *to, sal_Int32 toLength) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a given substring with another substring.
rtl_ustr_valueOfUInt64
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfUInt64(sal_Unicode *str, sal_uInt64 l, sal_Int16 radix) SAL_THROW_EXTERN_C()
Create the string representation of an unsigned long integer.
rtl_uString_newFromCodePoints
SAL_DLLPUBLIC void rtl_uString_newFromCodePoints(rtl_uString **newString, sal_uInt32 const *codePoints, sal_Int32 codePointCount) SAL_THROW_EXTERN_C()
Allocate a new string from an array of Unicode code points.
rtl_ustr_compareIgnoreAsciiCase_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_compareIgnoreAsciiCase_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const sal_Unicode *second, sal_Int32 secondLen) SAL_THROW_EXTERN_C()
Compare two strings, ignoring the case of ASCII characters.
rtl_ustr_reverseCompare_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_reverseCompare_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const sal_Unicode *second, sal_Int32 secondLen) SAL_THROW_EXTERN_C()
Compare two strings from back to front.
rtl_ustr_shortenedCompare_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_shortenedCompare_WithLength(const sal_Unicode *first, sal_Int32 firstLen, const sal_Unicode *second, sal_Int32 secondLen, sal_Int32 shortenedLen) SAL_THROW_EXTERN_C()
Compare two strings with a maximum count of characters.
rtl_ustr_toAsciiUpperCase
SAL_DLLPUBLIC void rtl_ustr_toAsciiUpperCase(sal_Unicode *str) SAL_THROW_EXTERN_C()
Convert all ASCII lowercase letters to uppercase within a string.
rtl_ustr_valueOfInt32
SAL_DLLPUBLIC sal_Int32 rtl_ustr_valueOfInt32(sal_Unicode *str, sal_Int32 i, sal_Int16 radix) SAL_THROW_EXTERN_C()
Create the string representation of an integer.
rtl_ustr_toBoolean
SAL_DLLPUBLIC sal_Bool rtl_ustr_toBoolean(const sal_Unicode *str) SAL_THROW_EXTERN_C()
Interpret a string as a boolean.
rtl_uString_newReplace
SAL_DLLPUBLIC void rtl_uString_newReplace(rtl_uString **newStr, rtl_uString *str, sal_Unicode oldChar, sal_Unicode newChar) SAL_THROW_EXTERN_C()
Create a new string by replacing all occurrences of a single character within another string.
rtl_uString_getStr
SAL_DLLPUBLIC sal_Unicode * rtl_uString_getStr(rtl_uString *str) SAL_THROW_EXTERN_C()
Return a pointer to the underlying character array of a string.
rtl_ustr_hashCode_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_hashCode_WithLength(const sal_Unicode *str, sal_Int32 len) SAL_THROW_EXTERN_C()
Return a hash code for a string.
rtl_uString_newReplaceFirst
SAL_DLLPUBLIC void rtl_uString_newReplaceFirst(rtl_uString **newStr, rtl_uString *str, rtl_uString const *from, rtl_uString const *to, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_uString_newReplaceFirstAsciiLUtf16L
SAL_DLLPUBLIC void rtl_uString_newReplaceFirstAsciiLUtf16L(rtl_uString **newStr, rtl_uString *str, char const *from, sal_Int32 fromLength, sal_Unicode const *to, sal_Int32 toLength, sal_Int32 *index) SAL_THROW_EXTERN_C()
Create a new string by replacing the first occurrence of a given substring with another substring.
rtl_uString_newToAsciiUpperCase
SAL_DLLPUBLIC void rtl_uString_newToAsciiUpperCase(rtl_uString **newStr, rtl_uString *str) SAL_THROW_EXTERN_C()
Create a new string by converting all ASCII lowercase letters to uppercase within another string.
rtl_ustr_lastIndexOfStr_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_lastIndexOfStr_WithLength(const sal_Unicode *str, sal_Int32 len, const sal_Unicode *subStr, sal_Int32 subLen) SAL_THROW_EXTERN_C()
Search for the last occurrence of a substring within a string.
rtl_ustr_indexOfChar_WithLength
SAL_DLLPUBLIC sal_Int32 rtl_ustr_indexOfChar_WithLength(const sal_Unicode *str, sal_Int32 len, sal_Unicode ch) SAL_THROW_EXTERN_C()
Search for the first occurrence of a character within a string.
rtl_uString_newFromSubString
SAL_DLLPUBLIC void rtl_uString_newFromSubString(rtl_uString **newStr, const rtl_uString *from, sal_Int32 beginIndex, sal_Int32 count) SAL_THROW_EXTERN_C()
Allocate a new string that is a substring of this string.
rtl_uString_newConcatAsciiL
SAL_DLLPUBLIC void rtl_uString_newConcatAsciiL(rtl_uString **newString, rtl_uString *left, char const *right, sal_Int32 rightLength)
Create a new string that is the concatenation of two other strings.
string.h
textenc.h
rtl_TextEncoding
sal_uInt16 rtl_TextEncoding
The various supported text encodings.
Definition textenc.h:37
interlck.h
oslInterlockedCount
sal_Int32 oslInterlockedCount
Definition interlck.h:44