Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Search  

ustring.h

Go to the documentation of this file.
00001 /*
00002 **********************************************************************
00003 *   Copyright (C) 1998-2001, International Business Machines
00004 *   Corporation and others.  All Rights Reserved.
00005 **********************************************************************
00006 *
00007 * File ustring.h
00008 *
00009 * Modification History:
00010 *
00011 *   Date        Name        Description
00012 *   12/07/98    bertrand    Creation.
00013 ******************************************************************************
00014 */
00015 
00016 #ifndef USTRING_H
00017 #define USTRING_H
00018 #include "unicode/utypes.h"
00019 
00064 U_CAPI int32_t U_EXPORT2
00065 u_strlen(const UChar *s);
00066 
00080 U_CAPI int32_t U_EXPORT2
00081 u_countChar32(const UChar *s, int32_t length);
00082 
00093 U_CAPI UChar* U_EXPORT2
00094 u_strcat(UChar     *dst, 
00095     const UChar     *src);
00096 
00108 U_CAPI UChar* U_EXPORT2
00109 u_strncat(UChar     *dst, 
00110      const UChar     *src, 
00111      int32_t     n);
00112 
00122 U_CAPI UChar*  U_EXPORT2
00123 u_strchr(const UChar     *s, 
00124     UChar     c);
00125 
00135 U_CAPI UChar * U_EXPORT2
00136 u_strstr(const UChar *s, const UChar *substring);
00137 
00149 U_CAPI UChar * U_EXPORT2
00150 u_strchr32(const UChar *s, UChar32 c);
00151 
00161 U_CAPI UChar * U_EXPORT2
00162 u_strpbrk(const UChar *string, const UChar *matchSet);
00163 
00172 U_CAPI int32_t U_EXPORT2
00173 u_strcspn(const UChar *string, const UChar *matchSet);
00174 
00183 U_CAPI int32_t U_EXPORT2
00184 u_strspn(const UChar *string, const UChar *matchSet);
00185 
00206 U_CAPI UChar * U_EXPORT2
00207 u_strtok_r(UChar    *src, 
00208      const UChar    *delim,
00209            UChar   **saveState);
00210 
00221 U_CAPI int32_t  U_EXPORT2
00222 u_strcmp(const UChar     *s1, 
00223     const UChar     *s2);
00224 
00242 U_CAPI int32_t U_EXPORT2
00243 u_strcmpCodePointOrder(const UChar *s1, const UChar *s2);
00244 
00257 U_CAPI int32_t U_EXPORT2
00258 u_strncmp(const UChar     *ucs1, 
00259      const UChar     *ucs2, 
00260      int32_t     n);
00261 
00275 U_CAPI int32_t U_EXPORT2
00276 u_strncmpCodePointOrder(const UChar *s1, const UChar *s2, int32_t n);
00277 
00288 U_CAPI int32_t U_EXPORT2
00289 u_strcasecmp(const UChar *s1, const UChar *s2, uint32_t options);
00290 
00303 U_CAPI int32_t U_EXPORT2
00304 u_strncasecmp(const UChar *s1, const UChar *s2, int32_t n, uint32_t options);
00305 
00318 U_CAPI int32_t U_EXPORT2
00319 u_memcasecmp(const UChar *s1, const UChar *s2, int32_t length, uint32_t options);
00320 
00329 U_CAPI UChar* U_EXPORT2
00330 u_strcpy(UChar     *dst, 
00331     const UChar     *src);
00332 
00344 U_CAPI UChar* U_EXPORT2
00345 u_strncpy(UChar     *dst, 
00346      const UChar     *src, 
00347      int32_t     n);
00348 
00359 U_CAPI UChar* U_EXPORT2 u_uastrcpy(UChar *dst,
00360                const char *src );
00361 
00374 U_CAPI UChar* U_EXPORT2 u_uastrncpy(UChar *dst,
00375             const char *src,
00376             int32_t n);
00377 
00388 U_CAPI char* U_EXPORT2 u_austrcpy(char *dst,
00389             const UChar *src );
00390 
00403 U_CAPI char* U_EXPORT2 u_austrncpy(char *dst,
00404             const UChar *src,
00405             int32_t n );
00406 
00411 U_CAPI UChar* U_EXPORT2
00412 u_memcpy(UChar *dest, const UChar *src, int32_t count);
00413 
00418 U_CAPI UChar* U_EXPORT2
00419 u_memmove(UChar *dest, const UChar *src, int32_t count);
00420 
00430 U_CAPI UChar* U_EXPORT2
00431 u_memset(UChar *dest, UChar c, int32_t count);
00432 
00444 U_CAPI int32_t U_EXPORT2
00445 u_memcmp(UChar *buf1, UChar *buf2, int32_t count);
00446 
00460 U_CAPI int32_t U_EXPORT2
00461 u_memcmpCodePointOrder(const UChar *s1, const UChar *s2, int32_t count);
00462 
00475 U_CAPI UChar* U_EXPORT2
00476 u_memchr(UChar *src, UChar ch, int32_t count);
00477 
00490 U_CAPI UChar* U_EXPORT2
00491 u_memchr32(UChar *src, UChar32 ch, int32_t count);
00492 
00529 #if U_SIZEOF_WCHAR_T==U_SIZEOF_UCHAR && U_CHARSET_FAMILY==U_ASCII_FAMILY
00530 #   define U_STRING_DECL(var, cs, length) static const wchar_t var[(length)+1]={ L ## cs }
00531 #   define U_STRING_INIT(var, cs, length)
00532 #elif U_SIZEOF_UCHAR==1 && U_CHARSET_FAMILY==U_ASCII_FAMILY
00533 #   define U_STRING_DECL(var, cs, length) static const UChar var[(length)+1]={ (const UChar *)cs }
00534 #   define U_STRING_INIT(var, cs, length)
00535 #else
00536 #   define U_STRING_DECL(var, cs, length) static UChar var[(length)+1]
00537 #   define U_STRING_INIT(var, cs, length) u_charsToUChars(cs, var, length+1)
00538 #endif
00539 
00586 U_CAPI int32_t U_EXPORT2
00587 u_unescape(const char *src,
00588            UChar *dest, int32_t destCapacity);
00589 
00598 U_CDECL_BEGIN
00599 typedef UChar (*UNESCAPE_CHAR_AT)(int32_t offset, void *context);
00600 U_CDECL_END
00601 
00630 U_CAPI UChar32 U_EXPORT2
00631 u_unescapeAt(UNESCAPE_CHAR_AT charAt,
00632              int32_t *offset,
00633              int32_t length,
00634              void *context);
00635 
00656 U_CAPI int32_t U_EXPORT2
00657 u_strToUpper(UChar *dest, int32_t destCapacity,
00658              const UChar *src, int32_t srcLength,
00659              const char *locale,
00660              UErrorCode *pErrorCode);
00661 
00682 U_CAPI int32_t U_EXPORT2
00683 u_strToLower(UChar *dest, int32_t destCapacity,
00684              const UChar *src, int32_t srcLength,
00685              const char *locale,
00686              UErrorCode *pErrorCode);
00687 
00710 U_CAPI int32_t U_EXPORT2
00711 u_strFoldCase(UChar *dest, int32_t destCapacity,
00712               const UChar *src, int32_t srcLength,
00713               uint32_t options,
00714               UErrorCode *pErrorCode);
00715 
00735 U_CAPI wchar_t* U_EXPORT2
00736 u_strToWCS(wchar_t *dest, 
00737            int32_t destCapacity,
00738            int32_t *pDestLength,
00739            const UChar *src, 
00740            int32_t srcLength,
00741            UErrorCode *pErrorCode);
00761 U_CAPI UChar* U_EXPORT2
00762 u_strFromWCS(UChar   *dest,
00763              int32_t destCapacity, 
00764              int32_t *pDestLength,
00765              const wchar_t *src,
00766              int32_t srcLength,
00767              UErrorCode *pErrorCode);
00787 U_CAPI char* U_EXPORT2 
00788 u_strToUTF8(char *dest,           
00789             int32_t destCapacity,
00790             int32_t *pDestLength,
00791             const UChar *src, 
00792             int32_t srcLength,
00793             UErrorCode *pErrorCode);
00794 
00814 U_CAPI UChar* U_EXPORT2
00815 u_strFromUTF8(UChar *dest,             
00816               int32_t destCapacity,
00817               int32_t *pDestLength,
00818               const char *src, 
00819               int32_t srcLength,
00820               UErrorCode *pErrorCode);
00821 
00841 U_CAPI UChar32* U_EXPORT2 
00842 u_strToUTF32(UChar32 *dest, 
00843              int32_t  destCapacity,
00844              int32_t  *pDestLength,
00845              const UChar *src, 
00846              int32_t  srcLength,
00847              UErrorCode *pErrorCode);
00848 
00868 U_CAPI UChar* U_EXPORT2 
00869 u_strFromUTF32(UChar   *dest,
00870                int32_t destCapacity, 
00871                int32_t *pDestLength,
00872                const UChar32 *src,
00873                int32_t srcLength,
00874                UErrorCode *pErrorCode);
00875 
00876 #endif

Generated on Mon Dec 3 19:00:28 2001 for ICU 2.0 by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001