1 // © 2016 and later: Unicode, Inc. and others.
2 // License & terms of use: http://www.unicode.org/copyright.html
3 /*
4 **********************************************************************
5 *   Copyright (C) 1997-2016, International Business Machines
6 *   Corporation and others.  All Rights Reserved.
7 **********************************************************************
8 *
9 * File UCHAR.H
10 *
11 * Modification History:
12 *
13 *   Date        Name        Description
14 *   04/02/97    aliu        Creation.
15 *   03/29/99    helena      Updated for C APIs.
16 *   4/15/99     Madhu       Updated for C Implementation and Javadoc
17 *   5/20/99     Madhu       Added the function u_getVersion()
18 *   8/19/1999   srl         Upgraded scripts to Unicode 3.0
19 *   8/27/1999   schererm    UCharDirection constants: U_...
20 *   11/11/1999  weiv        added u_isalnum(), cleaned comments
21 *   01/11/2000  helena      Renamed u_getVersion to u_getUnicodeVersion().
22 ******************************************************************************
23 */
24 
25 #ifndef UCHAR_H
26 #define UCHAR_H
27 
28 #include "unicode/utypes.h"
29 #include "unicode/stringoptions.h"
30 
31 #if !defined(USET_DEFINED) && !defined(U_IN_DOXYGEN)
32 
33 #define USET_DEFINED
34 
35 /**
36  * USet is the C API type corresponding to C++ class UnicodeSet.
37  * It is forward-declared here to avoid including unicode/uset.h file if related
38  * APIs are not used.
39  *
40  * @see ucnv_getUnicodeSet
41  * @stable ICU 2.4
42  */
43 typedef struct USet USet;
44 
45 #endif
46 
47 
48 U_CDECL_BEGIN
49 
50 /*==========================================================================*/
51 /* Unicode version number                                                   */
52 /*==========================================================================*/
53 /**
54  * Unicode version number, default for the current ICU version.
55  * The actual Unicode Character Database (UCD) data is stored in uprops.dat
56  * and may be generated from UCD files from a different Unicode version.
57  * Call u_getUnicodeVersion to get the actual Unicode version of the data.
58  *
59  * @see u_getUnicodeVersion
60  * @stable ICU 2.0
61  */
62 #define U_UNICODE_VERSION "15.0"
63 
64 /**
65  * \file
66  * \brief C API: Unicode Properties
67  *
68  * This C API provides low-level access to the Unicode Character Database.
69  * In addition to raw property values, some convenience functions calculate
70  * derived properties, for example for Java-style programming.
71  *
72  * Unicode assigns each code point (not just assigned character) values for
73  * many properties.
74  * Most of them are simple boolean flags, or constants from a small enumerated list.
75  * For some properties, values are strings or other relatively more complex types.
76  *
77  * For more information see
78  * "About the Unicode Character Database" (http://www.unicode.org/ucd/)
79  * and the ICU User Guide chapter on Properties (https://unicode-org.github.io/icu/userguide/strings/properties).
80  *
81  * Many properties are accessible via generic functions that take a UProperty selector.
82  * - u_hasBinaryProperty() returns a binary value (true/false) per property and code point.
83  * - u_getIntPropertyValue() returns an integer value per property and code point.
84  *   For each supported enumerated or catalog property, there is
85  *   an enum type for all of the property's values, and
86  *   u_getIntPropertyValue() returns the numeric values of those constants.
87  * - u_getBinaryPropertySet() returns a set for each ICU-supported binary property with
88  *   all code points for which the property is true.
89  * - u_getIntPropertyMap() returns a map for each
90  *   ICU-supported enumerated/catalog/int-valued property which
91  *   maps all Unicode code points to their values for that property.
92  *
93  * Many functions are designed to match java.lang.Character functions.
94  * See the individual function documentation,
95  * and see the JDK 1.4 java.lang.Character documentation
96  * at http://java.sun.com/j2se/1.4/docs/api/java/lang/Character.html
97  *
98  * There are also functions that provide easy migration from C/POSIX functions
99  * like isblank(). Their use is generally discouraged because the C/POSIX
100  * standards do not define their semantics beyond the ASCII range, which means
101  * that different implementations exhibit very different behavior.
102  * Instead, Unicode properties should be used directly.
103  *
104  * There are also only a few, broad C/POSIX character classes, and they tend
105  * to be used for conflicting purposes. For example, the "isalpha()" class
106  * is sometimes used to determine word boundaries, while a more sophisticated
107  * approach would at least distinguish initial letters from continuation
108  * characters (the latter including combining marks).
109  * (In ICU, BreakIterator is the most sophisticated API for word boundaries.)
110  * Another example: There is no "istitle()" class for titlecase characters.
111  *
112  * ICU 3.4 and later provides API access for all twelve C/POSIX character classes.
113  * ICU implements them according to the Standard Recommendations in
114  * Annex C: Compatibility Properties of UTS #18 Unicode Regular Expressions
115  * (http://www.unicode.org/reports/tr18/#Compatibility_Properties).
116  *
117  * API access for C/POSIX character classes is as follows:
118  * - alpha:     u_isUAlphabetic(c) or u_hasBinaryProperty(c, UCHAR_ALPHABETIC)
119  * - lower:     u_isULowercase(c) or u_hasBinaryProperty(c, UCHAR_LOWERCASE)
120  * - upper:     u_isUUppercase(c) or u_hasBinaryProperty(c, UCHAR_UPPERCASE)
121  * - punct:     u_ispunct(c)
122  * - digit:     u_isdigit(c) or u_charType(c)==U_DECIMAL_DIGIT_NUMBER
123  * - xdigit:    u_isxdigit(c) or u_hasBinaryProperty(c, UCHAR_POSIX_XDIGIT)
124  * - alnum:     u_hasBinaryProperty(c, UCHAR_POSIX_ALNUM)
125  * - space:     u_isUWhiteSpace(c) or u_hasBinaryProperty(c, UCHAR_WHITE_SPACE)
126  * - blank:     u_isblank(c) or u_hasBinaryProperty(c, UCHAR_POSIX_BLANK)
127  * - cntrl:     u_charType(c)==U_CONTROL_CHAR
128  * - graph:     u_hasBinaryProperty(c, UCHAR_POSIX_GRAPH)
129  * - print:     u_hasBinaryProperty(c, UCHAR_POSIX_PRINT)
130  *
131  * Note: Some of the u_isxyz() functions in uchar.h predate, and do not match,
132  * the Standard Recommendations in UTS #18. Instead, they match Java
133  * functions according to their API documentation.
134  *
135  * \htmlonly
136  * The C/POSIX character classes are also available in UnicodeSet patterns,
137  * using patterns like [:graph:] or \p{graph}.
138  * \endhtmlonly
139  *
140  * Note: There are several ICU whitespace functions.
141  * Comparison:
142  * - u_isUWhiteSpace=UCHAR_WHITE_SPACE: Unicode White_Space property;
143  *       most of general categories "Z" (separators) + most whitespace ISO controls
144  *       (including no-break spaces, but excluding IS1..IS4)
145  * - u_isWhitespace: Java isWhitespace; Z + whitespace ISO controls but excluding no-break spaces
146  * - u_isJavaSpaceChar: Java isSpaceChar; just Z (including no-break spaces)
147  * - u_isspace: Z + whitespace ISO controls (including no-break spaces)
148  * - u_isblank: "horizontal spaces" = TAB + Zs
149  */
150 
151 /**
152  * Constants.
153  */
154 
155 /** The lowest Unicode code point value. Code points are non-negative. @stable ICU 2.0 */
156 #define UCHAR_MIN_VALUE 0
157 
158 /**
159  * The highest Unicode code point value (scalar value) according to
160  * The Unicode Standard. This is a 21-bit value (20.1 bits, rounded up).
161  * For a single character, UChar32 is a simple type that can hold any code point value.
162  *
163  * @see UChar32
164  * @stable ICU 2.0
165  */
166 #define UCHAR_MAX_VALUE 0x10ffff
167 
168 /**
169  * Get a single-bit bit set (a flag) from a bit number 0..31.
170  * @stable ICU 2.1
171  */
172 #define U_MASK(x) ((uint32_t)1<<(x))
173 
174 /**
175  * Selection constants for Unicode properties.
176  * These constants are used in functions like u_hasBinaryProperty to select
177  * one of the Unicode properties.
178  *
179  * The properties APIs are intended to reflect Unicode properties as defined
180  * in the Unicode Character Database (UCD) and Unicode Technical Reports (UTR).
181  *
182  * For details about the properties see
183  * UAX #44: Unicode Character Database (http://www.unicode.org/reports/tr44/).
184  *
185  * Important: If ICU is built with UCD files from Unicode versions below, e.g., 3.2,
186  * then properties marked with "new in Unicode 3.2" are not or not fully available.
187  * Check u_getUnicodeVersion to be sure.
188  *
189  * @see u_hasBinaryProperty
190  * @see u_getIntPropertyValue
191  * @see u_getUnicodeVersion
192  * @stable ICU 2.1
193  */
194 typedef enum UProperty {
195     /*
196      * Note: UProperty constants are parsed by preparseucd.py.
197      * It matches lines like
198      *     UCHAR_<Unicode property name>=<integer>,
199      */
200 
201     /*  Note: Place UCHAR_ALPHABETIC before UCHAR_BINARY_START so that
202     debuggers display UCHAR_ALPHABETIC as the symbolic name for 0,
203     rather than UCHAR_BINARY_START.  Likewise for other *_START
204     identifiers. */
205 
206     /** Binary property Alphabetic. Same as u_isUAlphabetic, different from u_isalpha.
207         Lu+Ll+Lt+Lm+Lo+Nl+Other_Alphabetic @stable ICU 2.1 */
208     UCHAR_ALPHABETIC=0,
209     /** First constant for binary Unicode properties. @stable ICU 2.1 */
210     UCHAR_BINARY_START=UCHAR_ALPHABETIC,
211     /** Binary property ASCII_Hex_Digit. 0-9 A-F a-f @stable ICU 2.1 */
212     UCHAR_ASCII_HEX_DIGIT=1,
213     /** Binary property Bidi_Control.
214         Format controls which have specific functions
215         in the Bidi Algorithm. @stable ICU 2.1 */
216     UCHAR_BIDI_CONTROL=2,
217     /** Binary property Bidi_Mirrored.
218         Characters that may change display in RTL text.
219         Same as u_isMirrored.
220         See Bidi Algorithm, UTR 9. @stable ICU 2.1 */
221     UCHAR_BIDI_MIRRORED=3,
222     /** Binary property Dash. Variations of dashes. @stable ICU 2.1 */
223     UCHAR_DASH=4,
224     /** Binary property Default_Ignorable_Code_Point (new in Unicode 3.2).
225         Ignorable in most processing.
226         <2060..206F, FFF0..FFFB, E0000..E0FFF>+Other_Default_Ignorable_Code_Point+(Cf+Cc+Cs-White_Space) @stable ICU 2.1 */
227     UCHAR_DEFAULT_IGNORABLE_CODE_POINT=5,
228     /** Binary property Deprecated (new in Unicode 3.2).
229         The usage of deprecated characters is strongly discouraged. @stable ICU 2.1 */
230     UCHAR_DEPRECATED=6,
231     /** Binary property Diacritic. Characters that linguistically modify
232         the meaning of another character to which they apply. @stable ICU 2.1 */
233     UCHAR_DIACRITIC=7,
234     /** Binary property Extender.
235         Extend the value or shape of a preceding alphabetic character,
236         e.g., length and iteration marks. @stable ICU 2.1 */
237     UCHAR_EXTENDER=8,
238     /** Binary property Full_Composition_Exclusion.
239         CompositionExclusions.txt+Singleton Decompositions+
240         Non-Starter Decompositions. @stable ICU 2.1 */
241     UCHAR_FULL_COMPOSITION_EXCLUSION=9,
242     /** Binary property Grapheme_Base (new in Unicode 3.2).
243         For programmatic determination of grapheme cluster boundaries.
244         [0..10FFFF]-Cc-Cf-Cs-Co-Cn-Zl-Zp-Grapheme_Link-Grapheme_Extend-CGJ @stable ICU 2.1 */
245     UCHAR_GRAPHEME_BASE=10,
246     /** Binary property Grapheme_Extend (new in Unicode 3.2).
247         For programmatic determination of grapheme cluster boundaries.
248         Me+Mn+Mc+Other_Grapheme_Extend-Grapheme_Link-CGJ @stable ICU 2.1 */
249     UCHAR_GRAPHEME_EXTEND=11,
250     /** Binary property Grapheme_Link (new in Unicode 3.2).
251         For programmatic determination of grapheme cluster boundaries. @stable ICU 2.1 */
252     UCHAR_GRAPHEME_LINK=12,
253     /** Binary property Hex_Digit.
254         Characters commonly used for hexadecimal numbers. @stable ICU 2.1 */
255     UCHAR_HEX_DIGIT=13,
256     /** Binary property Hyphen. Dashes used to mark connections
257         between pieces of words, plus the Katakana middle dot. @stable ICU 2.1 */
258     UCHAR_HYPHEN=14,
259     /** Binary property ID_Continue.
260         Characters that can continue an identifier.
261         DerivedCoreProperties.txt also says "NOTE: Cf characters should be filtered out."
262         ID_Start+Mn+Mc+Nd+Pc @stable ICU 2.1 */
263     UCHAR_ID_CONTINUE=15,
264     /** Binary property ID_Start.
265         Characters that can start an identifier.
266         Lu+Ll+Lt+Lm+Lo+Nl @stable ICU 2.1 */
267     UCHAR_ID_START=16,
268     /** Binary property Ideographic.
269         CJKV ideographs. @stable ICU 2.1 */
270     UCHAR_IDEOGRAPHIC=17,
271     /** Binary property IDS_Binary_Operator (new in Unicode 3.2).
272         For programmatic determination of
273         Ideographic Description Sequences. @stable ICU 2.1 */
274     UCHAR_IDS_BINARY_OPERATOR=18,
275     /** Binary property IDS_Trinary_Operator (new in Unicode 3.2).
276         For programmatic determination of
277         Ideographic Description Sequences. @stable ICU 2.1 */
278     UCHAR_IDS_TRINARY_OPERATOR=19,
279     /** Binary property Join_Control.
280         Format controls for cursive joining and ligation. @stable ICU 2.1 */
281     UCHAR_JOIN_CONTROL=20,
282     /** Binary property Logical_Order_Exception (new in Unicode 3.2).
283         Characters that do not use logical order and
284         require special handling in most processing. @stable ICU 2.1 */
285     UCHAR_LOGICAL_ORDER_EXCEPTION=21,
286     /** Binary property Lowercase. Same as u_isULowercase, different from u_islower.
287         Ll+Other_Lowercase @stable ICU 2.1 */
288     UCHAR_LOWERCASE=22,
289     /** Binary property Math. Sm+Other_Math @stable ICU 2.1 */
290     UCHAR_MATH=23,
291     /** Binary property Noncharacter_Code_Point.
292         Code points that are explicitly defined as illegal
293         for the encoding of characters. @stable ICU 2.1 */
294     UCHAR_NONCHARACTER_CODE_POINT=24,
295     /** Binary property Quotation_Mark. @stable ICU 2.1 */
296     UCHAR_QUOTATION_MARK=25,
297     /** Binary property Radical (new in Unicode 3.2).
298         For programmatic determination of
299         Ideographic Description Sequences. @stable ICU 2.1 */
300     UCHAR_RADICAL=26,
301     /** Binary property Soft_Dotted (new in Unicode 3.2).
302         Characters with a "soft dot", like i or j.
303         An accent placed on these characters causes
304         the dot to disappear. @stable ICU 2.1 */
305     UCHAR_SOFT_DOTTED=27,
306     /** Binary property Terminal_Punctuation.
307         Punctuation characters that generally mark
308         the end of textual units. @stable ICU 2.1 */
309     UCHAR_TERMINAL_PUNCTUATION=28,
310     /** Binary property Unified_Ideograph (new in Unicode 3.2).
311         For programmatic determination of
312         Ideographic Description Sequences. @stable ICU 2.1 */
313     UCHAR_UNIFIED_IDEOGRAPH=29,
314     /** Binary property Uppercase. Same as u_isUUppercase, different from u_isupper.
315         Lu+Other_Uppercase @stable ICU 2.1 */
316     UCHAR_UPPERCASE=30,
317     /** Binary property White_Space.
318         Same as u_isUWhiteSpace, different from u_isspace and u_isWhitespace.
319         Space characters+TAB+CR+LF-ZWSP-ZWNBSP @stable ICU 2.1 */
320     UCHAR_WHITE_SPACE=31,
321     /** Binary property XID_Continue.
322         ID_Continue modified to allow closure under
323         normalization forms NFKC and NFKD. @stable ICU 2.1 */
324     UCHAR_XID_CONTINUE=32,
325     /** Binary property XID_Start. ID_Start modified to allow
326         closure under normalization forms NFKC and NFKD. @stable ICU 2.1 */
327     UCHAR_XID_START=33,
328     /** Binary property Case_Sensitive. Either the source of a case
329         mapping or _in_ the target of a case mapping. Not the same as
330         the general category Cased_Letter. @stable ICU 2.6 */
331    UCHAR_CASE_SENSITIVE=34,
332     /** Binary property STerm (new in Unicode 4.0.1).
333         Sentence Terminal. Used in UAX #29: Text Boundaries
334         (http://www.unicode.org/reports/tr29/)
335         @stable ICU 3.0 */
336     UCHAR_S_TERM=35,
337     /** Binary property Variation_Selector (new in Unicode 4.0.1).
338         Indicates all those characters that qualify as Variation Selectors.
339         For details on the behavior of these characters,
340         see StandardizedVariants.html and 15.6 Variation Selectors.
341         @stable ICU 3.0 */
342     UCHAR_VARIATION_SELECTOR=36,
343     /** Binary property NFD_Inert.
344         ICU-specific property for characters that are inert under NFD,
345         i.e., they do not interact with adjacent characters.
346         See the documentation for the Normalizer2 class and the
347         Normalizer2::isInert() method.
348         @stable ICU 3.0 */
349     UCHAR_NFD_INERT=37,
350     /** Binary property NFKD_Inert.
351         ICU-specific property for characters that are inert under NFKD,
352         i.e., they do not interact with adjacent characters.
353         See the documentation for the Normalizer2 class and the
354         Normalizer2::isInert() method.
355         @stable ICU 3.0 */
356     UCHAR_NFKD_INERT=38,
357     /** Binary property NFC_Inert.
358         ICU-specific property for characters that are inert under NFC,
359         i.e., they do not interact with adjacent characters.
360         See the documentation for the Normalizer2 class and the
361         Normalizer2::isInert() method.
362         @stable ICU 3.0 */
363     UCHAR_NFC_INERT=39,
364     /** Binary property NFKC_Inert.
365         ICU-specific property for characters that are inert under NFKC,
366         i.e., they do not interact with adjacent characters.
367         See the documentation for the Normalizer2 class and the
368         Normalizer2::isInert() method.
369         @stable ICU 3.0 */
370     UCHAR_NFKC_INERT=40,
371     /** Binary Property Segment_Starter.
372         ICU-specific property for characters that are starters in terms of
373         Unicode normalization and combining character sequences.
374         They have ccc=0 and do not occur in non-initial position of the
375         canonical decomposition of any character
376         (like a-umlaut in NFD and a Jamo T in an NFD(Hangul LVT)).
377         ICU uses this property for segmenting a string for generating a set of
378         canonically equivalent strings, e.g. for canonical closure while
379         processing collation tailoring rules.
380         @stable ICU 3.0 */
381     UCHAR_SEGMENT_STARTER=41,
382     /** Binary property Pattern_Syntax (new in Unicode 4.1).
383         See UAX #31 Identifier and Pattern Syntax
384         (http://www.unicode.org/reports/tr31/)
385         @stable ICU 3.4 */
386     UCHAR_PATTERN_SYNTAX=42,
387     /** Binary property Pattern_White_Space (new in Unicode 4.1).
388         See UAX #31 Identifier and Pattern Syntax
389         (http://www.unicode.org/reports/tr31/)
390         @stable ICU 3.4 */
391     UCHAR_PATTERN_WHITE_SPACE=43,
392     /** Binary property alnum (a C/POSIX character class).
393         Implemented according to the UTS #18 Annex C Standard Recommendation.
394         See the uchar.h file documentation.
395         @stable ICU 3.4 */
396     UCHAR_POSIX_ALNUM=44,
397     /** Binary property blank (a C/POSIX character class).
398         Implemented according to the UTS #18 Annex C Standard Recommendation.
399         See the uchar.h file documentation.
400         @stable ICU 3.4 */
401     UCHAR_POSIX_BLANK=45,
402     /** Binary property graph (a C/POSIX character class).
403         Implemented according to the UTS #18 Annex C Standard Recommendation.
404         See the uchar.h file documentation.
405         @stable ICU 3.4 */
406     UCHAR_POSIX_GRAPH=46,
407     /** Binary property print (a C/POSIX character class).
408         Implemented according to the UTS #18 Annex C Standard Recommendation.
409         See the uchar.h file documentation.
410         @stable ICU 3.4 */
411     UCHAR_POSIX_PRINT=47,
412     /** Binary property xdigit (a C/POSIX character class).
413         Implemented according to the UTS #18 Annex C Standard Recommendation.
414         See the uchar.h file documentation.
415         @stable ICU 3.4 */
416     UCHAR_POSIX_XDIGIT=48,
417     /** Binary property Cased. For Lowercase, Uppercase and Titlecase characters. @stable ICU 4.4 */
418     UCHAR_CASED=49,
419     /** Binary property Case_Ignorable. Used in context-sensitive case mappings. @stable ICU 4.4 */
420     UCHAR_CASE_IGNORABLE=50,
421     /** Binary property Changes_When_Lowercased. @stable ICU 4.4 */
422     UCHAR_CHANGES_WHEN_LOWERCASED=51,
423     /** Binary property Changes_When_Uppercased. @stable ICU 4.4 */
424     UCHAR_CHANGES_WHEN_UPPERCASED=52,
425     /** Binary property Changes_When_Titlecased. @stable ICU 4.4 */
426     UCHAR_CHANGES_WHEN_TITLECASED=53,
427     /** Binary property Changes_When_Casefolded. @stable ICU 4.4 */
428     UCHAR_CHANGES_WHEN_CASEFOLDED=54,
429     /** Binary property Changes_When_Casemapped. @stable ICU 4.4 */
430     UCHAR_CHANGES_WHEN_CASEMAPPED=55,
431     /** Binary property Changes_When_NFKC_Casefolded. @stable ICU 4.4 */
432     UCHAR_CHANGES_WHEN_NFKC_CASEFOLDED=56,
433     /**
434      * Binary property Emoji.
435      * See http://www.unicode.org/reports/tr51/#Emoji_Properties
436      *
437      * @stable ICU 57
438      */
439     UCHAR_EMOJI=57,
440     /**
441      * Binary property Emoji_Presentation.
442      * See http://www.unicode.org/reports/tr51/#Emoji_Properties
443      *
444      * @stable ICU 57
445      */
446     UCHAR_EMOJI_PRESENTATION=58,
447     /**
448      * Binary property Emoji_Modifier.
449      * See http://www.unicode.org/reports/tr51/#Emoji_Properties
450      *
451      * @stable ICU 57
452      */
453     UCHAR_EMOJI_MODIFIER=59,
454     /**
455      * Binary property Emoji_Modifier_Base.
456      * See http://www.unicode.org/reports/tr51/#Emoji_Properties
457      *
458      * @stable ICU 57
459      */
460     UCHAR_EMOJI_MODIFIER_BASE=60,
461     /**
462      * Binary property Emoji_Component.
463      * See http://www.unicode.org/reports/tr51/#Emoji_Properties
464      *
465      * @stable ICU 60
466      */
467     UCHAR_EMOJI_COMPONENT=61,
468     /**
469      * Binary property Regional_Indicator.
470      * @stable ICU 60
471      */
472     UCHAR_REGIONAL_INDICATOR=62,
473     /**
474      * Binary property Prepended_Concatenation_Mark.
475      * @stable ICU 60
476      */
477     UCHAR_PREPENDED_CONCATENATION_MARK=63,
478     /**
479      * Binary property Extended_Pictographic.
480      * See http://www.unicode.org/reports/tr51/#Emoji_Properties
481      *
482      * @stable ICU 62
483      */
484     UCHAR_EXTENDED_PICTOGRAPHIC=64,
485     /**
486      * Binary property of strings Basic_Emoji.
487      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
488      *
489      * @stable ICU 70
490      */
491     UCHAR_BASIC_EMOJI=65,
492     /**
493      * Binary property of strings Emoji_Keycap_Sequence.
494      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
495      *
496      * @stable ICU 70
497      */
498     UCHAR_EMOJI_KEYCAP_SEQUENCE=66,
499     /**
500      * Binary property of strings RGI_Emoji_Modifier_Sequence.
501      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
502      *
503      * @stable ICU 70
504      */
505     UCHAR_RGI_EMOJI_MODIFIER_SEQUENCE=67,
506     /**
507      * Binary property of strings RGI_Emoji_Flag_Sequence.
508      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
509      *
510      * @stable ICU 70
511      */
512     UCHAR_RGI_EMOJI_FLAG_SEQUENCE=68,
513     /**
514      * Binary property of strings RGI_Emoji_Tag_Sequence.
515      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
516      *
517      * @stable ICU 70
518      */
519     UCHAR_RGI_EMOJI_TAG_SEQUENCE=69,
520     /**
521      * Binary property of strings RGI_Emoji_ZWJ_Sequence.
522      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
523      *
524      * @stable ICU 70
525      */
526     UCHAR_RGI_EMOJI_ZWJ_SEQUENCE=70,
527     /**
528      * Binary property of strings RGI_Emoji.
529      * See https://www.unicode.org/reports/tr51/#Emoji_Sets
530      *
531      * @stable ICU 70
532      */
533     UCHAR_RGI_EMOJI=71,
534     /** Enumerated property Bidi_Class.
535         Same as u_charDirection, returns UCharDirection values. @stable ICU 2.2 */
536     UCHAR_BIDI_CLASS=0x1000,
537     /** First constant for enumerated/integer Unicode properties. @stable ICU 2.2 */
538     UCHAR_INT_START=UCHAR_BIDI_CLASS,
539     /** Enumerated property Block.
540         Same as ublock_getCode, returns UBlockCode values. @stable ICU 2.2 */
541     UCHAR_BLOCK=0x1001,
542     /** Enumerated property Canonical_Combining_Class.
543         Same as u_getCombiningClass, returns 8-bit numeric values. @stable ICU 2.2 */
544     UCHAR_CANONICAL_COMBINING_CLASS=0x1002,
545     /** Enumerated property Decomposition_Type.
546         Returns UDecompositionType values. @stable ICU 2.2 */
547     UCHAR_DECOMPOSITION_TYPE=0x1003,
548     /** Enumerated property East_Asian_Width.
549         See http://www.unicode.org/reports/tr11/
550         Returns UEastAsianWidth values. @stable ICU 2.2 */
551     UCHAR_EAST_ASIAN_WIDTH=0x1004,
552     /** Enumerated property General_Category.
553         Same as u_charType, returns UCharCategory values. @stable ICU 2.2 */
554     UCHAR_GENERAL_CATEGORY=0x1005,
555     /** Enumerated property Joining_Group.
556         Returns UJoiningGroup values. @stable ICU 2.2 */
557     UCHAR_JOINING_GROUP=0x1006,
558     /** Enumerated property Joining_Type.
559         Returns UJoiningType values. @stable ICU 2.2 */
560     UCHAR_JOINING_TYPE=0x1007,
561     /** Enumerated property Line_Break.
562         Returns ULineBreak values. @stable ICU 2.2 */
563     UCHAR_LINE_BREAK=0x1008,
564     /** Enumerated property Numeric_Type.
565         Returns UNumericType values. @stable ICU 2.2 */
566     UCHAR_NUMERIC_TYPE=0x1009,
567     /** Enumerated property Script.
568         Same as uscript_getScript, returns UScriptCode values. @stable ICU 2.2 */
569     UCHAR_SCRIPT=0x100A,
570     /** Enumerated property Hangul_Syllable_Type, new in Unicode 4.
571         Returns UHangulSyllableType values. @stable ICU 2.6 */
572     UCHAR_HANGUL_SYLLABLE_TYPE=0x100B,
573     /** Enumerated property NFD_Quick_Check.
574         Returns UNormalizationCheckResult values. @stable ICU 3.0 */
575     UCHAR_NFD_QUICK_CHECK=0x100C,
576     /** Enumerated property NFKD_Quick_Check.
577         Returns UNormalizationCheckResult values. @stable ICU 3.0 */
578     UCHAR_NFKD_QUICK_CHECK=0x100D,
579     /** Enumerated property NFC_Quick_Check.
580         Returns UNormalizationCheckResult values. @stable ICU 3.0 */
581     UCHAR_NFC_QUICK_CHECK=0x100E,
582     /** Enumerated property NFKC_Quick_Check.
583         Returns UNormalizationCheckResult values. @stable ICU 3.0 */
584     UCHAR_NFKC_QUICK_CHECK=0x100F,
585     /** Enumerated property Lead_Canonical_Combining_Class.
586         ICU-specific property for the ccc of the first code point
587         of the decomposition, or lccc(c)=ccc(NFD(c)[0]).
588         Useful for checking for canonically ordered text;
589         see UNORM_FCD and http://www.unicode.org/notes/tn5/#FCD .
590         Returns 8-bit numeric values like UCHAR_CANONICAL_COMBINING_CLASS. @stable ICU 3.0 */
591     UCHAR_LEAD_CANONICAL_COMBINING_CLASS=0x1010,
592     /** Enumerated property Trail_Canonical_Combining_Class.
593         ICU-specific property for the ccc of the last code point
594         of the decomposition, or tccc(c)=ccc(NFD(c)[last]).
595         Useful for checking for canonically ordered text;
596         see UNORM_FCD and http://www.unicode.org/notes/tn5/#FCD .
597         Returns 8-bit numeric values like UCHAR_CANONICAL_COMBINING_CLASS. @stable ICU 3.0 */
598     UCHAR_TRAIL_CANONICAL_COMBINING_CLASS=0x1011,
599     /** Enumerated property Grapheme_Cluster_Break (new in Unicode 4.1).
600         Used in UAX #29: Text Boundaries
601         (http://www.unicode.org/reports/tr29/)
602         Returns UGraphemeClusterBreak values. @stable ICU 3.4 */
603     UCHAR_GRAPHEME_CLUSTER_BREAK=0x1012,
604     /** Enumerated property Sentence_Break (new in Unicode 4.1).
605         Used in UAX #29: Text Boundaries
606         (http://www.unicode.org/reports/tr29/)
607         Returns USentenceBreak values. @stable ICU 3.4 */
608     UCHAR_SENTENCE_BREAK=0x1013,
609     /** Enumerated property Word_Break (new in Unicode 4.1).
610         Used in UAX #29: Text Boundaries
611         (http://www.unicode.org/reports/tr29/)
612         Returns UWordBreakValues values. @stable ICU 3.4 */
613     UCHAR_WORD_BREAK=0x1014,
614     /** Enumerated property Bidi_Paired_Bracket_Type (new in Unicode 6.3).
615         Used in UAX #9: Unicode Bidirectional Algorithm
616         (http://www.unicode.org/reports/tr9/)
617         Returns UBidiPairedBracketType values. @stable ICU 52 */
618     UCHAR_BIDI_PAIRED_BRACKET_TYPE=0x1015,
619     /**
620      * Enumerated property Indic_Positional_Category.
621      * New in Unicode 6.0 as provisional property Indic_Matra_Category;
622      * renamed and changed to informative in Unicode 8.0.
623      * See http://www.unicode.org/reports/tr44/#IndicPositionalCategory.txt
624      * @stable ICU 63
625      */
626     UCHAR_INDIC_POSITIONAL_CATEGORY=0x1016,
627     /**
628      * Enumerated property Indic_Syllabic_Category.
629      * New in Unicode 6.0 as provisional; informative since Unicode 8.0.
630      * See http://www.unicode.org/reports/tr44/#IndicSyllabicCategory.txt
631      * @stable ICU 63
632      */
633     UCHAR_INDIC_SYLLABIC_CATEGORY=0x1017,
634     /**
635      * Enumerated property Vertical_Orientation.
636      * Used for UAX #50 Unicode Vertical Text Layout (https://www.unicode.org/reports/tr50/).
637      * New as a UCD property in Unicode 10.0.
638      * @stable ICU 63
639      */
640     UCHAR_VERTICAL_ORIENTATION=0x1018,
641     /** Bitmask property General_Category_Mask.
642         This is the General_Category property returned as a bit mask.
643         When used in u_getIntPropertyValue(c), same as U_MASK(u_charType(c)),
644         returns bit masks for UCharCategory values where exactly one bit is set.
645         When used with u_getPropertyValueName() and u_getPropertyValueEnum(),
646         a multi-bit mask is used for sets of categories like "Letters".
647         Mask values should be cast to uint32_t.
648         @stable ICU 2.4 */
649     UCHAR_GENERAL_CATEGORY_MASK=0x2000,
650     /** First constant for bit-mask Unicode properties. @stable ICU 2.4 */
651     UCHAR_MASK_START=UCHAR_GENERAL_CATEGORY_MASK,
652     /** Double property Numeric_Value.
653         Corresponds to u_getNumericValue. @stable ICU 2.4 */
654     UCHAR_NUMERIC_VALUE=0x3000,
655     /** First constant for double Unicode properties. @stable ICU 2.4 */
656     UCHAR_DOUBLE_START=UCHAR_NUMERIC_VALUE,
657     /** String property Age.
658         Corresponds to u_charAge. @stable ICU 2.4 */
659     UCHAR_AGE=0x4000,
660     /** First constant for string Unicode properties. @stable ICU 2.4 */
661     UCHAR_STRING_START=UCHAR_AGE,
662     /** String property Bidi_Mirroring_Glyph.
663         Corresponds to u_charMirror. @stable ICU 2.4 */
664     UCHAR_BIDI_MIRRORING_GLYPH=0x4001,
665     /** String property Case_Folding.
666         Corresponds to u_strFoldCase in ustring.h. @stable ICU 2.4 */
667     UCHAR_CASE_FOLDING=0x4002,
668     /** String property Lowercase_Mapping.
669         Corresponds to u_strToLower in ustring.h. @stable ICU 2.4 */
670     UCHAR_LOWERCASE_MAPPING=0x4004,
671     /** String property Name.
672         Corresponds to u_charName. @stable ICU 2.4 */
673     UCHAR_NAME=0x4005,
674     /** String property Simple_Case_Folding.
675         Corresponds to u_foldCase. @stable ICU 2.4 */
676     UCHAR_SIMPLE_CASE_FOLDING=0x4006,
677     /** String property Simple_Lowercase_Mapping.
678         Corresponds to u_tolower. @stable ICU 2.4 */
679     UCHAR_SIMPLE_LOWERCASE_MAPPING=0x4007,
680     /** String property Simple_Titlecase_Mapping.
681         Corresponds to u_totitle. @stable ICU 2.4 */
682     UCHAR_SIMPLE_TITLECASE_MAPPING=0x4008,
683     /** String property Simple_Uppercase_Mapping.
684         Corresponds to u_toupper. @stable ICU 2.4 */
685     UCHAR_SIMPLE_UPPERCASE_MAPPING=0x4009,
686     /** String property Titlecase_Mapping.
687         Corresponds to u_strToTitle in ustring.h. @stable ICU 2.4 */
688     UCHAR_TITLECASE_MAPPING=0x400A,
689     /** String property Uppercase_Mapping.
690         Corresponds to u_strToUpper in ustring.h. @stable ICU 2.4 */
691     UCHAR_UPPERCASE_MAPPING=0x400C,
692     /** String property Bidi_Paired_Bracket (new in Unicode 6.3).
693         Corresponds to u_getBidiPairedBracket. @stable ICU 52 */
694     UCHAR_BIDI_PAIRED_BRACKET=0x400D,
695     /** Miscellaneous property Script_Extensions (new in Unicode 6.0).
696         Some characters are commonly used in multiple scripts.
697         For more information, see UAX #24: http://www.unicode.org/reports/tr24/.
698         Corresponds to uscript_hasScript and uscript_getScriptExtensions in uscript.h.
699         @stable ICU 4.6 */
700     UCHAR_SCRIPT_EXTENSIONS=0x7000,
701     /** First constant for Unicode properties with unusual value types. @stable ICU 4.6 */
702     UCHAR_OTHER_PROPERTY_START=UCHAR_SCRIPT_EXTENSIONS,
703     /** Represents a nonexistent or invalid property or property value. @stable ICU 2.4 */
704     UCHAR_INVALID_CODE = -1
705 } UProperty;
706 
707 /**
708  * Data for enumerated Unicode general category types.
709  * See http://www.unicode.org/Public/UNIDATA/UnicodeData.html .
710  * @stable ICU 2.0
711  */
712 typedef enum UCharCategory
713 {
714     /*
715      * Note: UCharCategory constants and their API comments are parsed by preparseucd.py.
716      * It matches pairs of lines like
717      *     / ** <Unicode 2-letter General_Category value> comment... * /
718      *     U_<[A-Z_]+> = <integer>,
719      */
720 
721     /** Non-category for unassigned and non-character code points. @stable ICU 2.0 */
722     U_UNASSIGNED              = 0,
723     /** Cn "Other, Not Assigned (no characters in [UnicodeData.txt] have this property)" (same as U_UNASSIGNED!) @stable ICU 2.0 */
724     U_GENERAL_OTHER_TYPES     = 0,
725     /** Lu @stable ICU 2.0 */
726     U_UPPERCASE_LETTER        = 1,
727     /** Ll @stable ICU 2.0 */
728     U_LOWERCASE_LETTER        = 2,
729     /** Lt @stable ICU 2.0 */
730     U_TITLECASE_LETTER        = 3,
731     /** Lm @stable ICU 2.0 */
732     U_MODIFIER_LETTER         = 4,
733     /** Lo @stable ICU 2.0 */
734     U_OTHER_LETTER            = 5,
735     /** Mn @stable ICU 2.0 */
736     U_NON_SPACING_MARK        = 6,
737     /** Me @stable ICU 2.0 */
738     U_ENCLOSING_MARK          = 7,
739     /** Mc @stable ICU 2.0 */
740     U_COMBINING_SPACING_MARK  = 8,
741     /** Nd @stable ICU 2.0 */
742     U_DECIMAL_DIGIT_NUMBER    = 9,
743     /** Nl @stable ICU 2.0 */
744     U_LETTER_NUMBER           = 10,
745     /** No @stable ICU 2.0 */
746     U_OTHER_NUMBER            = 11,
747     /** Zs @stable ICU 2.0 */
748     U_SPACE_SEPARATOR         = 12,
749     /** Zl @stable ICU 2.0 */
750     U_LINE_SEPARATOR          = 13,
751     /** Zp @stable ICU 2.0 */
752     U_PARAGRAPH_SEPARATOR     = 14,
753     /** Cc @stable ICU 2.0 */
754     U_CONTROL_CHAR            = 15,
755     /** Cf @stable ICU 2.0 */
756     U_FORMAT_CHAR             = 16,
757     /** Co @stable ICU 2.0 */
758     U_PRIVATE_USE_CHAR        = 17,
759     /** Cs @stable ICU 2.0 */
760     U_SURROGATE               = 18,
761     /** Pd @stable ICU 2.0 */
762     U_DASH_PUNCTUATION        = 19,
763     /** Ps @stable ICU 2.0 */
764     U_START_PUNCTUATION       = 20,
765     /** Pe @stable ICU 2.0 */
766     U_END_PUNCTUATION         = 21,
767     /** Pc @stable ICU 2.0 */
768     U_CONNECTOR_PUNCTUATION   = 22,
769     /** Po @stable ICU 2.0 */
770     U_OTHER_PUNCTUATION       = 23,
771     /** Sm @stable ICU 2.0 */
772     U_MATH_SYMBOL             = 24,
773     /** Sc @stable ICU 2.0 */
774     U_CURRENCY_SYMBOL         = 25,
775     /** Sk @stable ICU 2.0 */
776     U_MODIFIER_SYMBOL         = 26,
777     /** So @stable ICU 2.0 */
778     U_OTHER_SYMBOL            = 27,
779     /** Pi @stable ICU 2.0 */
780     U_INITIAL_PUNCTUATION     = 28,
781     /** Pf @stable ICU 2.0 */
782     U_FINAL_PUNCTUATION       = 29,
783     /**
784      * One higher than the last enum UCharCategory constant.
785      * This numeric value is stable (will not change), see
786      * http://www.unicode.org/policies/stability_policy.html#Property_Value
787      *
788      * @stable ICU 2.0
789      */
790     U_CHAR_CATEGORY_COUNT
791 } UCharCategory;
792 
793 /**
794  * U_GC_XX_MASK constants are bit flags corresponding to Unicode
795  * general category values.
796  * For each category, the nth bit is set if the numeric value of the
797  * corresponding UCharCategory constant is n.
798  *
799  * There are also some U_GC_Y_MASK constants for groups of general categories
800  * like L for all letter categories.
801  *
802  * @see u_charType
803  * @see U_GET_GC_MASK
804  * @see UCharCategory
805  * @stable ICU 2.1
806  */
807 #define U_GC_CN_MASK    U_MASK(U_GENERAL_OTHER_TYPES)
808 
809 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
810 #define U_GC_LU_MASK    U_MASK(U_UPPERCASE_LETTER)
811 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
812 #define U_GC_LL_MASK    U_MASK(U_LOWERCASE_LETTER)
813 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
814 #define U_GC_LT_MASK    U_MASK(U_TITLECASE_LETTER)
815 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
816 #define U_GC_LM_MASK    U_MASK(U_MODIFIER_LETTER)
817 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
818 #define U_GC_LO_MASK    U_MASK(U_OTHER_LETTER)
819 
820 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
821 #define U_GC_MN_MASK    U_MASK(U_NON_SPACING_MARK)
822 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
823 #define U_GC_ME_MASK    U_MASK(U_ENCLOSING_MARK)
824 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
825 #define U_GC_MC_MASK    U_MASK(U_COMBINING_SPACING_MARK)
826 
827 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
828 #define U_GC_ND_MASK    U_MASK(U_DECIMAL_DIGIT_NUMBER)
829 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
830 #define U_GC_NL_MASK    U_MASK(U_LETTER_NUMBER)
831 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
832 #define U_GC_NO_MASK    U_MASK(U_OTHER_NUMBER)
833 
834 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
835 #define U_GC_ZS_MASK    U_MASK(U_SPACE_SEPARATOR)
836 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
837 #define U_GC_ZL_MASK    U_MASK(U_LINE_SEPARATOR)
838 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
839 #define U_GC_ZP_MASK    U_MASK(U_PARAGRAPH_SEPARATOR)
840 
841 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
842 #define U_GC_CC_MASK    U_MASK(U_CONTROL_CHAR)
843 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
844 #define U_GC_CF_MASK    U_MASK(U_FORMAT_CHAR)
845 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
846 #define U_GC_CO_MASK    U_MASK(U_PRIVATE_USE_CHAR)
847 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
848 #define U_GC_CS_MASK    U_MASK(U_SURROGATE)
849 
850 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
851 #define U_GC_PD_MASK    U_MASK(U_DASH_PUNCTUATION)
852 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
853 #define U_GC_PS_MASK    U_MASK(U_START_PUNCTUATION)
854 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
855 #define U_GC_PE_MASK    U_MASK(U_END_PUNCTUATION)
856 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
857 #define U_GC_PC_MASK    U_MASK(U_CONNECTOR_PUNCTUATION)
858 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
859 #define U_GC_PO_MASK    U_MASK(U_OTHER_PUNCTUATION)
860 
861 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
862 #define U_GC_SM_MASK    U_MASK(U_MATH_SYMBOL)
863 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
864 #define U_GC_SC_MASK    U_MASK(U_CURRENCY_SYMBOL)
865 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
866 #define U_GC_SK_MASK    U_MASK(U_MODIFIER_SYMBOL)
867 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
868 #define U_GC_SO_MASK    U_MASK(U_OTHER_SYMBOL)
869 
870 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
871 #define U_GC_PI_MASK    U_MASK(U_INITIAL_PUNCTUATION)
872 /** Mask constant for a UCharCategory. @stable ICU 2.1 */
873 #define U_GC_PF_MASK    U_MASK(U_FINAL_PUNCTUATION)
874 
875 
876 /** Mask constant for multiple UCharCategory bits (L Letters). @stable ICU 2.1 */
877 #define U_GC_L_MASK \
878             (U_GC_LU_MASK|U_GC_LL_MASK|U_GC_LT_MASK|U_GC_LM_MASK|U_GC_LO_MASK)
879 
880 /** Mask constant for multiple UCharCategory bits (LC Cased Letters). @stable ICU 2.1 */
881 #define U_GC_LC_MASK \
882             (U_GC_LU_MASK|U_GC_LL_MASK|U_GC_LT_MASK)
883 
884 /** Mask constant for multiple UCharCategory bits (M Marks). @stable ICU 2.1 */
885 #define U_GC_M_MASK (U_GC_MN_MASK|U_GC_ME_MASK|U_GC_MC_MASK)
886 
887 /** Mask constant for multiple UCharCategory bits (N Numbers). @stable ICU 2.1 */
888 #define U_GC_N_MASK (U_GC_ND_MASK|U_GC_NL_MASK|U_GC_NO_MASK)
889 
890 /** Mask constant for multiple UCharCategory bits (Z Separators). @stable ICU 2.1 */
891 #define U_GC_Z_MASK (U_GC_ZS_MASK|U_GC_ZL_MASK|U_GC_ZP_MASK)
892 
893 /** Mask constant for multiple UCharCategory bits (C Others). @stable ICU 2.1 */
894 #define U_GC_C_MASK \
895             (U_GC_CN_MASK|U_GC_CC_MASK|U_GC_CF_MASK|U_GC_CO_MASK|U_GC_CS_MASK)
896 
897 /** Mask constant for multiple UCharCategory bits (P Punctuation). @stable ICU 2.1 */
898 #define U_GC_P_MASK \
899             (U_GC_PD_MASK|U_GC_PS_MASK|U_GC_PE_MASK|U_GC_PC_MASK|U_GC_PO_MASK| \
900              U_GC_PI_MASK|U_GC_PF_MASK)
901 
902 /** Mask constant for multiple UCharCategory bits (S Symbols). @stable ICU 2.1 */
903 #define U_GC_S_MASK (U_GC_SM_MASK|U_GC_SC_MASK|U_GC_SK_MASK|U_GC_SO_MASK)
904 
905 /**
906  * This specifies the language directional property of a character set.
907  * @stable ICU 2.0
908  */
909 typedef enum UCharDirection {
910     /*
911      * Note: UCharDirection constants and their API comments are parsed by preparseucd.py.
912      * It matches pairs of lines like
913      *     / ** <Unicode 1..3-letter Bidi_Class value> comment... * /
914      *     U_<[A-Z_]+> = <integer>,
915      */
916 
917     /** L @stable ICU 2.0 */
918     U_LEFT_TO_RIGHT               = 0,
919     /** R @stable ICU 2.0 */
920     U_RIGHT_TO_LEFT               = 1,
921     /** EN @stable ICU 2.0 */
922     U_EUROPEAN_NUMBER             = 2,
923     /** ES @stable ICU 2.0 */
924     U_EUROPEAN_NUMBER_SEPARATOR   = 3,
925     /** ET @stable ICU 2.0 */
926     U_EUROPEAN_NUMBER_TERMINATOR  = 4,
927     /** AN @stable ICU 2.0 */
928     U_ARABIC_NUMBER               = 5,
929     /** CS @stable ICU 2.0 */
930     U_COMMON_NUMBER_SEPARATOR     = 6,
931     /** B @stable ICU 2.0 */
932     U_BLOCK_SEPARATOR             = 7,
933     /** S @stable ICU 2.0 */
934     U_SEGMENT_SEPARATOR           = 8,
935     /** WS @stable ICU 2.0 */
936     U_WHITE_SPACE_NEUTRAL         = 9,
937     /** ON @stable ICU 2.0 */
938     U_OTHER_NEUTRAL               = 10,
939     /** LRE @stable ICU 2.0 */
940     U_LEFT_TO_RIGHT_EMBEDDING     = 11,
941     /** LRO @stable ICU 2.0 */
942     U_LEFT_TO_RIGHT_OVERRIDE      = 12,
943     /** AL @stable ICU 2.0 */
944     U_RIGHT_TO_LEFT_ARABIC        = 13,
945     /** RLE @stable ICU 2.0 */
946     U_RIGHT_TO_LEFT_EMBEDDING     = 14,
947     /** RLO @stable ICU 2.0 */
948     U_RIGHT_TO_LEFT_OVERRIDE      = 15,
949     /** PDF @stable ICU 2.0 */
950     U_POP_DIRECTIONAL_FORMAT      = 16,
951     /** NSM @stable ICU 2.0 */
952     U_DIR_NON_SPACING_MARK        = 17,
953     /** BN @stable ICU 2.0 */
954     U_BOUNDARY_NEUTRAL            = 18,
955     /** FSI @stable ICU 52 */
956     U_FIRST_STRONG_ISOLATE        = 19,
957     /** LRI @stable ICU 52 */
958     U_LEFT_TO_RIGHT_ISOLATE       = 20,
959     /** RLI @stable ICU 52 */
960     U_RIGHT_TO_LEFT_ISOLATE       = 21,
961     /** PDI @stable ICU 52 */
962     U_POP_DIRECTIONAL_ISOLATE     = 22,
963 } UCharDirection;
964 
965 /**
966  * Bidi Paired Bracket Type constants.
967  *
968  * @see UCHAR_BIDI_PAIRED_BRACKET_TYPE
969  * @stable ICU 52
970  */
971 typedef enum UBidiPairedBracketType {
972     /*
973      * Note: UBidiPairedBracketType constants are parsed by preparseucd.py.
974      * It matches lines like
975      *     U_BPT_<Unicode Bidi_Paired_Bracket_Type value name>
976      */
977 
978     /** Not a paired bracket. @stable ICU 52 */
979     U_BPT_NONE,
980     /** Open paired bracket. @stable ICU 52 */
981     U_BPT_OPEN,
982     /** Close paired bracket. @stable ICU 52 */
983     U_BPT_CLOSE,
984 } UBidiPairedBracketType;
985 
986 /**
987  * Constants for Unicode blocks, see the Unicode Data file Blocks.txt
988  * @stable ICU 2.0
989  */
990 enum UBlockCode {
991     /*
992      * Note: UBlockCode constants are parsed by preparseucd.py.
993      * It matches lines like
994      *     UBLOCK_<Unicode Block value name> = <integer>,
995      */
996 
997     /** New No_Block value in Unicode 4. @stable ICU 2.6 */
998     UBLOCK_NO_BLOCK = 0, /*[none]*/ /* Special range indicating No_Block */
999 
1000     /** @stable ICU 2.0 */
1001     UBLOCK_BASIC_LATIN = 1, /*[0000]*/
1002 
1003     /** @stable ICU 2.0 */
1004     UBLOCK_LATIN_1_SUPPLEMENT=2, /*[0080]*/
1005 
1006     /** @stable ICU 2.0 */
1007     UBLOCK_LATIN_EXTENDED_A =3, /*[0100]*/
1008 
1009     /** @stable ICU 2.0 */
1010     UBLOCK_LATIN_EXTENDED_B =4, /*[0180]*/
1011 
1012     /** @stable ICU 2.0 */
1013     UBLOCK_IPA_EXTENSIONS =5, /*[0250]*/
1014 
1015     /** @stable ICU 2.0 */
1016     UBLOCK_SPACING_MODIFIER_LETTERS =6, /*[02B0]*/
1017 
1018     /** @stable ICU 2.0 */
1019     UBLOCK_COMBINING_DIACRITICAL_MARKS =7, /*[0300]*/
1020 
1021     /**
1022      * Unicode 3.2 renames this block to "Greek and Coptic".
1023      * @stable ICU 2.0
1024      */
1025     UBLOCK_GREEK =8, /*[0370]*/
1026 
1027     /** @stable ICU 2.0 */
1028     UBLOCK_CYRILLIC =9, /*[0400]*/
1029 
1030     /** @stable ICU 2.0 */
1031     UBLOCK_ARMENIAN =10, /*[0530]*/
1032 
1033     /** @stable ICU 2.0 */
1034     UBLOCK_HEBREW =11, /*[0590]*/
1035 
1036     /** @stable ICU 2.0 */
1037     UBLOCK_ARABIC =12, /*[0600]*/
1038 
1039     /** @stable ICU 2.0 */
1040     UBLOCK_SYRIAC =13, /*[0700]*/
1041 
1042     /** @stable ICU 2.0 */
1043     UBLOCK_THAANA =14, /*[0780]*/
1044 
1045     /** @stable ICU 2.0 */
1046     UBLOCK_DEVANAGARI =15, /*[0900]*/
1047 
1048     /** @stable ICU 2.0 */
1049     UBLOCK_BENGALI =16, /*[0980]*/
1050 
1051     /** @stable ICU 2.0 */
1052     UBLOCK_GURMUKHI =17, /*[0A00]*/
1053 
1054     /** @stable ICU 2.0 */
1055     UBLOCK_GUJARATI =18, /*[0A80]*/
1056 
1057     /** @stable ICU 2.0 */
1058     UBLOCK_ORIYA =19, /*[0B00]*/
1059 
1060     /** @stable ICU 2.0 */
1061     UBLOCK_TAMIL =20, /*[0B80]*/
1062 
1063     /** @stable ICU 2.0 */
1064     UBLOCK_TELUGU =21, /*[0C00]*/
1065 
1066     /** @stable ICU 2.0 */
1067     UBLOCK_KANNADA =22, /*[0C80]*/
1068 
1069     /** @stable ICU 2.0 */
1070     UBLOCK_MALAYALAM =23, /*[0D00]*/
1071 
1072     /** @stable ICU 2.0 */
1073     UBLOCK_SINHALA =24, /*[0D80]*/
1074 
1075     /** @stable ICU 2.0 */
1076     UBLOCK_THAI =25, /*[0E00]*/
1077 
1078     /** @stable ICU 2.0 */
1079     UBLOCK_LAO =26, /*[0E80]*/
1080 
1081     /** @stable ICU 2.0 */
1082     UBLOCK_TIBETAN =27, /*[0F00]*/
1083 
1084     /** @stable ICU 2.0 */
1085     UBLOCK_MYANMAR =28, /*[1000]*/
1086 
1087     /** @stable ICU 2.0 */
1088     UBLOCK_GEORGIAN =29, /*[10A0]*/
1089 
1090     /** @stable ICU 2.0 */
1091     UBLOCK_HANGUL_JAMO =30, /*[1100]*/
1092 
1093     /** @stable ICU 2.0 */
1094     UBLOCK_ETHIOPIC =31, /*[1200]*/
1095 
1096     /** @stable ICU 2.0 */
1097     UBLOCK_CHEROKEE =32, /*[13A0]*/
1098 
1099     /** @stable ICU 2.0 */
1100     UBLOCK_UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS =33, /*[1400]*/
1101 
1102     /** @stable ICU 2.0 */
1103     UBLOCK_OGHAM =34, /*[1680]*/
1104 
1105     /** @stable ICU 2.0 */
1106     UBLOCK_RUNIC =35, /*[16A0]*/
1107 
1108     /** @stable ICU 2.0 */
1109     UBLOCK_KHMER =36, /*[1780]*/
1110 
1111     /** @stable ICU 2.0 */
1112     UBLOCK_MONGOLIAN =37, /*[1800]*/
1113 
1114     /** @stable ICU 2.0 */
1115     UBLOCK_LATIN_EXTENDED_ADDITIONAL =38, /*[1E00]*/
1116 
1117     /** @stable ICU 2.0 */
1118     UBLOCK_GREEK_EXTENDED =39, /*[1F00]*/
1119 
1120     /** @stable ICU 2.0 */
1121     UBLOCK_GENERAL_PUNCTUATION =40, /*[2000]*/
1122 
1123     /** @stable ICU 2.0 */
1124     UBLOCK_SUPERSCRIPTS_AND_SUBSCRIPTS =41, /*[2070]*/
1125 
1126     /** @stable ICU 2.0 */
1127     UBLOCK_CURRENCY_SYMBOLS =42, /*[20A0]*/
1128 
1129     /**
1130      * Unicode 3.2 renames this block to "Combining Diacritical Marks for Symbols".
1131      * @stable ICU 2.0
1132      */
1133     UBLOCK_COMBINING_MARKS_FOR_SYMBOLS =43, /*[20D0]*/
1134 
1135     /** @stable ICU 2.0 */
1136     UBLOCK_LETTERLIKE_SYMBOLS =44, /*[2100]*/
1137 
1138     /** @stable ICU 2.0 */
1139     UBLOCK_NUMBER_FORMS =45, /*[2150]*/
1140 
1141     /** @stable ICU 2.0 */
1142     UBLOCK_ARROWS =46, /*[2190]*/
1143 
1144     /** @stable ICU 2.0 */
1145     UBLOCK_MATHEMATICAL_OPERATORS =47, /*[2200]*/
1146 
1147     /** @stable ICU 2.0 */
1148     UBLOCK_MISCELLANEOUS_TECHNICAL =48, /*[2300]*/
1149 
1150     /** @stable ICU 2.0 */
1151     UBLOCK_CONTROL_PICTURES =49, /*[2400]*/
1152 
1153     /** @stable ICU 2.0 */
1154     UBLOCK_OPTICAL_CHARACTER_RECOGNITION =50, /*[2440]*/
1155 
1156     /** @stable ICU 2.0 */
1157     UBLOCK_ENCLOSED_ALPHANUMERICS =51, /*[2460]*/
1158 
1159     /** @stable ICU 2.0 */
1160     UBLOCK_BOX_DRAWING =52, /*[2500]*/
1161 
1162     /** @stable ICU 2.0 */
1163     UBLOCK_BLOCK_ELEMENTS =53, /*[2580]*/
1164 
1165     /** @stable ICU 2.0 */
1166     UBLOCK_GEOMETRIC_SHAPES =54, /*[25A0]*/
1167 
1168     /** @stable ICU 2.0 */
1169     UBLOCK_MISCELLANEOUS_SYMBOLS =55, /*[2600]*/
1170 
1171     /** @stable ICU 2.0 */
1172     UBLOCK_DINGBATS =56, /*[2700]*/
1173 
1174     /** @stable ICU 2.0 */
1175     UBLOCK_BRAILLE_PATTERNS =57, /*[2800]*/
1176 
1177     /** @stable ICU 2.0 */
1178     UBLOCK_CJK_RADICALS_SUPPLEMENT =58, /*[2E80]*/
1179 
1180     /** @stable ICU 2.0 */
1181     UBLOCK_KANGXI_RADICALS =59, /*[2F00]*/
1182 
1183     /** @stable ICU 2.0 */
1184     UBLOCK_IDEOGRAPHIC_DESCRIPTION_CHARACTERS =60, /*[2FF0]*/
1185 
1186     /** @stable ICU 2.0 */
1187     UBLOCK_CJK_SYMBOLS_AND_PUNCTUATION =61, /*[3000]*/
1188 
1189     /** @stable ICU 2.0 */
1190     UBLOCK_HIRAGANA =62, /*[3040]*/
1191 
1192     /** @stable ICU 2.0 */
1193     UBLOCK_KATAKANA =63, /*[30A0]*/
1194 
1195     /** @stable ICU 2.0 */
1196     UBLOCK_BOPOMOFO =64, /*[3100]*/
1197 
1198     /** @stable ICU 2.0 */
1199     UBLOCK_HANGUL_COMPATIBILITY_JAMO =65, /*[3130]*/
1200 
1201     /** @stable ICU 2.0 */
1202     UBLOCK_KANBUN =66, /*[3190]*/
1203 
1204     /** @stable ICU 2.0 */
1205     UBLOCK_BOPOMOFO_EXTENDED =67, /*[31A0]*/
1206 
1207     /** @stable ICU 2.0 */
1208     UBLOCK_ENCLOSED_CJK_LETTERS_AND_MONTHS =68, /*[3200]*/
1209 
1210     /** @stable ICU 2.0 */
1211     UBLOCK_CJK_COMPATIBILITY =69, /*[3300]*/
1212 
1213     /** @stable ICU 2.0 */
1214     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A =70, /*[3400]*/
1215 
1216     /** @stable ICU 2.0 */
1217     UBLOCK_CJK_UNIFIED_IDEOGRAPHS =71, /*[4E00]*/
1218 
1219     /** @stable ICU 2.0 */
1220     UBLOCK_YI_SYLLABLES =72, /*[A000]*/
1221 
1222     /** @stable ICU 2.0 */
1223     UBLOCK_YI_RADICALS =73, /*[A490]*/
1224 
1225     /** @stable ICU 2.0 */
1226     UBLOCK_HANGUL_SYLLABLES =74, /*[AC00]*/
1227 
1228     /** @stable ICU 2.0 */
1229     UBLOCK_HIGH_SURROGATES =75, /*[D800]*/
1230 
1231     /** @stable ICU 2.0 */
1232     UBLOCK_HIGH_PRIVATE_USE_SURROGATES =76, /*[DB80]*/
1233 
1234     /** @stable ICU 2.0 */
1235     UBLOCK_LOW_SURROGATES =77, /*[DC00]*/
1236 
1237     /**
1238      * Same as UBLOCK_PRIVATE_USE.
1239      * Until Unicode 3.1.1, the corresponding block name was "Private Use",
1240      * and multiple code point ranges had this block.
1241      * Unicode 3.2 renames the block for the BMP PUA to "Private Use Area" and
1242      * adds separate blocks for the supplementary PUAs.
1243      *
1244      * @stable ICU 2.0
1245      */
1246     UBLOCK_PRIVATE_USE_AREA =78, /*[E000]*/
1247     /**
1248      * Same as UBLOCK_PRIVATE_USE_AREA.
1249      * Until Unicode 3.1.1, the corresponding block name was "Private Use",
1250      * and multiple code point ranges had this block.
1251      * Unicode 3.2 renames the block for the BMP PUA to "Private Use Area" and
1252      * adds separate blocks for the supplementary PUAs.
1253      *
1254      * @stable ICU 2.0
1255      */
1256     UBLOCK_PRIVATE_USE = UBLOCK_PRIVATE_USE_AREA,
1257 
1258     /** @stable ICU 2.0 */
1259     UBLOCK_CJK_COMPATIBILITY_IDEOGRAPHS =79, /*[F900]*/
1260 
1261     /** @stable ICU 2.0 */
1262     UBLOCK_ALPHABETIC_PRESENTATION_FORMS =80, /*[FB00]*/
1263 
1264     /** @stable ICU 2.0 */
1265     UBLOCK_ARABIC_PRESENTATION_FORMS_A =81, /*[FB50]*/
1266 
1267     /** @stable ICU 2.0 */
1268     UBLOCK_COMBINING_HALF_MARKS =82, /*[FE20]*/
1269 
1270     /** @stable ICU 2.0 */
1271     UBLOCK_CJK_COMPATIBILITY_FORMS =83, /*[FE30]*/
1272 
1273     /** @stable ICU 2.0 */
1274     UBLOCK_SMALL_FORM_VARIANTS =84, /*[FE50]*/
1275 
1276     /** @stable ICU 2.0 */
1277     UBLOCK_ARABIC_PRESENTATION_FORMS_B =85, /*[FE70]*/
1278 
1279     /** @stable ICU 2.0 */
1280     UBLOCK_SPECIALS =86, /*[FFF0]*/
1281 
1282     /** @stable ICU 2.0 */
1283     UBLOCK_HALFWIDTH_AND_FULLWIDTH_FORMS =87, /*[FF00]*/
1284 
1285     /* New blocks in Unicode 3.1 */
1286 
1287     /** @stable ICU 2.0 */
1288     UBLOCK_OLD_ITALIC = 88, /*[10300]*/
1289     /** @stable ICU 2.0 */
1290     UBLOCK_GOTHIC = 89, /*[10330]*/
1291     /** @stable ICU 2.0 */
1292     UBLOCK_DESERET = 90, /*[10400]*/
1293     /** @stable ICU 2.0 */
1294     UBLOCK_BYZANTINE_MUSICAL_SYMBOLS = 91, /*[1D000]*/
1295     /** @stable ICU 2.0 */
1296     UBLOCK_MUSICAL_SYMBOLS = 92, /*[1D100]*/
1297     /** @stable ICU 2.0 */
1298     UBLOCK_MATHEMATICAL_ALPHANUMERIC_SYMBOLS = 93, /*[1D400]*/
1299     /** @stable ICU 2.0 */
1300     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_B  = 94, /*[20000]*/
1301     /** @stable ICU 2.0 */
1302     UBLOCK_CJK_COMPATIBILITY_IDEOGRAPHS_SUPPLEMENT = 95, /*[2F800]*/
1303     /** @stable ICU 2.0 */
1304     UBLOCK_TAGS = 96, /*[E0000]*/
1305 
1306     /* New blocks in Unicode 3.2 */
1307 
1308     /** @stable ICU 3.0  */
1309     UBLOCK_CYRILLIC_SUPPLEMENT = 97, /*[0500]*/
1310     /**
1311      * Unicode 4.0.1 renames the "Cyrillic Supplementary" block to "Cyrillic Supplement".
1312      * @stable ICU 2.2
1313      */
1314     UBLOCK_CYRILLIC_SUPPLEMENTARY = UBLOCK_CYRILLIC_SUPPLEMENT,
1315     /** @stable ICU 2.2 */
1316     UBLOCK_TAGALOG = 98, /*[1700]*/
1317     /** @stable ICU 2.2 */
1318     UBLOCK_HANUNOO = 99, /*[1720]*/
1319     /** @stable ICU 2.2 */
1320     UBLOCK_BUHID = 100, /*[1740]*/
1321     /** @stable ICU 2.2 */
1322     UBLOCK_TAGBANWA = 101, /*[1760]*/
1323     /** @stable ICU 2.2 */
1324     UBLOCK_MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A = 102, /*[27C0]*/
1325     /** @stable ICU 2.2 */
1326     UBLOCK_SUPPLEMENTAL_ARROWS_A = 103, /*[27F0]*/
1327     /** @stable ICU 2.2 */
1328     UBLOCK_SUPPLEMENTAL_ARROWS_B = 104, /*[2900]*/
1329     /** @stable ICU 2.2 */
1330     UBLOCK_MISCELLANEOUS_MATHEMATICAL_SYMBOLS_B = 105, /*[2980]*/
1331     /** @stable ICU 2.2 */
1332     UBLOCK_SUPPLEMENTAL_MATHEMATICAL_OPERATORS = 106, /*[2A00]*/
1333     /** @stable ICU 2.2 */
1334     UBLOCK_KATAKANA_PHONETIC_EXTENSIONS = 107, /*[31F0]*/
1335     /** @stable ICU 2.2 */
1336     UBLOCK_VARIATION_SELECTORS = 108, /*[FE00]*/
1337     /** @stable ICU 2.2 */
1338     UBLOCK_SUPPLEMENTARY_PRIVATE_USE_AREA_A = 109, /*[F0000]*/
1339     /** @stable ICU 2.2 */
1340     UBLOCK_SUPPLEMENTARY_PRIVATE_USE_AREA_B = 110, /*[100000]*/
1341 
1342     /* New blocks in Unicode 4 */
1343 
1344     /** @stable ICU 2.6 */
1345     UBLOCK_LIMBU = 111, /*[1900]*/
1346     /** @stable ICU 2.6 */
1347     UBLOCK_TAI_LE = 112, /*[1950]*/
1348     /** @stable ICU 2.6 */
1349     UBLOCK_KHMER_SYMBOLS = 113, /*[19E0]*/
1350     /** @stable ICU 2.6 */
1351     UBLOCK_PHONETIC_EXTENSIONS = 114, /*[1D00]*/
1352     /** @stable ICU 2.6 */
1353     UBLOCK_MISCELLANEOUS_SYMBOLS_AND_ARROWS = 115, /*[2B00]*/
1354     /** @stable ICU 2.6 */
1355     UBLOCK_YIJING_HEXAGRAM_SYMBOLS = 116, /*[4DC0]*/
1356     /** @stable ICU 2.6 */
1357     UBLOCK_LINEAR_B_SYLLABARY = 117, /*[10000]*/
1358     /** @stable ICU 2.6 */
1359     UBLOCK_LINEAR_B_IDEOGRAMS = 118, /*[10080]*/
1360     /** @stable ICU 2.6 */
1361     UBLOCK_AEGEAN_NUMBERS = 119, /*[10100]*/
1362     /** @stable ICU 2.6 */
1363     UBLOCK_UGARITIC = 120, /*[10380]*/
1364     /** @stable ICU 2.6 */
1365     UBLOCK_SHAVIAN = 121, /*[10450]*/
1366     /** @stable ICU 2.6 */
1367     UBLOCK_OSMANYA = 122, /*[10480]*/
1368     /** @stable ICU 2.6 */
1369     UBLOCK_CYPRIOT_SYLLABARY = 123, /*[10800]*/
1370     /** @stable ICU 2.6 */
1371     UBLOCK_TAI_XUAN_JING_SYMBOLS = 124, /*[1D300]*/
1372     /** @stable ICU 2.6 */
1373     UBLOCK_VARIATION_SELECTORS_SUPPLEMENT = 125, /*[E0100]*/
1374 
1375     /* New blocks in Unicode 4.1 */
1376 
1377     /** @stable ICU 3.4 */
1378     UBLOCK_ANCIENT_GREEK_MUSICAL_NOTATION = 126, /*[1D200]*/
1379     /** @stable ICU 3.4 */
1380     UBLOCK_ANCIENT_GREEK_NUMBERS = 127, /*[10140]*/
1381     /** @stable ICU 3.4 */
1382     UBLOCK_ARABIC_SUPPLEMENT = 128, /*[0750]*/
1383     /** @stable ICU 3.4 */
1384     UBLOCK_BUGINESE = 129, /*[1A00]*/
1385     /** @stable ICU 3.4 */
1386     UBLOCK_CJK_STROKES = 130, /*[31C0]*/
1387     /** @stable ICU 3.4 */
1388     UBLOCK_COMBINING_DIACRITICAL_MARKS_SUPPLEMENT = 131, /*[1DC0]*/
1389     /** @stable ICU 3.4 */
1390     UBLOCK_COPTIC = 132, /*[2C80]*/
1391     /** @stable ICU 3.4 */
1392     UBLOCK_ETHIOPIC_EXTENDED = 133, /*[2D80]*/
1393     /** @stable ICU 3.4 */
1394     UBLOCK_ETHIOPIC_SUPPLEMENT = 134, /*[1380]*/
1395     /** @stable ICU 3.4 */
1396     UBLOCK_GEORGIAN_SUPPLEMENT = 135, /*[2D00]*/
1397     /** @stable ICU 3.4 */
1398     UBLOCK_GLAGOLITIC = 136, /*[2C00]*/
1399     /** @stable ICU 3.4 */
1400     UBLOCK_KHAROSHTHI = 137, /*[10A00]*/
1401     /** @stable ICU 3.4 */
1402     UBLOCK_MODIFIER_TONE_LETTERS = 138, /*[A700]*/
1403     /** @stable ICU 3.4 */
1404     UBLOCK_NEW_TAI_LUE = 139, /*[1980]*/
1405     /** @stable ICU 3.4 */
1406     UBLOCK_OLD_PERSIAN = 140, /*[103A0]*/
1407     /** @stable ICU 3.4 */
1408     UBLOCK_PHONETIC_EXTENSIONS_SUPPLEMENT = 141, /*[1D80]*/
1409     /** @stable ICU 3.4 */
1410     UBLOCK_SUPPLEMENTAL_PUNCTUATION = 142, /*[2E00]*/
1411     /** @stable ICU 3.4 */
1412     UBLOCK_SYLOTI_NAGRI = 143, /*[A800]*/
1413     /** @stable ICU 3.4 */
1414     UBLOCK_TIFINAGH = 144, /*[2D30]*/
1415     /** @stable ICU 3.4 */
1416     UBLOCK_VERTICAL_FORMS = 145, /*[FE10]*/
1417 
1418     /* New blocks in Unicode 5.0 */
1419 
1420     /** @stable ICU 3.6 */
1421     UBLOCK_NKO = 146, /*[07C0]*/
1422     /** @stable ICU 3.6 */
1423     UBLOCK_BALINESE = 147, /*[1B00]*/
1424     /** @stable ICU 3.6 */
1425     UBLOCK_LATIN_EXTENDED_C = 148, /*[2C60]*/
1426     /** @stable ICU 3.6 */
1427     UBLOCK_LATIN_EXTENDED_D = 149, /*[A720]*/
1428     /** @stable ICU 3.6 */
1429     UBLOCK_PHAGS_PA = 150, /*[A840]*/
1430     /** @stable ICU 3.6 */
1431     UBLOCK_PHOENICIAN = 151, /*[10900]*/
1432     /** @stable ICU 3.6 */
1433     UBLOCK_CUNEIFORM = 152, /*[12000]*/
1434     /** @stable ICU 3.6 */
1435     UBLOCK_CUNEIFORM_NUMBERS_AND_PUNCTUATION = 153, /*[12400]*/
1436     /** @stable ICU 3.6 */
1437     UBLOCK_COUNTING_ROD_NUMERALS = 154, /*[1D360]*/
1438 
1439     /* New blocks in Unicode 5.1 */
1440 
1441     /** @stable ICU 4.0 */
1442     UBLOCK_SUNDANESE = 155, /*[1B80]*/
1443     /** @stable ICU 4.0 */
1444     UBLOCK_LEPCHA = 156, /*[1C00]*/
1445     /** @stable ICU 4.0 */
1446     UBLOCK_OL_CHIKI = 157, /*[1C50]*/
1447     /** @stable ICU 4.0 */
1448     UBLOCK_CYRILLIC_EXTENDED_A = 158, /*[2DE0]*/
1449     /** @stable ICU 4.0 */
1450     UBLOCK_VAI = 159, /*[A500]*/
1451     /** @stable ICU 4.0 */
1452     UBLOCK_CYRILLIC_EXTENDED_B = 160, /*[A640]*/
1453     /** @stable ICU 4.0 */
1454     UBLOCK_SAURASHTRA = 161, /*[A880]*/
1455     /** @stable ICU 4.0 */
1456     UBLOCK_KAYAH_LI = 162, /*[A900]*/
1457     /** @stable ICU 4.0 */
1458     UBLOCK_REJANG = 163, /*[A930]*/
1459     /** @stable ICU 4.0 */
1460     UBLOCK_CHAM = 164, /*[AA00]*/
1461     /** @stable ICU 4.0 */
1462     UBLOCK_ANCIENT_SYMBOLS = 165, /*[10190]*/
1463     /** @stable ICU 4.0 */
1464     UBLOCK_PHAISTOS_DISC = 166, /*[101D0]*/
1465     /** @stable ICU 4.0 */
1466     UBLOCK_LYCIAN = 167, /*[10280]*/
1467     /** @stable ICU 4.0 */
1468     UBLOCK_CARIAN = 168, /*[102A0]*/
1469     /** @stable ICU 4.0 */
1470     UBLOCK_LYDIAN = 169, /*[10920]*/
1471     /** @stable ICU 4.0 */
1472     UBLOCK_MAHJONG_TILES = 170, /*[1F000]*/
1473     /** @stable ICU 4.0 */
1474     UBLOCK_DOMINO_TILES = 171, /*[1F030]*/
1475 
1476     /* New blocks in Unicode 5.2 */
1477 
1478     /** @stable ICU 4.4 */
1479     UBLOCK_SAMARITAN = 172, /*[0800]*/
1480     /** @stable ICU 4.4 */
1481     UBLOCK_UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS_EXTENDED = 173, /*[18B0]*/
1482     /** @stable ICU 4.4 */
1483     UBLOCK_TAI_THAM = 174, /*[1A20]*/
1484     /** @stable ICU 4.4 */
1485     UBLOCK_VEDIC_EXTENSIONS = 175, /*[1CD0]*/
1486     /** @stable ICU 4.4 */
1487     UBLOCK_LISU = 176, /*[A4D0]*/
1488     /** @stable ICU 4.4 */
1489     UBLOCK_BAMUM = 177, /*[A6A0]*/
1490     /** @stable ICU 4.4 */
1491     UBLOCK_COMMON_INDIC_NUMBER_FORMS = 178, /*[A830]*/
1492     /** @stable ICU 4.4 */
1493     UBLOCK_DEVANAGARI_EXTENDED = 179, /*[A8E0]*/
1494     /** @stable ICU 4.4 */
1495     UBLOCK_HANGUL_JAMO_EXTENDED_A = 180, /*[A960]*/
1496     /** @stable ICU 4.4 */
1497     UBLOCK_JAVANESE = 181, /*[A980]*/
1498     /** @stable ICU 4.4 */
1499     UBLOCK_MYANMAR_EXTENDED_A = 182, /*[AA60]*/
1500     /** @stable ICU 4.4 */
1501     UBLOCK_TAI_VIET = 183, /*[AA80]*/
1502     /** @stable ICU 4.4 */
1503     UBLOCK_MEETEI_MAYEK = 184, /*[ABC0]*/
1504     /** @stable ICU 4.4 */
1505     UBLOCK_HANGUL_JAMO_EXTENDED_B = 185, /*[D7B0]*/
1506     /** @stable ICU 4.4 */
1507     UBLOCK_IMPERIAL_ARAMAIC = 186, /*[10840]*/
1508     /** @stable ICU 4.4 */
1509     UBLOCK_OLD_SOUTH_ARABIAN = 187, /*[10A60]*/
1510     /** @stable ICU 4.4 */
1511     UBLOCK_AVESTAN = 188, /*[10B00]*/
1512     /** @stable ICU 4.4 */
1513     UBLOCK_INSCRIPTIONAL_PARTHIAN = 189, /*[10B40]*/
1514     /** @stable ICU 4.4 */
1515     UBLOCK_INSCRIPTIONAL_PAHLAVI = 190, /*[10B60]*/
1516     /** @stable ICU 4.4 */
1517     UBLOCK_OLD_TURKIC = 191, /*[10C00]*/
1518     /** @stable ICU 4.4 */
1519     UBLOCK_RUMI_NUMERAL_SYMBOLS = 192, /*[10E60]*/
1520     /** @stable ICU 4.4 */
1521     UBLOCK_KAITHI = 193, /*[11080]*/
1522     /** @stable ICU 4.4 */
1523     UBLOCK_EGYPTIAN_HIEROGLYPHS = 194, /*[13000]*/
1524     /** @stable ICU 4.4 */
1525     UBLOCK_ENCLOSED_ALPHANUMERIC_SUPPLEMENT = 195, /*[1F100]*/
1526     /** @stable ICU 4.4 */
1527     UBLOCK_ENCLOSED_IDEOGRAPHIC_SUPPLEMENT = 196, /*[1F200]*/
1528     /** @stable ICU 4.4 */
1529     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_C = 197, /*[2A700]*/
1530 
1531     /* New blocks in Unicode 6.0 */
1532 
1533     /** @stable ICU 4.6 */
1534     UBLOCK_MANDAIC = 198, /*[0840]*/
1535     /** @stable ICU 4.6 */
1536     UBLOCK_BATAK = 199, /*[1BC0]*/
1537     /** @stable ICU 4.6 */
1538     UBLOCK_ETHIOPIC_EXTENDED_A = 200, /*[AB00]*/
1539     /** @stable ICU 4.6 */
1540     UBLOCK_BRAHMI = 201, /*[11000]*/
1541     /** @stable ICU 4.6 */
1542     UBLOCK_BAMUM_SUPPLEMENT = 202, /*[16800]*/
1543     /** @stable ICU 4.6 */
1544     UBLOCK_KANA_SUPPLEMENT = 203, /*[1B000]*/
1545     /** @stable ICU 4.6 */
1546     UBLOCK_PLAYING_CARDS = 204, /*[1F0A0]*/
1547     /** @stable ICU 4.6 */
1548     UBLOCK_MISCELLANEOUS_SYMBOLS_AND_PICTOGRAPHS = 205, /*[1F300]*/
1549     /** @stable ICU 4.6 */
1550     UBLOCK_EMOTICONS = 206, /*[1F600]*/
1551     /** @stable ICU 4.6 */
1552     UBLOCK_TRANSPORT_AND_MAP_SYMBOLS = 207, /*[1F680]*/
1553     /** @stable ICU 4.6 */
1554     UBLOCK_ALCHEMICAL_SYMBOLS = 208, /*[1F700]*/
1555     /** @stable ICU 4.6 */
1556     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_D = 209, /*[2B740]*/
1557 
1558     /* New blocks in Unicode 6.1 */
1559 
1560     /** @stable ICU 49 */
1561     UBLOCK_ARABIC_EXTENDED_A = 210, /*[08A0]*/
1562     /** @stable ICU 49 */
1563     UBLOCK_ARABIC_MATHEMATICAL_ALPHABETIC_SYMBOLS = 211, /*[1EE00]*/
1564     /** @stable ICU 49 */
1565     UBLOCK_CHAKMA = 212, /*[11100]*/
1566     /** @stable ICU 49 */
1567     UBLOCK_MEETEI_MAYEK_EXTENSIONS = 213, /*[AAE0]*/
1568     /** @stable ICU 49 */
1569     UBLOCK_MEROITIC_CURSIVE = 214, /*[109A0]*/
1570     /** @stable ICU 49 */
1571     UBLOCK_MEROITIC_HIEROGLYPHS = 215, /*[10980]*/
1572     /** @stable ICU 49 */
1573     UBLOCK_MIAO = 216, /*[16F00]*/
1574     /** @stable ICU 49 */
1575     UBLOCK_SHARADA = 217, /*[11180]*/
1576     /** @stable ICU 49 */
1577     UBLOCK_SORA_SOMPENG = 218, /*[110D0]*/
1578     /** @stable ICU 49 */
1579     UBLOCK_SUNDANESE_SUPPLEMENT = 219, /*[1CC0]*/
1580     /** @stable ICU 49 */
1581     UBLOCK_TAKRI = 220, /*[11680]*/
1582 
1583     /* New blocks in Unicode 7.0 */
1584 
1585     /** @stable ICU 54 */
1586     UBLOCK_BASSA_VAH = 221, /*[16AD0]*/
1587     /** @stable ICU 54 */
1588     UBLOCK_CAUCASIAN_ALBANIAN = 222, /*[10530]*/
1589     /** @stable ICU 54 */
1590     UBLOCK_COPTIC_EPACT_NUMBERS = 223, /*[102E0]*/
1591     /** @stable ICU 54 */
1592     UBLOCK_COMBINING_DIACRITICAL_MARKS_EXTENDED = 224, /*[1AB0]*/
1593     /** @stable ICU 54 */
1594     UBLOCK_DUPLOYAN = 225, /*[1BC00]*/
1595     /** @stable ICU 54 */
1596     UBLOCK_ELBASAN = 226, /*[10500]*/
1597     /** @stable ICU 54 */
1598     UBLOCK_GEOMETRIC_SHAPES_EXTENDED = 227, /*[1F780]*/
1599     /** @stable ICU 54 */
1600     UBLOCK_GRANTHA = 228, /*[11300]*/
1601     /** @stable ICU 54 */
1602     UBLOCK_KHOJKI = 229, /*[11200]*/
1603     /** @stable ICU 54 */
1604     UBLOCK_KHUDAWADI = 230, /*[112B0]*/
1605     /** @stable ICU 54 */
1606     UBLOCK_LATIN_EXTENDED_E = 231, /*[AB30]*/
1607     /** @stable ICU 54 */
1608     UBLOCK_LINEAR_A = 232, /*[10600]*/
1609     /** @stable ICU 54 */
1610     UBLOCK_MAHAJANI = 233, /*[11150]*/
1611     /** @stable ICU 54 */
1612     UBLOCK_MANICHAEAN = 234, /*[10AC0]*/
1613     /** @stable ICU 54 */
1614     UBLOCK_MENDE_KIKAKUI = 235, /*[1E800]*/
1615     /** @stable ICU 54 */
1616     UBLOCK_MODI = 236, /*[11600]*/
1617     /** @stable ICU 54 */
1618     UBLOCK_MRO = 237, /*[16A40]*/
1619     /** @stable ICU 54 */
1620     UBLOCK_MYANMAR_EXTENDED_B = 238, /*[A9E0]*/
1621     /** @stable ICU 54 */
1622     UBLOCK_NABATAEAN = 239, /*[10880]*/
1623     /** @stable ICU 54 */
1624     UBLOCK_OLD_NORTH_ARABIAN = 240, /*[10A80]*/
1625     /** @stable ICU 54 */
1626     UBLOCK_OLD_PERMIC = 241, /*[10350]*/
1627     /** @stable ICU 54 */
1628     UBLOCK_ORNAMENTAL_DINGBATS = 242, /*[1F650]*/
1629     /** @stable ICU 54 */
1630     UBLOCK_PAHAWH_HMONG = 243, /*[16B00]*/
1631     /** @stable ICU 54 */
1632     UBLOCK_PALMYRENE = 244, /*[10860]*/
1633     /** @stable ICU 54 */
1634     UBLOCK_PAU_CIN_HAU = 245, /*[11AC0]*/
1635     /** @stable ICU 54 */
1636     UBLOCK_PSALTER_PAHLAVI = 246, /*[10B80]*/
1637     /** @stable ICU 54 */
1638     UBLOCK_SHORTHAND_FORMAT_CONTROLS = 247, /*[1BCA0]*/
1639     /** @stable ICU 54 */
1640     UBLOCK_SIDDHAM = 248, /*[11580]*/
1641     /** @stable ICU 54 */
1642     UBLOCK_SINHALA_ARCHAIC_NUMBERS = 249, /*[111E0]*/
1643     /** @stable ICU 54 */
1644     UBLOCK_SUPPLEMENTAL_ARROWS_C = 250, /*[1F800]*/
1645     /** @stable ICU 54 */
1646     UBLOCK_TIRHUTA = 251, /*[11480]*/
1647     /** @stable ICU 54 */
1648     UBLOCK_WARANG_CITI = 252, /*[118A0]*/
1649 
1650     /* New blocks in Unicode 8.0 */
1651 
1652     /** @stable ICU 56 */
1653     UBLOCK_AHOM = 253, /*[11700]*/
1654     /** @stable ICU 56 */
1655     UBLOCK_ANATOLIAN_HIEROGLYPHS = 254, /*[14400]*/
1656     /** @stable ICU 56 */
1657     UBLOCK_CHEROKEE_SUPPLEMENT = 255, /*[AB70]*/
1658     /** @stable ICU 56 */
1659     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_E = 256, /*[2B820]*/
1660     /** @stable ICU 56 */
1661     UBLOCK_EARLY_DYNASTIC_CUNEIFORM = 257, /*[12480]*/
1662     /** @stable ICU 56 */
1663     UBLOCK_HATRAN = 258, /*[108E0]*/
1664     /** @stable ICU 56 */
1665     UBLOCK_MULTANI = 259, /*[11280]*/
1666     /** @stable ICU 56 */
1667     UBLOCK_OLD_HUNGARIAN = 260, /*[10C80]*/
1668     /** @stable ICU 56 */
1669     UBLOCK_SUPPLEMENTAL_SYMBOLS_AND_PICTOGRAPHS = 261, /*[1F900]*/
1670     /** @stable ICU 56 */
1671     UBLOCK_SUTTON_SIGNWRITING = 262, /*[1D800]*/
1672 
1673     /* New blocks in Unicode 9.0 */
1674 
1675     /** @stable ICU 58 */
1676     UBLOCK_ADLAM = 263, /*[1E900]*/
1677     /** @stable ICU 58 */
1678     UBLOCK_BHAIKSUKI = 264, /*[11C00]*/
1679     /** @stable ICU 58 */
1680     UBLOCK_CYRILLIC_EXTENDED_C = 265, /*[1C80]*/
1681     /** @stable ICU 58 */
1682     UBLOCK_GLAGOLITIC_SUPPLEMENT = 266, /*[1E000]*/
1683     /** @stable ICU 58 */
1684     UBLOCK_IDEOGRAPHIC_SYMBOLS_AND_PUNCTUATION = 267, /*[16FE0]*/
1685     /** @stable ICU 58 */
1686     UBLOCK_MARCHEN = 268, /*[11C70]*/
1687     /** @stable ICU 58 */
1688     UBLOCK_MONGOLIAN_SUPPLEMENT = 269, /*[11660]*/
1689     /** @stable ICU 58 */
1690     UBLOCK_NEWA = 270, /*[11400]*/
1691     /** @stable ICU 58 */
1692     UBLOCK_OSAGE = 271, /*[104B0]*/
1693     /** @stable ICU 58 */
1694     UBLOCK_TANGUT = 272, /*[17000]*/
1695     /** @stable ICU 58 */
1696     UBLOCK_TANGUT_COMPONENTS = 273, /*[18800]*/
1697 
1698     // New blocks in Unicode 10.0
1699 
1700     /** @stable ICU 60 */
1701     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_F = 274, /*[2CEB0]*/
1702     /** @stable ICU 60 */
1703     UBLOCK_KANA_EXTENDED_A = 275, /*[1B100]*/
1704     /** @stable ICU 60 */
1705     UBLOCK_MASARAM_GONDI = 276, /*[11D00]*/
1706     /** @stable ICU 60 */
1707     UBLOCK_NUSHU = 277, /*[1B170]*/
1708     /** @stable ICU 60 */
1709     UBLOCK_SOYOMBO = 278, /*[11A50]*/
1710     /** @stable ICU 60 */
1711     UBLOCK_SYRIAC_SUPPLEMENT = 279, /*[0860]*/
1712     /** @stable ICU 60 */
1713     UBLOCK_ZANABAZAR_SQUARE = 280, /*[11A00]*/
1714 
1715     // New blocks in Unicode 11.0
1716 
1717     /** @stable ICU 62 */
1718     UBLOCK_CHESS_SYMBOLS = 281, /*[1FA00]*/
1719     /** @stable ICU 62 */
1720     UBLOCK_DOGRA = 282, /*[11800]*/
1721     /** @stable ICU 62 */
1722     UBLOCK_GEORGIAN_EXTENDED = 283, /*[1C90]*/
1723     /** @stable ICU 62 */
1724     UBLOCK_GUNJALA_GONDI = 284, /*[11D60]*/
1725     /** @stable ICU 62 */
1726     UBLOCK_HANIFI_ROHINGYA = 285, /*[10D00]*/
1727     /** @stable ICU 62 */
1728     UBLOCK_INDIC_SIYAQ_NUMBERS = 286, /*[1EC70]*/
1729     /** @stable ICU 62 */
1730     UBLOCK_MAKASAR = 287, /*[11EE0]*/
1731     /** @stable ICU 62 */
1732     UBLOCK_MAYAN_NUMERALS = 288, /*[1D2E0]*/
1733     /** @stable ICU 62 */
1734     UBLOCK_MEDEFAIDRIN = 289, /*[16E40]*/
1735     /** @stable ICU 62 */
1736     UBLOCK_OLD_SOGDIAN = 290, /*[10F00]*/
1737     /** @stable ICU 62 */
1738     UBLOCK_SOGDIAN = 291, /*[10F30]*/
1739 
1740     // New blocks in Unicode 12.0
1741 
1742     /** @stable ICU 64 */
1743     UBLOCK_EGYPTIAN_HIEROGLYPH_FORMAT_CONTROLS = 292, /*[13430]*/
1744     /** @stable ICU 64 */
1745     UBLOCK_ELYMAIC = 293, /*[10FE0]*/
1746     /** @stable ICU 64 */
1747     UBLOCK_NANDINAGARI = 294, /*[119A0]*/
1748     /** @stable ICU 64 */
1749     UBLOCK_NYIAKENG_PUACHUE_HMONG = 295, /*[1E100]*/
1750     /** @stable ICU 64 */
1751     UBLOCK_OTTOMAN_SIYAQ_NUMBERS = 296, /*[1ED00]*/
1752     /** @stable ICU 64 */
1753     UBLOCK_SMALL_KANA_EXTENSION = 297, /*[1B130]*/
1754     /** @stable ICU 64 */
1755     UBLOCK_SYMBOLS_AND_PICTOGRAPHS_EXTENDED_A = 298, /*[1FA70]*/
1756     /** @stable ICU 64 */
1757     UBLOCK_TAMIL_SUPPLEMENT = 299, /*[11FC0]*/
1758     /** @stable ICU 64 */
1759     UBLOCK_WANCHO = 300, /*[1E2C0]*/
1760 
1761     // New blocks in Unicode 13.0
1762 
1763     /** @stable ICU 66 */
1764     UBLOCK_CHORASMIAN = 301, /*[10FB0]*/
1765     /** @stable ICU 66 */
1766     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_G = 302, /*[30000]*/
1767     /** @stable ICU 66 */
1768     UBLOCK_DIVES_AKURU = 303, /*[11900]*/
1769     /** @stable ICU 66 */
1770     UBLOCK_KHITAN_SMALL_SCRIPT = 304, /*[18B00]*/
1771     /** @stable ICU 66 */
1772     UBLOCK_LISU_SUPPLEMENT = 305, /*[11FB0]*/
1773     /** @stable ICU 66 */
1774     UBLOCK_SYMBOLS_FOR_LEGACY_COMPUTING = 306, /*[1FB00]*/
1775     /** @stable ICU 66 */
1776     UBLOCK_TANGUT_SUPPLEMENT = 307, /*[18D00]*/
1777     /** @stable ICU 66 */
1778     UBLOCK_YEZIDI = 308, /*[10E80]*/
1779 
1780     // New blocks in Unicode 14.0
1781 
1782     /** @stable ICU 70 */
1783     UBLOCK_ARABIC_EXTENDED_B = 309, /*[0870]*/
1784     /** @stable ICU 70 */
1785     UBLOCK_CYPRO_MINOAN = 310, /*[12F90]*/
1786     /** @stable ICU 70 */
1787     UBLOCK_ETHIOPIC_EXTENDED_B = 311, /*[1E7E0]*/
1788     /** @stable ICU 70 */
1789     UBLOCK_KANA_EXTENDED_B = 312, /*[1AFF0]*/
1790     /** @stable ICU 70 */
1791     UBLOCK_LATIN_EXTENDED_F = 313, /*[10780]*/
1792     /** @stable ICU 70 */
1793     UBLOCK_LATIN_EXTENDED_G = 314, /*[1DF00]*/
1794     /** @stable ICU 70 */
1795     UBLOCK_OLD_UYGHUR = 315, /*[10F70]*/
1796     /** @stable ICU 70 */
1797     UBLOCK_TANGSA = 316, /*[16A70]*/
1798     /** @stable ICU 70 */
1799     UBLOCK_TOTO = 317, /*[1E290]*/
1800     /** @stable ICU 70 */
1801     UBLOCK_UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS_EXTENDED_A = 318, /*[11AB0]*/
1802     /** @stable ICU 70 */
1803     UBLOCK_VITHKUQI = 319, /*[10570]*/
1804     /** @stable ICU 70 */
1805     UBLOCK_ZNAMENNY_MUSICAL_NOTATION = 320, /*[1CF00]*/
1806 
1807     // New blocks in Unicode 15.0
1808 
1809     /** @stable ICU 72 */
1810     UBLOCK_ARABIC_EXTENDED_C = 321, /*[10EC0]*/
1811     /** @stable ICU 72 */
1812     UBLOCK_CJK_UNIFIED_IDEOGRAPHS_EXTENSION_H = 322, /*[31350]*/
1813     /** @stable ICU 72 */
1814     UBLOCK_CYRILLIC_EXTENDED_D = 323, /*[1E030]*/
1815     /** @stable ICU 72 */
1816     UBLOCK_DEVANAGARI_EXTENDED_A = 324, /*[11B00]*/
1817     /** @stable ICU 72 */
1818     UBLOCK_KAKTOVIK_NUMERALS = 325, /*[1D2C0]*/
1819     /** @stable ICU 72 */
1820     UBLOCK_KAWI = 326, /*[11F00]*/
1821     /** @stable ICU 72 */
1822     UBLOCK_NAG_MUNDARI = 327, /*[1E4D0]*/
1823     /** @stable ICU 2.0 */
1824     UBLOCK_INVALID_CODE=-1
1825 };
1826 
1827 /** @stable ICU 2.0 */
1828 typedef enum UBlockCode UBlockCode;
1829 
1830 /**
1831  * East Asian Width constants.
1832  *
1833  * @see UCHAR_EAST_ASIAN_WIDTH
1834  * @see u_getIntPropertyValue
1835  * @stable ICU 2.2
1836  */
1837 typedef enum UEastAsianWidth {
1838     /*
1839      * Note: UEastAsianWidth constants are parsed by preparseucd.py.
1840      * It matches lines like
1841      *     U_EA_<Unicode East_Asian_Width value name>
1842      */
1843 
1844     U_EA_NEUTRAL,   /*[N]*/
1845     U_EA_AMBIGUOUS, /*[A]*/
1846     U_EA_HALFWIDTH, /*[H]*/
1847     U_EA_FULLWIDTH, /*[F]*/
1848     U_EA_NARROW,    /*[Na]*/
1849     U_EA_WIDE,      /*[W]*/
1850 } UEastAsianWidth;
1851 
1852 /**
1853  * Selector constants for u_charName().
1854  * u_charName() returns the "modern" name of a
1855  * Unicode character; or the name that was defined in
1856  * Unicode version 1.0, before the Unicode standard merged
1857  * with ISO-10646; or an "extended" name that gives each
1858  * Unicode code point a unique name.
1859  *
1860  * @see u_charName
1861  * @stable ICU 2.0
1862  */
1863 typedef enum UCharNameChoice {
1864     /** Unicode character name (Name property). @stable ICU 2.0 */
1865     U_UNICODE_CHAR_NAME,
1866     /** Standard or synthetic character name. @stable ICU 2.0 */
1867     U_EXTENDED_CHAR_NAME = U_UNICODE_CHAR_NAME+2,
1868     /** Corrected name from NameAliases.txt. @stable ICU 4.4 */
1869     U_CHAR_NAME_ALIAS,
1870 } UCharNameChoice;
1871 
1872 /**
1873  * Selector constants for u_getPropertyName() and
1874  * u_getPropertyValueName().  These selectors are used to choose which
1875  * name is returned for a given property or value.  All properties and
1876  * values have a long name.  Most have a short name, but some do not.
1877  * Unicode allows for additional names, beyond the long and short
1878  * name, which would be indicated by U_LONG_PROPERTY_NAME + i, where
1879  * i=1, 2,...
1880  *
1881  * @see u_getPropertyName()
1882  * @see u_getPropertyValueName()
1883  * @stable ICU 2.4
1884  */
1885 typedef enum UPropertyNameChoice {
1886     U_SHORT_PROPERTY_NAME,
1887     U_LONG_PROPERTY_NAME,
1888 } UPropertyNameChoice;
1889 
1890 /**
1891  * Decomposition Type constants.
1892  *
1893  * @see UCHAR_DECOMPOSITION_TYPE
1894  * @stable ICU 2.2
1895  */
1896 typedef enum UDecompositionType {
1897     /*
1898      * Note: UDecompositionType constants are parsed by preparseucd.py.
1899      * It matches lines like
1900      *     U_DT_<Unicode Decomposition_Type value name>
1901      */
1902 
1903     U_DT_NONE,              /*[none]*/
1904     U_DT_CANONICAL,         /*[can]*/
1905     U_DT_COMPAT,            /*[com]*/
1906     U_DT_CIRCLE,            /*[enc]*/
1907     U_DT_FINAL,             /*[fin]*/
1908     U_DT_FONT,              /*[font]*/
1909     U_DT_FRACTION,          /*[fra]*/
1910     U_DT_INITIAL,           /*[init]*/
1911     U_DT_ISOLATED,          /*[iso]*/
1912     U_DT_MEDIAL,            /*[med]*/
1913     U_DT_NARROW,            /*[nar]*/
1914     U_DT_NOBREAK,           /*[nb]*/
1915     U_DT_SMALL,             /*[sml]*/
1916     U_DT_SQUARE,            /*[sqr]*/
1917     U_DT_SUB,               /*[sub]*/
1918     U_DT_SUPER,             /*[sup]*/
1919     U_DT_VERTICAL,          /*[vert]*/
1920     U_DT_WIDE,              /*[wide]*/
1921 } UDecompositionType;
1922 
1923 /**
1924  * Joining Type constants.
1925  *
1926  * @see UCHAR_JOINING_TYPE
1927  * @stable ICU 2.2
1928  */
1929 typedef enum UJoiningType {
1930     /*
1931      * Note: UJoiningType constants are parsed by preparseucd.py.
1932      * It matches lines like
1933      *     U_JT_<Unicode Joining_Type value name>
1934      */
1935 
1936     U_JT_NON_JOINING,       /*[U]*/
1937     U_JT_JOIN_CAUSING,      /*[C]*/
1938     U_JT_DUAL_JOINING,      /*[D]*/
1939     U_JT_LEFT_JOINING,      /*[L]*/
1940     U_JT_RIGHT_JOINING,     /*[R]*/
1941     U_JT_TRANSPARENT,       /*[T]*/
1942 } UJoiningType;
1943 
1944 /**
1945  * Joining Group constants.
1946  *
1947  * @see UCHAR_JOINING_GROUP
1948  * @stable ICU 2.2
1949  */
1950 typedef enum UJoiningGroup {
1951     /*
1952      * Note: UJoiningGroup constants are parsed by preparseucd.py.
1953      * It matches lines like
1954      *     U_JG_<Unicode Joining_Group value name>
1955      */
1956 
1957     U_JG_NO_JOINING_GROUP,
1958     U_JG_AIN,
1959     U_JG_ALAPH,
1960     U_JG_ALEF,
1961     U_JG_BEH,
1962     U_JG_BETH,
1963     U_JG_DAL,
1964     U_JG_DALATH_RISH,
1965     U_JG_E,
1966     U_JG_FEH,
1967     U_JG_FINAL_SEMKATH,
1968     U_JG_GAF,
1969     U_JG_GAMAL,
1970     U_JG_HAH,
1971     U_JG_TEH_MARBUTA_GOAL,  /**< @stable ICU 4.6 */
1972     U_JG_HAMZA_ON_HEH_GOAL=U_JG_TEH_MARBUTA_GOAL,
1973     U_JG_HE,
1974     U_JG_HEH,
1975     U_JG_HEH_GOAL,
1976     U_JG_HETH,
1977     U_JG_KAF,
1978     U_JG_KAPH,
1979     U_JG_KNOTTED_HEH,
1980     U_JG_LAM,
1981     U_JG_LAMADH,
1982     U_JG_MEEM,
1983     U_JG_MIM,
1984     U_JG_NOON,
1985     U_JG_NUN,
1986     U_JG_PE,
1987     U_JG_QAF,
1988     U_JG_QAPH,
1989     U_JG_REH,
1990     U_JG_REVERSED_PE,
1991     U_JG_SAD,
1992     U_JG_SADHE,
1993     U_JG_SEEN,
1994     U_JG_SEMKATH,
1995     U_JG_SHIN,
1996     U_JG_SWASH_KAF,
1997     U_JG_SYRIAC_WAW,
1998     U_JG_TAH,
1999     U_JG_TAW,
2000     U_JG_TEH_MARBUTA,
2001     U_JG_TETH,
2002     U_JG_WAW,
2003     U_JG_YEH,
2004     U_JG_YEH_BARREE,
2005     U_JG_YEH_WITH_TAIL,
2006     U_JG_YUDH,
2007     U_JG_YUDH_HE,
2008     U_JG_ZAIN,
2009     U_JG_FE,        /**< @stable ICU 2.6 */
2010     U_JG_KHAPH,     /**< @stable ICU 2.6 */
2011     U_JG_ZHAIN,     /**< @stable ICU 2.6 */
2012     U_JG_BURUSHASKI_YEH_BARREE, /**< @stable ICU 4.0 */
2013     U_JG_FARSI_YEH, /**< @stable ICU 4.4 */
2014     U_JG_NYA,       /**< @stable ICU 4.4 */
2015     U_JG_ROHINGYA_YEH,  /**< @stable ICU 49 */
2016     U_JG_MANICHAEAN_ALEPH,  /**< @stable ICU 54 */
2017     U_JG_MANICHAEAN_AYIN,  /**< @stable ICU 54 */
2018     U_JG_MANICHAEAN_BETH,  /**< @stable ICU 54 */
2019     U_JG_MANICHAEAN_DALETH,  /**< @stable ICU 54 */
2020     U_JG_MANICHAEAN_DHAMEDH,  /**< @stable ICU 54 */
2021     U_JG_MANICHAEAN_FIVE,  /**< @stable ICU 54 */
2022     U_JG_MANICHAEAN_GIMEL,  /**< @stable ICU 54 */
2023     U_JG_MANICHAEAN_HETH,  /**< @stable ICU 54 */
2024     U_JG_MANICHAEAN_HUNDRED,  /**< @stable ICU 54 */
2025     U_JG_MANICHAEAN_KAPH,  /**< @stable ICU 54 */
2026     U_JG_MANICHAEAN_LAMEDH,  /**< @stable ICU 54 */
2027     U_JG_MANICHAEAN_MEM,  /**< @stable ICU 54 */
2028     U_JG_MANICHAEAN_NUN,  /**< @stable ICU 54 */
2029     U_JG_MANICHAEAN_ONE,  /**< @stable ICU 54 */
2030     U_JG_MANICHAEAN_PE,  /**< @stable ICU 54 */
2031     U_JG_MANICHAEAN_QOPH,  /**< @stable ICU 54 */
2032     U_JG_MANICHAEAN_RESH,  /**< @stable ICU 54 */
2033     U_JG_MANICHAEAN_SADHE,  /**< @stable ICU 54 */
2034     U_JG_MANICHAEAN_SAMEKH,  /**< @stable ICU 54 */
2035     U_JG_MANICHAEAN_TAW,  /**< @stable ICU 54 */
2036     U_JG_MANICHAEAN_TEN,  /**< @stable ICU 54 */
2037     U_JG_MANICHAEAN_TETH,  /**< @stable ICU 54 */
2038     U_JG_MANICHAEAN_THAMEDH,  /**< @stable ICU 54 */
2039     U_JG_MANICHAEAN_TWENTY,  /**< @stable ICU 54 */
2040     U_JG_MANICHAEAN_WAW,  /**< @stable ICU 54 */
2041     U_JG_MANICHAEAN_YODH,  /**< @stable ICU 54 */
2042     U_JG_MANICHAEAN_ZAYIN,  /**< @stable ICU 54 */
2043     U_JG_STRAIGHT_WAW,  /**< @stable ICU 54 */
2044     U_JG_AFRICAN_FEH,  /**< @stable ICU 58 */
2045     U_JG_AFRICAN_NOON,  /**< @stable ICU 58 */
2046     U_JG_AFRICAN_QAF,  /**< @stable ICU 58 */
2047 
2048     U_JG_MALAYALAM_BHA,  /**< @stable ICU 60 */
2049     U_JG_MALAYALAM_JA,  /**< @stable ICU 60 */
2050     U_JG_MALAYALAM_LLA,  /**< @stable ICU 60 */
2051     U_JG_MALAYALAM_LLLA,  /**< @stable ICU 60 */
2052     U_JG_MALAYALAM_NGA,  /**< @stable ICU 60 */
2053     U_JG_MALAYALAM_NNA,  /**< @stable ICU 60 */
2054     U_JG_MALAYALAM_NNNA,  /**< @stable ICU 60 */
2055     U_JG_MALAYALAM_NYA,  /**< @stable ICU 60 */
2056     U_JG_MALAYALAM_RA,  /**< @stable ICU 60 */
2057     U_JG_MALAYALAM_SSA,  /**< @stable ICU 60 */
2058     U_JG_MALAYALAM_TTA,  /**< @stable ICU 60 */
2059 
2060     U_JG_HANIFI_ROHINGYA_KINNA_YA,  /**< @stable ICU 62 */
2061     U_JG_HANIFI_ROHINGYA_PA,  /**< @stable ICU 62 */
2062 
2063     U_JG_THIN_YEH,  /**< @stable ICU 70 */
2064     U_JG_VERTICAL_TAIL,  /**< @stable ICU 70 */
2065 } UJoiningGroup;
2066 
2067 /**
2068  * Grapheme Cluster Break constants.
2069  *
2070  * @see UCHAR_GRAPHEME_CLUSTER_BREAK
2071  * @stable ICU 3.4
2072  */
2073 typedef enum UGraphemeClusterBreak {
2074     /*
2075      * Note: UGraphemeClusterBreak constants are parsed by preparseucd.py.
2076      * It matches lines like
2077      *     U_GCB_<Unicode Grapheme_Cluster_Break value name>
2078      */
2079 
2080     U_GCB_OTHER = 0,            /*[XX]*/
2081     U_GCB_CONTROL = 1,          /*[CN]*/
2082     U_GCB_CR = 2,               /*[CR]*/
2083     U_GCB_EXTEND = 3,           /*[EX]*/
2084     U_GCB_L = 4,                /*[L]*/
2085     U_GCB_LF = 5,               /*[LF]*/
2086     U_GCB_LV = 6,               /*[LV]*/
2087     U_GCB_LVT = 7,              /*[LVT]*/
2088     U_GCB_T = 8,                /*[T]*/
2089     U_GCB_V = 9,                /*[V]*/
2090     /** @stable ICU 4.0 */
2091     U_GCB_SPACING_MARK = 10,    /*[SM]*/ /* from here on: new in Unicode 5.1/ICU 4.0 */
2092     /** @stable ICU 4.0 */
2093     U_GCB_PREPEND = 11,         /*[PP]*/
2094     /** @stable ICU 50 */
2095     U_GCB_REGIONAL_INDICATOR = 12,  /*[RI]*/ /* new in Unicode 6.2/ICU 50 */
2096     /** @stable ICU 58 */
2097     U_GCB_E_BASE = 13,          /*[EB]*/ /* from here on: new in Unicode 9.0/ICU 58 */
2098     /** @stable ICU 58 */
2099     U_GCB_E_BASE_GAZ = 14,      /*[EBG]*/
2100     /** @stable ICU 58 */
2101     U_GCB_E_MODIFIER = 15,      /*[EM]*/
2102     /** @stable ICU 58 */
2103     U_GCB_GLUE_AFTER_ZWJ = 16,  /*[GAZ]*/
2104     /** @stable ICU 58 */
2105     U_GCB_ZWJ = 17,             /*[ZWJ]*/
2106 } UGraphemeClusterBreak;
2107 
2108 /**
2109  * Word Break constants.
2110  * (UWordBreak is a pre-existing enum type in ubrk.h for word break status tags.)
2111  *
2112  * @see UCHAR_WORD_BREAK
2113  * @stable ICU 3.4
2114  */
2115 typedef enum UWordBreakValues {
2116     /*
2117      * Note: UWordBreakValues constants are parsed by preparseucd.py.
2118      * It matches lines like
2119      *     U_WB_<Unicode Word_Break value name>
2120      */
2121 
2122     U_WB_OTHER = 0,             /*[XX]*/
2123     U_WB_ALETTER = 1,           /*[LE]*/
2124     U_WB_FORMAT = 2,            /*[FO]*/
2125     U_WB_KATAKANA = 3,          /*[KA]*/
2126     U_WB_MIDLETTER = 4,         /*[ML]*/
2127     U_WB_MIDNUM = 5,            /*[MN]*/
2128     U_WB_NUMERIC = 6,           /*[NU]*/
2129     U_WB_EXTENDNUMLET = 7,      /*[EX]*/
2130     /** @stable ICU 4.0 */
2131     U_WB_CR = 8,                /*[CR]*/ /* from here on: new in Unicode 5.1/ICU 4.0 */
2132     /** @stable ICU 4.0 */
2133     U_WB_EXTEND = 9,            /*[Extend]*/
2134     /** @stable ICU 4.0 */
2135     U_WB_LF = 10,               /*[LF]*/
2136     /** @stable ICU 4.0 */
2137     U_WB_MIDNUMLET =11,         /*[MB]*/
2138     /** @stable ICU 4.0 */
2139     U_WB_NEWLINE =12,           /*[NL]*/
2140     /** @stable ICU 50 */
2141     U_WB_REGIONAL_INDICATOR = 13,   /*[RI]*/ /* new in Unicode 6.2/ICU 50 */
2142     /** @stable ICU 52 */
2143     U_WB_HEBREW_LETTER = 14,    /*[HL]*/ /* from here on: new in Unicode 6.3/ICU 52 */
2144     /** @stable ICU 52 */
2145     U_WB_SINGLE_QUOTE = 15,     /*[SQ]*/
2146     /** @stable ICU 52 */
2147     U_WB_DOUBLE_QUOTE = 16,     /*[DQ]*/
2148     /** @stable ICU 58 */
2149     U_WB_E_BASE = 17,           /*[EB]*/ /* from here on: new in Unicode 9.0/ICU 58 */
2150     /** @stable ICU 58 */
2151     U_WB_E_BASE_GAZ = 18,       /*[EBG]*/
2152     /** @stable ICU 58 */
2153     U_WB_E_MODIFIER = 19,       /*[EM]*/
2154     /** @stable ICU 58 */
2155     U_WB_GLUE_AFTER_ZWJ = 20,   /*[GAZ]*/
2156     /** @stable ICU 58 */
2157     U_WB_ZWJ = 21,              /*[ZWJ]*/
2158     /** @stable ICU 62 */
2159     U_WB_WSEGSPACE = 22,        /*[WSEGSPACE]*/
2160 } UWordBreakValues;
2161 
2162 /**
2163  * Sentence Break constants.
2164  *
2165  * @see UCHAR_SENTENCE_BREAK
2166  * @stable ICU 3.4
2167  */
2168 typedef enum USentenceBreak {
2169     /*
2170      * Note: USentenceBreak constants are parsed by preparseucd.py.
2171      * It matches lines like
2172      *     U_SB_<Unicode Sentence_Break value name>
2173      */
2174 
2175     U_SB_OTHER = 0,             /*[XX]*/
2176     U_SB_ATERM = 1,             /*[AT]*/
2177     U_SB_CLOSE = 2,             /*[CL]*/
2178     U_SB_FORMAT = 3,            /*[FO]*/
2179     U_SB_LOWER = 4,             /*[LO]*/
2180     U_SB_NUMERIC = 5,           /*[NU]*/
2181     U_SB_OLETTER = 6,           /*[LE]*/
2182     U_SB_SEP = 7,               /*[SE]*/
2183     U_SB_SP = 8,                /*[SP]*/
2184     U_SB_STERM = 9,             /*[ST]*/
2185     U_SB_UPPER = 10,            /*[UP]*/
2186     U_SB_CR = 11,               /*[CR]*/ /* from here on: new in Unicode 5.1/ICU 4.0 */
2187     U_SB_EXTEND = 12,           /*[EX]*/
2188     U_SB_LF = 13,               /*[LF]*/
2189     U_SB_SCONTINUE = 14,        /*[SC]*/
2190 } USentenceBreak;
2191 
2192 /**
2193  * Line Break constants.
2194  *
2195  * @see UCHAR_LINE_BREAK
2196  * @stable ICU 2.2
2197  */
2198 typedef enum ULineBreak {
2199     /*
2200      * Note: ULineBreak constants are parsed by preparseucd.py.
2201      * It matches lines like
2202      *     U_LB_<Unicode Line_Break value name>
2203      */
2204 
2205     U_LB_UNKNOWN = 0,           /*[XX]*/
2206     U_LB_AMBIGUOUS = 1,         /*[AI]*/
2207     U_LB_ALPHABETIC = 2,        /*[AL]*/
2208     U_LB_BREAK_BOTH = 3,        /*[B2]*/
2209     U_LB_BREAK_AFTER = 4,       /*[BA]*/
2210     U_LB_BREAK_BEFORE = 5,      /*[BB]*/
2211     U_LB_MANDATORY_BREAK = 6,   /*[BK]*/
2212     U_LB_CONTINGENT_BREAK = 7,  /*[CB]*/
2213     U_LB_CLOSE_PUNCTUATION = 8, /*[CL]*/
2214     U_LB_COMBINING_MARK = 9,    /*[CM]*/
2215     U_LB_CARRIAGE_RETURN = 10,   /*[CR]*/
2216     U_LB_EXCLAMATION = 11,       /*[EX]*/
2217     U_LB_GLUE = 12,              /*[GL]*/
2218     U_LB_HYPHEN = 13,            /*[HY]*/
2219     U_LB_IDEOGRAPHIC = 14,       /*[ID]*/
2220     /** Renamed from the misspelled "inseperable" in Unicode 4.0.1/ICU 3.0 @stable ICU 3.0 */
2221     U_LB_INSEPARABLE = 15,       /*[IN]*/
2222     U_LB_INSEPERABLE = U_LB_INSEPARABLE,
2223     U_LB_INFIX_NUMERIC = 16,     /*[IS]*/
2224     U_LB_LINE_FEED = 17,         /*[LF]*/
2225     U_LB_NONSTARTER = 18,        /*[NS]*/
2226     U_LB_NUMERIC = 19,           /*[NU]*/
2227     U_LB_OPEN_PUNCTUATION = 20,  /*[OP]*/
2228     U_LB_POSTFIX_NUMERIC = 21,   /*[PO]*/
2229     U_LB_PREFIX_NUMERIC = 22,    /*[PR]*/
2230     U_LB_QUOTATION = 23,         /*[QU]*/
2231     U_LB_COMPLEX_CONTEXT = 24,   /*[SA]*/
2232     U_LB_SURROGATE = 25,         /*[SG]*/
2233     U_LB_SPACE = 26,             /*[SP]*/
2234     U_LB_BREAK_SYMBOLS = 27,     /*[SY]*/
2235     U_LB_ZWSPACE = 28,           /*[ZW]*/
2236     /** @stable ICU 2.6 */
2237     U_LB_NEXT_LINE = 29,         /*[NL]*/ /* from here on: new in Unicode 4/ICU 2.6 */
2238     /** @stable ICU 2.6 */
2239     U_LB_WORD_JOINER = 30,       /*[WJ]*/
2240     /** @stable ICU 3.4 */
2241     U_LB_H2 = 31,                /*[H2]*/ /* from here on: new in Unicode 4.1/ICU 3.4 */
2242     /** @stable ICU 3.4 */
2243     U_LB_H3 = 32,                /*[H3]*/
2244     /** @stable ICU 3.4 */
2245     U_LB_JL = 33,                /*[JL]*/
2246     /** @stable ICU 3.4 */
2247     U_LB_JT = 34,                /*[JT]*/
2248     /** @stable ICU 3.4 */
2249     U_LB_JV = 35,                /*[JV]*/
2250     /** @stable ICU 4.4 */
2251     U_LB_CLOSE_PARENTHESIS = 36, /*[CP]*/ /* new in Unicode 5.2/ICU 4.4 */
2252     /** @stable ICU 49 */
2253     U_LB_CONDITIONAL_JAPANESE_STARTER = 37,/*[CJ]*/ /* new in Unicode 6.1/ICU 49 */
2254     /** @stable ICU 49 */
2255     U_LB_HEBREW_LETTER = 38,     /*[HL]*/ /* new in Unicode 6.1/ICU 49 */
2256     /** @stable ICU 50 */
2257     U_LB_REGIONAL_INDICATOR = 39,/*[RI]*/ /* new in Unicode 6.2/ICU 50 */
2258     /** @stable ICU 58 */
2259     U_LB_E_BASE = 40,            /*[EB]*/ /* from here on: new in Unicode 9.0/ICU 58 */
2260     /** @stable ICU 58 */
2261     U_LB_E_MODIFIER = 41,        /*[EM]*/
2262     /** @stable ICU 58 */
2263     U_LB_ZWJ = 42,               /*[ZWJ]*/
2264 } ULineBreak;
2265 
2266 /**
2267  * Numeric Type constants.
2268  *
2269  * @see UCHAR_NUMERIC_TYPE
2270  * @stable ICU 2.2
2271  */
2272 typedef enum UNumericType {
2273     /*
2274      * Note: UNumericType constants are parsed by preparseucd.py.
2275      * It matches lines like
2276      *     U_NT_<Unicode Numeric_Type value name>
2277      */
2278 
2279     U_NT_NONE,              /*[None]*/
2280     U_NT_DECIMAL,           /*[de]*/
2281     U_NT_DIGIT,             /*[di]*/
2282     U_NT_NUMERIC,           /*[nu]*/
2283 } UNumericType;
2284 
2285 /**
2286  * Hangul Syllable Type constants.
2287  *
2288  * @see UCHAR_HANGUL_SYLLABLE_TYPE
2289  * @stable ICU 2.6
2290  */
2291 typedef enum UHangulSyllableType {
2292     /*
2293      * Note: UHangulSyllableType constants are parsed by preparseucd.py.
2294      * It matches lines like
2295      *     U_HST_<Unicode Hangul_Syllable_Type value name>
2296      */
2297 
2298     U_HST_NOT_APPLICABLE,   /*[NA]*/
2299     U_HST_LEADING_JAMO,     /*[L]*/
2300     U_HST_VOWEL_JAMO,       /*[V]*/
2301     U_HST_TRAILING_JAMO,    /*[T]*/
2302     U_HST_LV_SYLLABLE,      /*[LV]*/
2303     U_HST_LVT_SYLLABLE,     /*[LVT]*/
2304 } UHangulSyllableType;
2305 
2306 /**
2307  * Indic Positional Category constants.
2308  *
2309  * @see UCHAR_INDIC_POSITIONAL_CATEGORY
2310  * @stable ICU 63
2311  */
2312 typedef enum UIndicPositionalCategory {
2313     /*
2314      * Note: UIndicPositionalCategory constants are parsed by preparseucd.py.
2315      * It matches lines like
2316      *     U_INPC_<Unicode Indic_Positional_Category value name>
2317      */
2318 
2319     /** @stable ICU 63 */
2320     U_INPC_NA,
2321     /** @stable ICU 63 */
2322     U_INPC_BOTTOM,
2323     /** @stable ICU 63 */
2324     U_INPC_BOTTOM_AND_LEFT,
2325     /** @stable ICU 63 */
2326     U_INPC_BOTTOM_AND_RIGHT,
2327     /** @stable ICU 63 */
2328     U_INPC_LEFT,
2329     /** @stable ICU 63 */
2330     U_INPC_LEFT_AND_RIGHT,
2331     /** @stable ICU 63 */
2332     U_INPC_OVERSTRUCK,
2333     /** @stable ICU 63 */
2334     U_INPC_RIGHT,
2335     /** @stable ICU 63 */
2336     U_INPC_TOP,
2337     /** @stable ICU 63 */
2338     U_INPC_TOP_AND_BOTTOM,
2339     /** @stable ICU 63 */
2340     U_INPC_TOP_AND_BOTTOM_AND_RIGHT,
2341     /** @stable ICU 63 */
2342     U_INPC_TOP_AND_LEFT,
2343     /** @stable ICU 63 */
2344     U_INPC_TOP_AND_LEFT_AND_RIGHT,
2345     /** @stable ICU 63 */
2346     U_INPC_TOP_AND_RIGHT,
2347     /** @stable ICU 63 */
2348     U_INPC_VISUAL_ORDER_LEFT,
2349     /** @stable ICU 66 */
2350     U_INPC_TOP_AND_BOTTOM_AND_LEFT,
2351 } UIndicPositionalCategory;
2352 
2353 /**
2354  * Indic Syllabic Category constants.
2355  *
2356  * @see UCHAR_INDIC_SYLLABIC_CATEGORY
2357  * @stable ICU 63
2358  */
2359 typedef enum UIndicSyllabicCategory {
2360     /*
2361      * Note: UIndicSyllabicCategory constants are parsed by preparseucd.py.
2362      * It matches lines like
2363      *     U_INSC_<Unicode Indic_Syllabic_Category value name>
2364      */
2365 
2366     /** @stable ICU 63 */
2367     U_INSC_OTHER,
2368     /** @stable ICU 63 */
2369     U_INSC_AVAGRAHA,
2370     /** @stable ICU 63 */
2371     U_INSC_BINDU,
2372     /** @stable ICU 63 */
2373     U_INSC_BRAHMI_JOINING_NUMBER,
2374     /** @stable ICU 63 */
2375     U_INSC_CANTILLATION_MARK,
2376     /** @stable ICU 63 */
2377     U_INSC_CONSONANT,
2378     /** @stable ICU 63 */
2379     U_INSC_CONSONANT_DEAD,
2380     /** @stable ICU 63 */
2381     U_INSC_CONSONANT_FINAL,
2382     /** @stable ICU 63 */
2383     U_INSC_CONSONANT_HEAD_LETTER,
2384     /** @stable ICU 63 */
2385     U_INSC_CONSONANT_INITIAL_POSTFIXED,
2386     /** @stable ICU 63 */
2387     U_INSC_CONSONANT_KILLER,
2388     /** @stable ICU 63 */
2389     U_INSC_CONSONANT_MEDIAL,
2390     /** @stable ICU 63 */
2391     U_INSC_CONSONANT_PLACEHOLDER,
2392     /** @stable ICU 63 */
2393     U_INSC_CONSONANT_PRECEDING_REPHA,
2394     /** @stable ICU 63 */
2395     U_INSC_CONSONANT_PREFIXED,
2396     /** @stable ICU 63 */
2397     U_INSC_CONSONANT_SUBJOINED,
2398     /** @stable ICU 63 */
2399     U_INSC_CONSONANT_SUCCEEDING_REPHA,
2400     /** @stable ICU 63 */
2401     U_INSC_CONSONANT_WITH_STACKER,
2402     /** @stable ICU 63 */
2403     U_INSC_GEMINATION_MARK,
2404     /** @stable ICU 63 */
2405     U_INSC_INVISIBLE_STACKER,
2406     /** @stable ICU 63 */
2407     U_INSC_JOINER,
2408     /** @stable ICU 63 */
2409     U_INSC_MODIFYING_LETTER,
2410     /** @stable ICU 63 */
2411     U_INSC_NON_JOINER,
2412     /** @stable ICU 63 */
2413     U_INSC_NUKTA,
2414     /** @stable ICU 63 */
2415     U_INSC_NUMBER,
2416     /** @stable ICU 63 */
2417     U_INSC_NUMBER_JOINER,
2418     /** @stable ICU 63 */
2419     U_INSC_PURE_KILLER,
2420     /** @stable ICU 63 */
2421     U_INSC_REGISTER_SHIFTER,
2422     /** @stable ICU 63 */
2423     U_INSC_SYLLABLE_MODIFIER,
2424     /** @stable ICU 63 */
2425     U_INSC_TONE_LETTER,
2426     /** @stable ICU 63 */
2427     U_INSC_TONE_MARK,
2428     /** @stable ICU 63 */
2429     U_INSC_VIRAMA,
2430     /** @stable ICU 63 */
2431     U_INSC_VISARGA,
2432     /** @stable ICU 63 */
2433     U_INSC_VOWEL,
2434     /** @stable ICU 63 */
2435     U_INSC_VOWEL_DEPENDENT,
2436     /** @stable ICU 63 */
2437     U_INSC_VOWEL_INDEPENDENT,
2438 } UIndicSyllabicCategory;
2439 
2440 /**
2441  * Vertical Orientation constants.
2442  *
2443  * @see UCHAR_VERTICAL_ORIENTATION
2444  * @stable ICU 63
2445  */
2446 typedef enum UVerticalOrientation {
2447     /*
2448      * Note: UVerticalOrientation constants are parsed by preparseucd.py.
2449      * It matches lines like
2450      *     U_VO_<Unicode Vertical_Orientation value name>
2451      */
2452 
2453     /** @stable ICU 63 */
2454     U_VO_ROTATED,
2455     /** @stable ICU 63 */
2456     U_VO_TRANSFORMED_ROTATED,
2457     /** @stable ICU 63 */
2458     U_VO_TRANSFORMED_UPRIGHT,
2459     /** @stable ICU 63 */
2460     U_VO_UPRIGHT,
2461 } UVerticalOrientation;
2462 
2463 /**
2464  * Check a binary Unicode property for a code point.
2465  *
2466  * Unicode, especially in version 3.2, defines many more properties than the
2467  * original set in UnicodeData.txt.
2468  *
2469  * The properties APIs are intended to reflect Unicode properties as defined
2470  * in the Unicode Character Database (UCD) and Unicode Technical Reports (UTR).
2471  * For details about the properties see http://www.unicode.org/ucd/ .
2472  * For names of Unicode properties see the UCD file PropertyAliases.txt.
2473  *
2474  * Important: If ICU is built with UCD files from Unicode versions below 3.2,
2475  * then properties marked with "new in Unicode 3.2" are not or not fully available.
2476  *
2477  * @param c Code point to test.
2478  * @param which UProperty selector constant, identifies which binary property to check.
2479  *        Must be UCHAR_BINARY_START&lt;=which&lt;UCHAR_BINARY_LIMIT.
2480  * @return true or false according to the binary Unicode property value for c.
2481  *         Also false if 'which' is out of bounds or if the Unicode version
2482  *         does not have data for the property at all.
2483  *
2484  * @see UProperty
2485  * @see u_getBinaryPropertySet
2486  * @see u_getIntPropertyValue
2487  * @see u_getUnicodeVersion
2488  * @stable ICU 2.1
2489  */
2490 U_CAPI UBool U_EXPORT2
2491 u_hasBinaryProperty(UChar32 c, UProperty which);
2492 
2493 /**
2494  * Returns true if the property is true for the string.
2495  * Same as u_hasBinaryProperty(single code point, which)
2496  * if the string contains exactly one code point.
2497  *
2498  * Most properties apply only to single code points.
2499  * <a href="https://www.unicode.org/reports/tr51/#Emoji_Sets">UTS #51 Unicode Emoji</a>
2500  * defines several properties of strings.
2501  *
2502  * @param s String to test.
2503  * @param length Length of the string, or negative if NUL-terminated.
2504  * @param which UProperty selector constant, identifies which binary property to check.
2505  *        Must be UCHAR_BINARY_START&lt;=which&lt;UCHAR_BINARY_LIMIT.
2506  * @return true or false according to the binary Unicode property value for the string.
2507  *         Also false if 'which' is out of bounds or if the Unicode version
2508  *         does not have data for the property at all.
2509  *
2510  * @see UProperty
2511  * @see u_hasBinaryProperty
2512  * @see u_getBinaryPropertySet
2513  * @see u_getIntPropertyValue
2514  * @see u_getUnicodeVersion
2515  * @stable ICU 70
2516  */
2517 U_CAPI UBool U_EXPORT2
2518 u_stringHasBinaryProperty(const UChar *s, int32_t length, UProperty which);
2519 
2520 /**
2521  * Returns a frozen USet for a binary property.
2522  * The library retains ownership over the returned object.
2523  * Sets an error code if the property number is not one for a binary property.
2524  *
2525  * The returned set contains all code points for which the property is true.
2526  *
2527  * @param property UCHAR_BINARY_START..UCHAR_BINARY_LIMIT-1
2528  * @param pErrorCode an in/out ICU UErrorCode
2529  * @return the property as a set
2530  * @see UProperty
2531  * @see u_hasBinaryProperty
2532  * @see Unicode::fromUSet
2533  * @stable ICU 63
2534  */
2535 U_CAPI const USet * U_EXPORT2
2536 u_getBinaryPropertySet(UProperty property, UErrorCode *pErrorCode);
2537 
2538 /**
2539  * Check if a code point has the Alphabetic Unicode property.
2540  * Same as u_hasBinaryProperty(c, UCHAR_ALPHABETIC).
2541  * This is different from u_isalpha!
2542  * @param c Code point to test
2543  * @return true if the code point has the Alphabetic Unicode property, false otherwise
2544  *
2545  * @see UCHAR_ALPHABETIC
2546  * @see u_isalpha
2547  * @see u_hasBinaryProperty
2548  * @stable ICU 2.1
2549  */
2550 U_CAPI UBool U_EXPORT2
2551 u_isUAlphabetic(UChar32 c);
2552 
2553 /**
2554  * Check if a code point has the Lowercase Unicode property.
2555  * Same as u_hasBinaryProperty(c, UCHAR_LOWERCASE).
2556  * This is different from u_islower!
2557  * @param c Code point to test
2558  * @return true if the code point has the Lowercase Unicode property, false otherwise
2559  *
2560  * @see UCHAR_LOWERCASE
2561  * @see u_islower
2562  * @see u_hasBinaryProperty
2563  * @stable ICU 2.1
2564  */
2565 U_CAPI UBool U_EXPORT2
2566 u_isULowercase(UChar32 c);
2567 
2568 /**
2569  * Check if a code point has the Uppercase Unicode property.
2570  * Same as u_hasBinaryProperty(c, UCHAR_UPPERCASE).
2571  * This is different from u_isupper!
2572  * @param c Code point to test
2573  * @return true if the code point has the Uppercase Unicode property, false otherwise
2574  *
2575  * @see UCHAR_UPPERCASE
2576  * @see u_isupper
2577  * @see u_hasBinaryProperty
2578  * @stable ICU 2.1
2579  */
2580 U_CAPI UBool U_EXPORT2
2581 u_isUUppercase(UChar32 c);
2582 
2583 /**
2584  * Check if a code point has the White_Space Unicode property.
2585  * Same as u_hasBinaryProperty(c, UCHAR_WHITE_SPACE).
2586  * This is different from both u_isspace and u_isWhitespace!
2587  *
2588  * Note: There are several ICU whitespace functions; please see the uchar.h
2589  * file documentation for a detailed comparison.
2590  *
2591  * @param c Code point to test
2592  * @return true if the code point has the White_Space Unicode property, false otherwise.
2593  *
2594  * @see UCHAR_WHITE_SPACE
2595  * @see u_isWhitespace
2596  * @see u_isspace
2597  * @see u_isJavaSpaceChar
2598  * @see u_hasBinaryProperty
2599  * @stable ICU 2.1
2600  */
2601 U_CAPI UBool U_EXPORT2
2602 u_isUWhiteSpace(UChar32 c);
2603 
2604 /**
2605  * Get the property value for an enumerated or integer Unicode property for a code point.
2606  * Also returns binary and mask property values.
2607  *
2608  * Unicode, especially in version 3.2, defines many more properties than the
2609  * original set in UnicodeData.txt.
2610  *
2611  * The properties APIs are intended to reflect Unicode properties as defined
2612  * in the Unicode Character Database (UCD) and Unicode Technical Reports (UTR).
2613  * For details about the properties see http://www.unicode.org/ .
2614  * For names of Unicode properties see the UCD file PropertyAliases.txt.
2615  *
2616  * Sample usage:
2617  * UEastAsianWidth ea=(UEastAsianWidth)u_getIntPropertyValue(c, UCHAR_EAST_ASIAN_WIDTH);
2618  * UBool b=(UBool)u_getIntPropertyValue(c, UCHAR_IDEOGRAPHIC);
2619  *
2620  * @param c Code point to test.
2621  * @param which UProperty selector constant, identifies which property to check.
2622  *        Must be UCHAR_BINARY_START<=which<UCHAR_BINARY_LIMIT
2623  *        or UCHAR_INT_START<=which<UCHAR_INT_LIMIT
2624  *        or UCHAR_MASK_START<=which<UCHAR_MASK_LIMIT.
2625  * @return Numeric value that is directly the property value or,
2626  *         for enumerated properties, corresponds to the numeric value of the enumerated
2627  *         constant of the respective property value enumeration type
2628  *         (cast to enum type if necessary).
2629  *         Returns 0 or 1 (for false/true) for binary Unicode properties.
2630  *         Returns a bit-mask for mask properties.
2631  *         Returns 0 if 'which' is out of bounds or if the Unicode version
2632  *         does not have data for the property at all, or not for this code point.
2633  *
2634  * @see UProperty
2635  * @see u_hasBinaryProperty
2636  * @see u_getIntPropertyMinValue
2637  * @see u_getIntPropertyMaxValue
2638  * @see u_getIntPropertyMap
2639  * @see u_getUnicodeVersion
2640  * @stable ICU 2.2
2641  */
2642 U_CAPI int32_t U_EXPORT2
2643 u_getIntPropertyValue(UChar32 c, UProperty which);
2644 
2645 /**
2646  * Get the minimum value for an enumerated/integer/binary Unicode property.
2647  * Can be used together with u_getIntPropertyMaxValue
2648  * to allocate arrays of UnicodeSet or similar.
2649  *
2650  * @param which UProperty selector constant, identifies which binary property to check.
2651  *        Must be UCHAR_BINARY_START<=which<UCHAR_BINARY_LIMIT
2652  *        or UCHAR_INT_START<=which<UCHAR_INT_LIMIT.
2653  * @return Minimum value returned by u_getIntPropertyValue for a Unicode property.
2654  *         0 if the property selector is out of range.
2655  *
2656  * @see UProperty
2657  * @see u_hasBinaryProperty
2658  * @see u_getUnicodeVersion
2659  * @see u_getIntPropertyMaxValue
2660  * @see u_getIntPropertyValue
2661  * @stable ICU 2.2
2662  */
2663 U_CAPI int32_t U_EXPORT2
2664 u_getIntPropertyMinValue(UProperty which);
2665 
2666 /**
2667  * Get the maximum value for an enumerated/integer/binary Unicode property.
2668  * Can be used together with u_getIntPropertyMinValue
2669  * to allocate arrays of UnicodeSet or similar.
2670  *
2671  * Examples for min/max values (for Unicode 3.2):
2672  *
2673  * - UCHAR_BIDI_CLASS:    0/18 (U_LEFT_TO_RIGHT/U_BOUNDARY_NEUTRAL)
2674  * - UCHAR_SCRIPT:        0/45 (USCRIPT_COMMON/USCRIPT_TAGBANWA)
2675  * - UCHAR_IDEOGRAPHIC:   0/1  (false/true)
2676  *
2677  * For undefined UProperty constant values, min/max values will be 0/-1.
2678  *
2679  * @param which UProperty selector constant, identifies which binary property to check.
2680  *        Must be UCHAR_BINARY_START<=which<UCHAR_BINARY_LIMIT
2681  *        or UCHAR_INT_START<=which<UCHAR_INT_LIMIT.
2682  * @return Maximum value returned by u_getIntPropertyValue for a Unicode property.
2683  *         <=0 if the property selector is out of range.
2684  *
2685  * @see UProperty
2686  * @see u_hasBinaryProperty
2687  * @see u_getUnicodeVersion
2688  * @see u_getIntPropertyMaxValue
2689  * @see u_getIntPropertyValue
2690  * @stable ICU 2.2
2691  */
2692 U_CAPI int32_t U_EXPORT2
2693 u_getIntPropertyMaxValue(UProperty which);
2694 
2695 /**
2696  * Get the numeric value for a Unicode code point as defined in the
2697  * Unicode Character Database.
2698  *
2699  * A "double" return type is necessary because
2700  * some numeric values are fractions, negative, or too large for int32_t.
2701  *
2702  * For characters without any numeric values in the Unicode Character Database,
2703  * this function will return U_NO_NUMERIC_VALUE.
2704  * Note: This is different from the Unicode Standard which specifies NaN as the default value.
2705  * (NaN is not available on all platforms.)
2706  *
2707  * Similar to java.lang.Character.getNumericValue(), but u_getNumericValue()
2708  * also supports negative values, large values, and fractions,
2709  * while Java's getNumericValue() returns values 10..35 for ASCII letters.
2710  *
2711  * @param c Code point to get the numeric value for.
2712  * @return Numeric value of c, or U_NO_NUMERIC_VALUE if none is defined.
2713  *
2714  * @see U_NO_NUMERIC_VALUE
2715  * @stable ICU 2.2
2716  */
2717 U_CAPI double U_EXPORT2
2718 u_getNumericValue(UChar32 c);
2719 
2720 /**
2721  * Special value that is returned by u_getNumericValue when
2722  * no numeric value is defined for a code point.
2723  *
2724  * @see u_getNumericValue
2725  * @stable ICU 2.2
2726  */
2727 #define U_NO_NUMERIC_VALUE ((double)-123456789.)
2728 
2729 /**
2730  * Determines whether the specified code point has the general category "Ll"
2731  * (lowercase letter).
2732  *
2733  * Same as java.lang.Character.isLowerCase().
2734  *
2735  * This misses some characters that are also lowercase but
2736  * have a different general category value.
2737  * In order to include those, use UCHAR_LOWERCASE.
2738  *
2739  * In addition to being equivalent to a Java function, this also serves
2740  * as a C/POSIX migration function.
2741  * See the comments about C/POSIX character classification functions in the
2742  * documentation at the top of this header file.
2743  *
2744  * @param c the code point to be tested
2745  * @return true if the code point is an Ll lowercase letter
2746  *
2747  * @see UCHAR_LOWERCASE
2748  * @see u_isupper
2749  * @see u_istitle
2750  * @stable ICU 2.0
2751  */
2752 U_CAPI UBool U_EXPORT2
2753 u_islower(UChar32 c);
2754 
2755 /**
2756  * Determines whether the specified code point has the general category "Lu"
2757  * (uppercase letter).
2758  *
2759  * Same as java.lang.Character.isUpperCase().
2760  *
2761  * This misses some characters that are also uppercase but
2762  * have a different general category value.
2763  * In order to include those, use UCHAR_UPPERCASE.
2764  *
2765  * In addition to being equivalent to a Java function, this also serves
2766  * as a C/POSIX migration function.
2767  * See the comments about C/POSIX character classification functions in the
2768  * documentation at the top of this header file.
2769  *
2770  * @param c the code point to be tested
2771  * @return true if the code point is an Lu uppercase letter
2772  *
2773  * @see UCHAR_UPPERCASE
2774  * @see u_islower
2775  * @see u_istitle
2776  * @see u_tolower
2777  * @stable ICU 2.0
2778  */
2779 U_CAPI UBool U_EXPORT2
2780 u_isupper(UChar32 c);
2781 
2782 /**
2783  * Determines whether the specified code point is a titlecase letter.
2784  * True for general category "Lt" (titlecase letter).
2785  *
2786  * Same as java.lang.Character.isTitleCase().
2787  *
2788  * @param c the code point to be tested
2789  * @return true if the code point is an Lt titlecase letter
2790  *
2791  * @see u_isupper
2792  * @see u_islower
2793  * @see u_totitle
2794  * @stable ICU 2.0
2795  */
2796 U_CAPI UBool U_EXPORT2
2797 u_istitle(UChar32 c);
2798 
2799 /**
2800  * Determines whether the specified code point is a digit character according to Java.
2801  * True for characters with general category "Nd" (decimal digit numbers).
2802  * Beginning with Unicode 4, this is the same as
2803  * testing for the Numeric_Type of Decimal.
2804  *
2805  * Same as java.lang.Character.isDigit().
2806  *
2807  * In addition to being equivalent to a Java function, this also serves
2808  * as a C/POSIX migration function.
2809  * See the comments about C/POSIX character classification functions in the
2810  * documentation at the top of this header file.
2811  *
2812  * @param c the code point to be tested
2813  * @return true if the code point is a digit character according to Character.isDigit()
2814  *
2815  * @stable ICU 2.0
2816  */
2817 U_CAPI UBool U_EXPORT2
2818 u_isdigit(UChar32 c);
2819 
2820 /**
2821  * Determines whether the specified code point is a letter character.
2822  * True for general categories "L" (letters).
2823  *
2824  * Same as java.lang.Character.isLetter().
2825  *
2826  * In addition to being equivalent to a Java function, this also serves
2827  * as a C/POSIX migration function.
2828  * See the comments about C/POSIX character classification functions in the
2829  * documentation at the top of this header file.
2830  *
2831  * @param c the code point to be tested
2832  * @return true if the code point is a letter character
2833  *
2834  * @see u_isdigit
2835  * @see u_isalnum
2836  * @stable ICU 2.0
2837  */
2838 U_CAPI UBool U_EXPORT2
2839 u_isalpha(UChar32 c);
2840 
2841 /**
2842  * Determines whether the specified code point is an alphanumeric character
2843  * (letter or digit) according to Java.
2844  * True for characters with general categories
2845  * "L" (letters) and "Nd" (decimal digit numbers).
2846  *
2847  * Same as java.lang.Character.isLetterOrDigit().
2848  *
2849  * In addition to being equivalent to a Java function, this also serves
2850  * as a C/POSIX migration function.
2851  * See the comments about C/POSIX character classification functions in the
2852  * documentation at the top of this header file.
2853  *
2854  * @param c the code point to be tested
2855  * @return true if the code point is an alphanumeric character according to Character.isLetterOrDigit()
2856  *
2857  * @stable ICU 2.0
2858  */
2859 U_CAPI UBool U_EXPORT2
2860 u_isalnum(UChar32 c);
2861 
2862 /**
2863  * Determines whether the specified code point is a hexadecimal digit.
2864  * This is equivalent to u_digit(c, 16)>=0.
2865  * True for characters with general category "Nd" (decimal digit numbers)
2866  * as well as Latin letters a-f and A-F in both ASCII and Fullwidth ASCII.
2867  * (That is, for letters with code points
2868  * 0041..0046, 0061..0066, FF21..FF26, FF41..FF46.)
2869  *
2870  * In order to narrow the definition of hexadecimal digits to only ASCII
2871  * characters, use (c<=0x7f && u_isxdigit(c)).
2872  *
2873  * This is a C/POSIX migration function.
2874  * See the comments about C/POSIX character classification functions in the
2875  * documentation at the top of this header file.
2876  *
2877  * @param c the code point to be tested
2878  * @return true if the code point is a hexadecimal digit
2879  *
2880  * @stable ICU 2.6
2881  */
2882 U_CAPI UBool U_EXPORT2
2883 u_isxdigit(UChar32 c);
2884 
2885 /**
2886  * Determines whether the specified code point is a punctuation character.
2887  * True for characters with general categories "P" (punctuation).
2888  *
2889  * This is a C/POSIX migration function.
2890  * See the comments about C/POSIX character classification functions in the
2891  * documentation at the top of this header file.
2892  *
2893  * @param c the code point to be tested
2894  * @return true if the code point is a punctuation character
2895  *
2896  * @stable ICU 2.6
2897  */
2898 U_CAPI UBool U_EXPORT2
2899 u_ispunct(UChar32 c);
2900 
2901 /**
2902  * Determines whether the specified code point is a "graphic" character
2903  * (printable, excluding spaces).
2904  * true for all characters except those with general categories
2905  * "Cc" (control codes), "Cf" (format controls), "Cs" (surrogates),
2906  * "Cn" (unassigned), and "Z" (separators).
2907  *
2908  * This is a C/POSIX migration function.
2909  * See the comments about C/POSIX character classification functions in the
2910  * documentation at the top of this header file.
2911  *
2912  * @param c the code point to be tested
2913  * @return true if the code point is a "graphic" character
2914  *
2915  * @stable ICU 2.6
2916  */
2917 U_CAPI UBool U_EXPORT2
2918 u_isgraph(UChar32 c);
2919 
2920 /**
2921  * Determines whether the specified code point is a "blank" or "horizontal space",
2922  * a character that visibly separates words on a line.
2923  * The following are equivalent definitions:
2924  *
2925  * true for Unicode White_Space characters except for "vertical space controls"
2926  * where "vertical space controls" are the following characters:
2927  * U+000A (LF) U+000B (VT) U+000C (FF) U+000D (CR) U+0085 (NEL) U+2028 (LS) U+2029 (PS)
2928  *
2929  * same as
2930  *
2931  * true for U+0009 (TAB) and characters with general category "Zs" (space separators).
2932  *
2933  * Note: There are several ICU whitespace functions; please see the uchar.h
2934  * file documentation for a detailed comparison.
2935  *
2936  * This is a C/POSIX migration function.
2937  * See the comments about C/POSIX character classification functions in the
2938  * documentation at the top of this header file.
2939  *
2940  * @param c the code point to be tested
2941  * @return true if the code point is a "blank"
2942  *
2943  * @stable ICU 2.6
2944  */
2945 U_CAPI UBool U_EXPORT2
2946 u_isblank(UChar32 c);
2947 
2948 /**
2949  * Determines whether the specified code point is "defined",
2950  * which usually means that it is assigned a character.
2951  * True for general categories other than "Cn" (other, not assigned),
2952  * i.e., true for all code points mentioned in UnicodeData.txt.
2953  *
2954  * Note that non-character code points (e.g., U+FDD0) are not "defined"
2955  * (they are Cn), but surrogate code points are "defined" (Cs).
2956  *
2957  * Same as java.lang.Character.isDefined().
2958  *
2959  * @param c the code point to be tested
2960  * @return true if the code point is assigned a character
2961  *
2962  * @see u_isdigit
2963  * @see u_isalpha
2964  * @see u_isalnum
2965  * @see u_isupper
2966  * @see u_islower
2967  * @see u_istitle
2968  * @stable ICU 2.0
2969  */
2970 U_CAPI UBool U_EXPORT2
2971 u_isdefined(UChar32 c);
2972 
2973 /**
2974  * Determines if the specified character is a space character or not.
2975  *
2976  * Note: There are several ICU whitespace functions; please see the uchar.h
2977  * file documentation for a detailed comparison.
2978  *
2979  * This is a C/POSIX migration function.
2980  * See the comments about C/POSIX character classification functions in the
2981  * documentation at the top of this header file.
2982  *
2983  * @param c    the character to be tested
2984  * @return  true if the character is a space character; false otherwise.
2985  *
2986  * @see u_isJavaSpaceChar
2987  * @see u_isWhitespace
2988  * @see u_isUWhiteSpace
2989  * @stable ICU 2.0
2990  */
2991 U_CAPI UBool U_EXPORT2
2992 u_isspace(UChar32 c);
2993 
2994 /**
2995  * Determine if the specified code point is a space character according to Java.
2996  * True for characters with general categories "Z" (separators),
2997  * which does not include control codes (e.g., TAB or Line Feed).
2998  *
2999  * Same as java.lang.Character.isSpaceChar().
3000  *
3001  * Note: There are several ICU whitespace functions; please see the uchar.h
3002  * file documentation for a detailed comparison.
3003  *
3004  * @param c the code point to be tested
3005  * @return true if the code point is a space character according to Character.isSpaceChar()
3006  *
3007  * @see u_isspace
3008  * @see u_isWhitespace
3009  * @see u_isUWhiteSpace
3010  * @stable ICU 2.6
3011  */
3012 U_CAPI UBool U_EXPORT2
3013 u_isJavaSpaceChar(UChar32 c);
3014 
3015 /**
3016  * Determines if the specified code point is a whitespace character according to Java/ICU.
3017  * A character is considered to be a Java whitespace character if and only
3018  * if it satisfies one of the following criteria:
3019  *
3020  * - It is a Unicode Separator character (categories "Z" = "Zs" or "Zl" or "Zp"), but is not
3021  *      also a non-breaking space (U+00A0 NBSP or U+2007 Figure Space or U+202F Narrow NBSP).
3022  * - It is U+0009 HORIZONTAL TABULATION.
3023  * - It is U+000A LINE FEED.
3024  * - It is U+000B VERTICAL TABULATION.
3025  * - It is U+000C FORM FEED.
3026  * - It is U+000D CARRIAGE RETURN.
3027  * - It is U+001C FILE SEPARATOR.
3028  * - It is U+001D GROUP SEPARATOR.
3029  * - It is U+001E RECORD SEPARATOR.
3030  * - It is U+001F UNIT SEPARATOR.
3031  *
3032  * This API tries to sync with the semantics of Java's
3033  * java.lang.Character.isWhitespace(), but it may not return
3034  * the exact same results because of the Unicode version
3035  * difference.
3036  *
3037  * Note: Unicode 4.0.1 changed U+200B ZERO WIDTH SPACE from a Space Separator (Zs)
3038  * to a Format Control (Cf). Since then, isWhitespace(0x200b) returns false.
3039  * See http://www.unicode.org/versions/Unicode4.0.1/
3040  *
3041  * Note: There are several ICU whitespace functions; please see the uchar.h
3042  * file documentation for a detailed comparison.
3043  *
3044  * @param c the code point to be tested
3045  * @return true if the code point is a whitespace character according to Java/ICU
3046  *
3047  * @see u_isspace
3048  * @see u_isJavaSpaceChar
3049  * @see u_isUWhiteSpace
3050  * @stable ICU 2.0
3051  */
3052 U_CAPI UBool U_EXPORT2
3053 u_isWhitespace(UChar32 c);
3054 
3055 /**
3056  * Determines whether the specified code point is a control character
3057  * (as defined by this function).
3058  * A control character is one of the following:
3059  * - ISO 8-bit control character (U+0000..U+001f and U+007f..U+009f)
3060  * - U_CONTROL_CHAR (Cc)
3061  * - U_FORMAT_CHAR (Cf)
3062  * - U_LINE_SEPARATOR (Zl)
3063  * - U_PARAGRAPH_SEPARATOR (Zp)
3064  *
3065  * This is a C/POSIX migration function.
3066  * See the comments about C/POSIX character classification functions in the
3067  * documentation at the top of this header file.
3068  *
3069  * @param c the code point to be tested
3070  * @return true if the code point is a control character
3071  *
3072  * @see UCHAR_DEFAULT_IGNORABLE_CODE_POINT
3073  * @see u_isprint
3074  * @stable ICU 2.0
3075  */
3076 U_CAPI UBool U_EXPORT2
3077 u_iscntrl(UChar32 c);
3078 
3079 /**
3080  * Determines whether the specified code point is an ISO control code.
3081  * True for U+0000..U+001f and U+007f..U+009f (general category "Cc").
3082  *
3083  * Same as java.lang.Character.isISOControl().
3084  *
3085  * @param c the code point to be tested
3086  * @return true if the code point is an ISO control code
3087  *
3088  * @see u_iscntrl
3089  * @stable ICU 2.6
3090  */
3091 U_CAPI UBool U_EXPORT2
3092 u_isISOControl(UChar32 c);
3093 
3094 /**
3095  * Determines whether the specified code point is a printable character.
3096  * True for general categories <em>other</em> than "C" (controls).
3097  *
3098  * This is a C/POSIX migration function.
3099  * See the comments about C/POSIX character classification functions in the
3100  * documentation at the top of this header file.
3101  *
3102  * @param c the code point to be tested
3103  * @return true if the code point is a printable character
3104  *
3105  * @see UCHAR_DEFAULT_IGNORABLE_CODE_POINT
3106  * @see u_iscntrl
3107  * @stable ICU 2.0
3108  */
3109 U_CAPI UBool U_EXPORT2
3110 u_isprint(UChar32 c);
3111 
3112 /**
3113  * Non-standard: Determines whether the specified code point is a base character.
3114  * True for general categories "L" (letters), "N" (numbers),
3115  * "Mc" (spacing combining marks), and "Me" (enclosing marks).
3116  *
3117  * Note that this is different from the Unicode Standard definition in
3118  * chapter 3.6, conformance clause D51 “Base character”,
3119  * which defines base characters as the code points with general categories
3120  * Letter (L), Number (N), Punctuation (P), Symbol (S), or Space Separator (Zs).
3121  *
3122  * @param c the code point to be tested
3123  * @return true if the code point is a base character according to this function
3124  *
3125  * @see u_isalpha
3126  * @see u_isdigit
3127  * @stable ICU 2.0
3128  */
3129 U_CAPI UBool U_EXPORT2
3130 u_isbase(UChar32 c);
3131 
3132 /**
3133  * Returns the bidirectional category value for the code point,
3134  * which is used in the Unicode bidirectional algorithm
3135  * (UAX #9 http://www.unicode.org/reports/tr9/).
3136  * Note that some <em>unassigned</em> code points have bidi values
3137  * of R or AL because they are in blocks that are reserved
3138  * for Right-To-Left scripts.
3139  *
3140  * Same as java.lang.Character.getDirectionality()
3141  *
3142  * @param c the code point to be tested
3143  * @return the bidirectional category (UCharDirection) value
3144  *
3145  * @see UCharDirection
3146  * @stable ICU 2.0
3147  */
3148 U_CAPI UCharDirection U_EXPORT2
3149 u_charDirection(UChar32 c);
3150 
3151 /**
3152  * Determines whether the code point has the Bidi_Mirrored property.
3153  * This property is set for characters that are commonly used in
3154  * Right-To-Left contexts and need to be displayed with a "mirrored"
3155  * glyph.
3156  *
3157  * Same as java.lang.Character.isMirrored().
3158  * Same as UCHAR_BIDI_MIRRORED
3159  *
3160  * @param c the code point to be tested
3161  * @return true if the character has the Bidi_Mirrored property
3162  *
3163  * @see UCHAR_BIDI_MIRRORED
3164  * @stable ICU 2.0
3165  */
3166 U_CAPI UBool U_EXPORT2
3167 u_isMirrored(UChar32 c);
3168 
3169 /**
3170  * Maps the specified character to a "mirror-image" character.
3171  * For characters with the Bidi_Mirrored property, implementations
3172  * sometimes need a "poor man's" mapping to another Unicode
3173  * character (code point) such that the default glyph may serve
3174  * as the mirror-image of the default glyph of the specified
3175  * character. This is useful for text conversion to and from
3176  * codepages with visual order, and for displays without glyph
3177  * selection capabilities.
3178  *
3179  * @param c the code point to be mapped
3180  * @return another Unicode code point that may serve as a mirror-image
3181  *         substitute, or c itself if there is no such mapping or c
3182  *         does not have the Bidi_Mirrored property
3183  *
3184  * @see UCHAR_BIDI_MIRRORED
3185  * @see u_isMirrored
3186  * @stable ICU 2.0
3187  */
3188 U_CAPI UChar32 U_EXPORT2
3189 u_charMirror(UChar32 c);
3190 
3191 /**
3192  * Maps the specified character to its paired bracket character.
3193  * For Bidi_Paired_Bracket_Type!=None, this is the same as u_charMirror().
3194  * Otherwise c itself is returned.
3195  * See http://www.unicode.org/reports/tr9/
3196  *
3197  * @param c the code point to be mapped
3198  * @return the paired bracket code point,
3199  *         or c itself if there is no such mapping
3200  *         (Bidi_Paired_Bracket_Type=None)
3201  *
3202  * @see UCHAR_BIDI_PAIRED_BRACKET
3203  * @see UCHAR_BIDI_PAIRED_BRACKET_TYPE
3204  * @see u_charMirror
3205  * @stable ICU 52
3206  */
3207 U_CAPI UChar32 U_EXPORT2
3208 u_getBidiPairedBracket(UChar32 c);
3209 
3210 /**
3211  * Returns the general category value for the code point.
3212  *
3213  * Same as java.lang.Character.getType().
3214  *
3215  * @param c the code point to be tested
3216  * @return the general category (UCharCategory) value
3217  *
3218  * @see UCharCategory
3219  * @stable ICU 2.0
3220  */
3221 U_CAPI int8_t U_EXPORT2
3222 u_charType(UChar32 c);
3223 
3224 /**
3225  * Get a single-bit bit set for the general category of a character.
3226  * This bit set can be compared bitwise with U_GC_SM_MASK, U_GC_L_MASK, etc.
3227  * Same as U_MASK(u_charType(c)).
3228  *
3229  * @param c the code point to be tested
3230  * @return a single-bit mask corresponding to the general category (UCharCategory) value
3231  *
3232  * @see u_charType
3233  * @see UCharCategory
3234  * @see U_GC_CN_MASK
3235  * @stable ICU 2.1
3236  */
3237 #define U_GET_GC_MASK(c) U_MASK(u_charType(c))
3238 
3239 /**
3240  * Callback from u_enumCharTypes(), is called for each contiguous range
3241  * of code points c (where start<=c<limit)
3242  * with the same Unicode general category ("character type").
3243  *
3244  * The callback function can stop the enumeration by returning false.
3245  *
3246  * @param context an opaque pointer, as passed into utrie_enum()
3247  * @param start the first code point in a contiguous range with value
3248  * @param limit one past the last code point in a contiguous range with value
3249  * @param type the general category for all code points in [start..limit[
3250  * @return false to stop the enumeration
3251  *
3252  * @stable ICU 2.1
3253  * @see UCharCategory
3254  * @see u_enumCharTypes
3255  */
3256 typedef UBool U_CALLCONV
3257 UCharEnumTypeRange(const void *context, UChar32 start, UChar32 limit, UCharCategory type);
3258 
3259 /**
3260  * Enumerate efficiently all code points with their Unicode general categories.
3261  *
3262  * This is useful for building data structures (e.g., UnicodeSet's),
3263  * for enumerating all assigned code points (type!=U_UNASSIGNED), etc.
3264  *
3265  * For each contiguous range of code points with a given general category ("character type"),
3266  * the UCharEnumTypeRange function is called.
3267  * Adjacent ranges have different types.
3268  * The Unicode Standard guarantees that the numeric value of the type is 0..31.
3269  *
3270  * @param enumRange a pointer to a function that is called for each contiguous range
3271  *                  of code points with the same general category
3272  * @param context an opaque pointer that is passed on to the callback function
3273  *
3274  * @stable ICU 2.1
3275  * @see UCharCategory
3276  * @see UCharEnumTypeRange
3277  */
3278 U_CAPI void U_EXPORT2
3279 u_enumCharTypes(UCharEnumTypeRange *enumRange, const void *context);
3280 
3281 #if !UCONFIG_NO_NORMALIZATION
3282 
3283 /**
3284  * Returns the combining class of the code point as specified in UnicodeData.txt.
3285  *
3286  * @param c the code point of the character
3287  * @return the combining class of the character
3288  * @stable ICU 2.0
3289  */
3290 U_CAPI uint8_t U_EXPORT2
3291 u_getCombiningClass(UChar32 c);
3292 
3293 #endif
3294 
3295 /**
3296  * Returns the decimal digit value of a decimal digit character.
3297  * Such characters have the general category "Nd" (decimal digit numbers)
3298  * and a Numeric_Type of Decimal.
3299  *
3300  * Unlike ICU releases before 2.6, no digit values are returned for any
3301  * Han characters because Han number characters are often used with a special
3302  * Chinese-style number format (with characters for powers of 10 in between)
3303  * instead of in decimal-positional notation.
3304  * Unicode 4 explicitly assigns Han number characters the Numeric_Type
3305  * Numeric instead of Decimal.
3306  * See Jitterbug 1483 for more details.
3307  *
3308  * Use u_getIntPropertyValue(c, UCHAR_NUMERIC_TYPE) and u_getNumericValue()
3309  * for complete numeric Unicode properties.
3310  *
3311  * @param c the code point for which to get the decimal digit value
3312  * @return the decimal digit value of c,
3313  *         or -1 if c is not a decimal digit character
3314  *
3315  * @see u_getNumericValue
3316  * @stable ICU 2.0
3317  */
3318 U_CAPI int32_t U_EXPORT2
3319 u_charDigitValue(UChar32 c);
3320 
3321 /**
3322  * Returns the Unicode allocation block that contains the character.
3323  *
3324  * @param c the code point to be tested
3325  * @return the block value (UBlockCode) for c
3326  *
3327  * @see UBlockCode
3328  * @stable ICU 2.0
3329  */
3330 U_CAPI UBlockCode U_EXPORT2
3331 ublock_getCode(UChar32 c);
3332 
3333 /**
3334  * Retrieve the name of a Unicode character.
3335  * Depending on <code>nameChoice</code>, the character name written
3336  * into the buffer is the "modern" name or the name that was defined
3337  * in Unicode version 1.0.
3338  * The name contains only "invariant" characters
3339  * like A-Z, 0-9, space, and '-'.
3340  * Unicode 1.0 names are only retrieved if they are different from the modern
3341  * names and if the data file contains the data for them. gennames may or may
3342  * not be called with a command line option to include 1.0 names in unames.dat.
3343  *
3344  * @param code The character (code point) for which to get the name.
3345  *             It must be <code>0<=code<=0x10ffff</code>.
3346  * @param nameChoice Selector for which name to get.
3347  * @param buffer Destination address for copying the name.
3348  *               The name will always be zero-terminated.
3349  *               If there is no name, then the buffer will be set to the empty string.
3350  * @param bufferLength <code>==sizeof(buffer)</code>
3351  * @param pErrorCode Pointer to a UErrorCode variable;
3352  *        check for <code>U_SUCCESS()</code> after <code>u_charName()</code>
3353  *        returns.
3354  * @return The length of the name, or 0 if there is no name for this character.
3355  *         If the bufferLength is less than or equal to the length, then the buffer
3356  *         contains the truncated name and the returned length indicates the full
3357  *         length of the name.
3358  *         The length does not include the zero-termination.
3359  *
3360  * @see UCharNameChoice
3361  * @see u_charFromName
3362  * @see u_enumCharNames
3363  * @stable ICU 2.0
3364  */
3365 U_CAPI int32_t U_EXPORT2
3366 u_charName(UChar32 code, UCharNameChoice nameChoice,
3367            char *buffer, int32_t bufferLength,
3368            UErrorCode *pErrorCode);
3369 
3370 /**
3371  * Find a Unicode character by its name and return its code point value.
3372  * The name is matched exactly and completely.
3373  * If the name does not correspond to a code point, <i>pErrorCode</i>
3374  * is set to <code>U_INVALID_CHAR_FOUND</code>.
3375  * A Unicode 1.0 name is matched only if it differs from the modern name.
3376  * Unicode names are all uppercase. Extended names are lowercase followed
3377  * by an uppercase hexadecimal number, and within angle brackets.
3378  *
3379  * @param nameChoice Selector for which name to match.
3380  * @param name The name to match.
3381  * @param pErrorCode Pointer to a UErrorCode variable
3382  * @return The Unicode value of the code point with the given name,
3383  *         or an undefined value if there is no such code point.
3384  *
3385  * @see UCharNameChoice
3386  * @see u_charName
3387  * @see u_enumCharNames
3388  * @stable ICU 1.7
3389  */
3390 U_CAPI UChar32 U_EXPORT2
3391 u_charFromName(UCharNameChoice nameChoice,
3392                const char *name,
3393                UErrorCode *pErrorCode);
3394 
3395 /**
3396  * Type of a callback function for u_enumCharNames() that gets called
3397  * for each Unicode character with the code point value and
3398  * the character name.
3399  * If such a function returns false, then the enumeration is stopped.
3400  *
3401  * @param context The context pointer that was passed to u_enumCharNames().
3402  * @param code The Unicode code point for the character with this name.
3403  * @param nameChoice Selector for which kind of names is enumerated.
3404  * @param name The character's name, zero-terminated.
3405  * @param length The length of the name.
3406  * @return true if the enumeration should continue, false to stop it.
3407  *
3408  * @see UCharNameChoice
3409  * @see u_enumCharNames
3410  * @stable ICU 1.7
3411  */
3412 typedef UBool U_CALLCONV UEnumCharNamesFn(void *context,
3413                                UChar32 code,
3414                                UCharNameChoice nameChoice,
3415                                const char *name,
3416                                int32_t length);
3417 
3418 /**
3419  * Enumerate all assigned Unicode characters between the start and limit
3420  * code points (start inclusive, limit exclusive) and call a function
3421  * for each, passing the code point value and the character name.
3422  * For Unicode 1.0 names, only those are enumerated that differ from the
3423  * modern names.
3424  *
3425  * @param start The first code point in the enumeration range.
3426  * @param limit One more than the last code point in the enumeration range
3427  *              (the first one after the range).
3428  * @param fn The function that is to be called for each character name.
3429  * @param context An arbitrary pointer that is passed to the function.
3430  * @param nameChoice Selector for which kind of names to enumerate.
3431  * @param pErrorCode Pointer to a UErrorCode variable
3432  *
3433  * @see UCharNameChoice
3434  * @see UEnumCharNamesFn
3435  * @see u_charName
3436  * @see u_charFromName
3437  * @stable ICU 1.7
3438  */
3439 U_CAPI void U_EXPORT2
3440 u_enumCharNames(UChar32 start, UChar32 limit,
3441                 UEnumCharNamesFn *fn,
3442                 void *context,
3443                 UCharNameChoice nameChoice,
3444                 UErrorCode *pErrorCode);
3445 
3446 /**
3447  * Return the Unicode name for a given property, as given in the
3448  * Unicode database file PropertyAliases.txt.
3449  *
3450  * In addition, this function maps the property
3451  * UCHAR_GENERAL_CATEGORY_MASK to the synthetic names "gcm" /
3452  * "General_Category_Mask".  These names are not in
3453  * PropertyAliases.txt.
3454  *
3455  * @param property UProperty selector other than UCHAR_INVALID_CODE.
3456  *         If out of range, NULL is returned.
3457  *
3458  * @param nameChoice selector for which name to get.  If out of range,
3459  *         NULL is returned.  All properties have a long name.  Most
3460  *         have a short name, but some do not.  Unicode allows for
3461  *         additional names; if present these will be returned by
3462  *         U_LONG_PROPERTY_NAME + i, where i=1, 2,...
3463  *
3464  * @return a pointer to the name, or NULL if either the
3465  *         property or the nameChoice is out of range.  If a given
3466  *         nameChoice returns NULL, then all larger values of
3467  *         nameChoice will return NULL, with one exception: if NULL is
3468  *         returned for U_SHORT_PROPERTY_NAME, then
3469  *         U_LONG_PROPERTY_NAME (and higher) may still return a
3470  *         non-NULL value.  The returned pointer is valid until
3471  *         u_cleanup() is called.
3472  *
3473  * @see UProperty
3474  * @see UPropertyNameChoice
3475  * @stable ICU 2.4
3476  */
3477 U_CAPI const char* U_EXPORT2
3478 u_getPropertyName(UProperty property,
3479                   UPropertyNameChoice nameChoice);
3480 
3481 /**
3482  * Return the UProperty enum for a given property name, as specified
3483  * in the Unicode database file PropertyAliases.txt.  Short, long, and
3484  * any other variants are recognized.
3485  *
3486  * In addition, this function maps the synthetic names "gcm" /
3487  * "General_Category_Mask" to the property
3488  * UCHAR_GENERAL_CATEGORY_MASK.  These names are not in
3489  * PropertyAliases.txt.
3490  *
3491  * @param alias the property name to be matched.  The name is compared
3492  *         using "loose matching" as described in PropertyAliases.txt.
3493  *
3494  * @return a UProperty enum, or UCHAR_INVALID_CODE if the given name
3495  *         does not match any property.
3496  *
3497  * @see UProperty
3498  * @stable ICU 2.4
3499  */
3500 U_CAPI UProperty U_EXPORT2
3501 u_getPropertyEnum(const char* alias);
3502 
3503 /**
3504  * Return the Unicode name for a given property value, as given in the
3505  * Unicode database file PropertyValueAliases.txt.
3506  *
3507  * Note: Some of the names in PropertyValueAliases.txt can only be
3508  * retrieved using UCHAR_GENERAL_CATEGORY_MASK, not
3509  * UCHAR_GENERAL_CATEGORY.  These include: "C" / "Other", "L" /
3510  * "Letter", "LC" / "Cased_Letter", "M" / "Mark", "N" / "Number", "P"
3511  * / "Punctuation", "S" / "Symbol", and "Z" / "Separator".
3512  *
3513  * @param property UProperty selector constant.
3514  *        Must be UCHAR_BINARY_START<=which<UCHAR_BINARY_LIMIT
3515  *        or UCHAR_INT_START<=which<UCHAR_INT_LIMIT
3516  *        or UCHAR_MASK_START<=which<UCHAR_MASK_LIMIT.
3517  *        If out of range, NULL is returned.
3518  *
3519  * @param value selector for a value for the given property.  If out
3520  *         of range, NULL is returned.  In general, valid values range
3521  *         from 0 up to some maximum.  There are a few exceptions:
3522  *         (1.) UCHAR_BLOCK values begin at the non-zero value
3523  *         UBLOCK_BASIC_LATIN.  (2.)  UCHAR_CANONICAL_COMBINING_CLASS
3524  *         values are not contiguous and range from 0..240.  (3.)
3525  *         UCHAR_GENERAL_CATEGORY_MASK values are not values of
3526  *         UCharCategory, but rather mask values produced by
3527  *         U_GET_GC_MASK().  This allows grouped categories such as
3528  *         [:L:] to be represented.  Mask values range
3529  *         non-contiguously from 1..U_GC_P_MASK.
3530  *
3531  * @param nameChoice selector for which name to get.  If out of range,
3532  *         NULL is returned.  All values have a long name.  Most have
3533  *         a short name, but some do not.  Unicode allows for
3534  *         additional names; if present these will be returned by
3535  *         U_LONG_PROPERTY_NAME + i, where i=1, 2,...
3536 
3537  * @return a pointer to the name, or NULL if either the
3538  *         property or the nameChoice is out of range.  If a given
3539  *         nameChoice returns NULL, then all larger values of
3540  *         nameChoice will return NULL, with one exception: if NULL is
3541  *         returned for U_SHORT_PROPERTY_NAME, then
3542  *         U_LONG_PROPERTY_NAME (and higher) may still return a
3543  *         non-NULL value.  The returned pointer is valid until
3544  *         u_cleanup() is called.
3545  *
3546  * @see UProperty
3547  * @see UPropertyNameChoice
3548  * @stable ICU 2.4
3549  */
3550 U_CAPI const char* U_EXPORT2
3551 u_getPropertyValueName(UProperty property,
3552                        int32_t value,
3553                        UPropertyNameChoice nameChoice);
3554 
3555 /**
3556  * Return the property value integer for a given value name, as
3557  * specified in the Unicode database file PropertyValueAliases.txt.
3558  * Short, long, and any other variants are recognized.
3559  *
3560  * Note: Some of the names in PropertyValueAliases.txt will only be
3561  * recognized with UCHAR_GENERAL_CATEGORY_MASK, not
3562  * UCHAR_GENERAL_CATEGORY.  These include: "C" / "Other", "L" /
3563  * "Letter", "LC" / "Cased_Letter", "M" / "Mark", "N" / "Number", "P"
3564  * / "Punctuation", "S" / "Symbol", and "Z" / "Separator".
3565  *
3566  * @param property UProperty selector constant.
3567  *        Must be UCHAR_BINARY_START<=which<UCHAR_BINARY_LIMIT
3568  *        or UCHAR_INT_START<=which<UCHAR_INT_LIMIT
3569  *        or UCHAR_MASK_START<=which<UCHAR_MASK_LIMIT.
3570  *        If out of range, UCHAR_INVALID_CODE is returned.
3571  *
3572  * @param alias the value name to be matched.  The name is compared
3573  *         using "loose matching" as described in
3574  *         PropertyValueAliases.txt.
3575  *
3576  * @return a value integer or UCHAR_INVALID_CODE if the given name
3577  *         does not match any value of the given property, or if the
3578  *         property is invalid.  Note: UCHAR_GENERAL_CATEGORY_MASK values
3579  *         are not values of UCharCategory, but rather mask values
3580  *         produced by U_GET_GC_MASK().  This allows grouped
3581  *         categories such as [:L:] to be represented.
3582  *
3583  * @see UProperty
3584  * @stable ICU 2.4
3585  */
3586 U_CAPI int32_t U_EXPORT2
3587 u_getPropertyValueEnum(UProperty property,
3588                        const char* alias);
3589 
3590 /**
3591  * Determines if the specified character is permissible as the
3592  * first character in an identifier according to Unicode
3593  * (The Unicode Standard, Version 3.0, chapter 5.16 Identifiers).
3594  * True for characters with general categories "L" (letters) and "Nl" (letter numbers).
3595  *
3596  * Same as java.lang.Character.isUnicodeIdentifierStart().
3597  * Same as UCHAR_ID_START
3598  *
3599  * @param c the code point to be tested
3600  * @return true if the code point may start an identifier
3601  *
3602  * @see UCHAR_ID_START
3603  * @see u_isalpha
3604  * @see u_isIDPart
3605  * @stable ICU 2.0
3606  */
3607 U_CAPI UBool U_EXPORT2
3608 u_isIDStart(UChar32 c);
3609 
3610 /**
3611  * Determines if the specified character is permissible
3612  * in an identifier according to Java.
3613  * True for characters with general categories "L" (letters),
3614  * "Nl" (letter numbers), "Nd" (decimal digits),
3615  * "Mc" and "Mn" (combining marks), "Pc" (connecting punctuation), and
3616  * u_isIDIgnorable(c).
3617  *
3618  * Same as java.lang.Character.isUnicodeIdentifierPart().
3619  * Almost the same as Unicode's ID_Continue (UCHAR_ID_CONTINUE)
3620  * except that Unicode recommends to ignore Cf which is less than
3621  * u_isIDIgnorable(c).
3622  *
3623  * @param c the code point to be tested
3624  * @return true if the code point may occur in an identifier according to Java
3625  *
3626  * @see UCHAR_ID_CONTINUE
3627  * @see u_isIDStart
3628  * @see u_isIDIgnorable
3629  * @stable ICU 2.0
3630  */
3631 U_CAPI UBool U_EXPORT2
3632 u_isIDPart(UChar32 c);
3633 
3634 /**
3635  * Determines if the specified character should be regarded
3636  * as an ignorable character in an identifier,
3637  * according to Java.
3638  * True for characters with general category "Cf" (format controls) as well as
3639  * non-whitespace ISO controls
3640  * (U+0000..U+0008, U+000E..U+001B, U+007F..U+009F).
3641  *
3642  * Same as java.lang.Character.isIdentifierIgnorable().
3643  *
3644  * Note that Unicode just recommends to ignore Cf (format controls).
3645  *
3646  * @param c the code point to be tested
3647  * @return true if the code point is ignorable in identifiers according to Java
3648  *
3649  * @see UCHAR_DEFAULT_IGNORABLE_CODE_POINT
3650  * @see u_isIDStart
3651  * @see u_isIDPart
3652  * @stable ICU 2.0
3653  */
3654 U_CAPI UBool U_EXPORT2
3655 u_isIDIgnorable(UChar32 c);
3656 
3657 /**
3658  * Determines if the specified character is permissible as the
3659  * first character in a Java identifier.
3660  * In addition to u_isIDStart(c), true for characters with
3661  * general categories "Sc" (currency symbols) and "Pc" (connecting punctuation).
3662  *
3663  * Same as java.lang.Character.isJavaIdentifierStart().
3664  *
3665  * @param c the code point to be tested
3666  * @return true if the code point may start a Java identifier
3667  *
3668  * @see     u_isJavaIDPart
3669  * @see     u_isalpha
3670  * @see     u_isIDStart
3671  * @stable ICU 2.0
3672  */
3673 U_CAPI UBool U_EXPORT2
3674 u_isJavaIDStart(UChar32 c);
3675 
3676 /**
3677  * Determines if the specified character is permissible
3678  * in a Java identifier.
3679  * In addition to u_isIDPart(c), true for characters with
3680  * general category "Sc" (currency symbols).
3681  *
3682  * Same as java.lang.Character.isJavaIdentifierPart().
3683  *
3684  * @param c the code point to be tested
3685  * @return true if the code point may occur in a Java identifier
3686  *
3687  * @see     u_isIDIgnorable
3688  * @see     u_isJavaIDStart
3689  * @see     u_isalpha
3690  * @see     u_isdigit
3691  * @see     u_isIDPart
3692  * @stable ICU 2.0
3693  */
3694 U_CAPI UBool U_EXPORT2
3695 u_isJavaIDPart(UChar32 c);
3696 
3697 /**
3698  * The given character is mapped to its lowercase equivalent according to
3699  * UnicodeData.txt; if the character has no lowercase equivalent, the character
3700  * itself is returned.
3701  *
3702  * Same as java.lang.Character.toLowerCase().
3703  *
3704  * This function only returns the simple, single-code point case mapping.
3705  * Full case mappings should be used whenever possible because they produce
3706  * better results by working on whole strings.
3707  * They take into account the string context and the language and can map
3708  * to a result string with a different length as appropriate.
3709  * Full case mappings are applied by the string case mapping functions,
3710  * see ustring.h and the UnicodeString class.
3711  * See also the User Guide chapter on C/POSIX migration:
3712  * https://unicode-org.github.io/icu/userguide/icu/posix#case-mappings
3713  *
3714  * @param c the code point to be mapped
3715  * @return the Simple_Lowercase_Mapping of the code point, if any;
3716  *         otherwise the code point itself.
3717  * @stable ICU 2.0
3718  */
3719 U_CAPI UChar32 U_EXPORT2
3720 u_tolower(UChar32 c);
3721 
3722 /**
3723  * The given character is mapped to its uppercase equivalent according to UnicodeData.txt;
3724  * if the character has no uppercase equivalent, the character itself is
3725  * returned.
3726  *
3727  * Same as java.lang.Character.toUpperCase().
3728  *
3729  * This function only returns the simple, single-code point case mapping.
3730  * Full case mappings should be used whenever possible because they produce
3731  * better results by working on whole strings.
3732  * They take into account the string context and the language and can map
3733  * to a result string with a different length as appropriate.
3734  * Full case mappings are applied by the string case mapping functions,
3735  * see ustring.h and the UnicodeString class.
3736  * See also the User Guide chapter on C/POSIX migration:
3737  * https://unicode-org.github.io/icu/userguide/icu/posix#case-mappings
3738  *
3739  * @param c the code point to be mapped
3740  * @return the Simple_Uppercase_Mapping of the code point, if any;
3741  *         otherwise the code point itself.
3742  * @stable ICU 2.0
3743  */
3744 U_CAPI UChar32 U_EXPORT2
3745 u_toupper(UChar32 c);
3746 
3747 /**
3748  * The given character is mapped to its titlecase equivalent
3749  * according to UnicodeData.txt;
3750  * if none is defined, the character itself is returned.
3751  *
3752  * Same as java.lang.Character.toTitleCase().
3753  *
3754  * This function only returns the simple, single-code point case mapping.
3755  * Full case mappings should be used whenever possible because they produce
3756  * better results by working on whole strings.
3757  * They take into account the string context and the language and can map
3758  * to a result string with a different length as appropriate.
3759  * Full case mappings are applied by the string case mapping functions,
3760  * see ustring.h and the UnicodeString class.
3761  * See also the User Guide chapter on C/POSIX migration:
3762  * https://unicode-org.github.io/icu/userguide/icu/posix#case-mappings
3763  *
3764  * @param c the code point to be mapped
3765  * @return the Simple_Titlecase_Mapping of the code point, if any;
3766  *         otherwise the code point itself.
3767  * @stable ICU 2.0
3768  */
3769 U_CAPI UChar32 U_EXPORT2
3770 u_totitle(UChar32 c);
3771 
3772 /**
3773  * The given character is mapped to its case folding equivalent according to
3774  * UnicodeData.txt and CaseFolding.txt;
3775  * if the character has no case folding equivalent, the character
3776  * itself is returned.
3777  *
3778  * This function only returns the simple, single-code point case mapping.
3779  * Full case mappings should be used whenever possible because they produce
3780  * better results by working on whole strings.
3781  * They take into account the string context and the language and can map
3782  * to a result string with a different length as appropriate.
3783  * Full case mappings are applied by the string case mapping functions,
3784  * see ustring.h and the UnicodeString class.
3785  * See also the User Guide chapter on C/POSIX migration:
3786  * https://unicode-org.github.io/icu/userguide/icu/posix#case-mappings
3787  *
3788  * @param c the code point to be mapped
3789  * @param options Either U_FOLD_CASE_DEFAULT or U_FOLD_CASE_EXCLUDE_SPECIAL_I
3790  * @return the Simple_Case_Folding of the code point, if any;
3791  *         otherwise the code point itself.
3792  * @stable ICU 2.0
3793  */
3794 U_CAPI UChar32 U_EXPORT2
3795 u_foldCase(UChar32 c, uint32_t options);
3796 
3797 /**
3798  * Returns the decimal digit value of the code point in the
3799  * specified radix.
3800  *
3801  * If the radix is not in the range <code>2<=radix<=36</code> or if the
3802  * value of <code>c</code> is not a valid digit in the specified
3803  * radix, <code>-1</code> is returned. A character is a valid digit
3804  * if at least one of the following is true:
3805  * <ul>
3806  * <li>The character has a decimal digit value.
3807  *     Such characters have the general category "Nd" (decimal digit numbers)
3808  *     and a Numeric_Type of Decimal.
3809  *     In this case the value is the character's decimal digit value.</li>
3810  * <li>The character is one of the uppercase Latin letters
3811  *     <code>'A'</code> through <code>'Z'</code>.
3812  *     In this case the value is <code>c-'A'+10</code>.</li>
3813  * <li>The character is one of the lowercase Latin letters
3814  *     <code>'a'</code> through <code>'z'</code>.
3815  *     In this case the value is <code>ch-'a'+10</code>.</li>
3816  * <li>Latin letters from both the ASCII range (0061..007A, 0041..005A)
3817  *     as well as from the Fullwidth ASCII range (FF41..FF5A, FF21..FF3A)
3818  *     are recognized.</li>
3819  * </ul>
3820  *
3821  * Same as java.lang.Character.digit().
3822  *
3823  * @param   ch      the code point to be tested.
3824  * @param   radix   the radix.
3825  * @return  the numeric value represented by the character in the
3826  *          specified radix,
3827  *          or -1 if there is no value or if the value exceeds the radix.
3828  *
3829  * @see     UCHAR_NUMERIC_TYPE
3830  * @see     u_forDigit
3831  * @see     u_charDigitValue
3832  * @see     u_isdigit
3833  * @stable ICU 2.0
3834  */
3835 U_CAPI int32_t U_EXPORT2
3836 u_digit(UChar32 ch, int8_t radix);
3837 
3838 /**
3839  * Determines the character representation for a specific digit in
3840  * the specified radix. If the value of <code>radix</code> is not a
3841  * valid radix, or the value of <code>digit</code> is not a valid
3842  * digit in the specified radix, the null character
3843  * (<code>U+0000</code>) is returned.
3844  * <p>
3845  * The <code>radix</code> argument is valid if it is greater than or
3846  * equal to 2 and less than or equal to 36.
3847  * The <code>digit</code> argument is valid if
3848  * <code>0 <= digit < radix</code>.
3849  * <p>
3850  * If the digit is less than 10, then
3851  * <code>'0' + digit</code> is returned. Otherwise, the value
3852  * <code>'a' + digit - 10</code> is returned.
3853  *
3854  * Same as java.lang.Character.forDigit().
3855  *
3856  * @param   digit   the number to convert to a character.
3857  * @param   radix   the radix.
3858  * @return  the <code>char</code> representation of the specified digit
3859  *          in the specified radix.
3860  *
3861  * @see     u_digit
3862  * @see     u_charDigitValue
3863  * @see     u_isdigit
3864  * @stable ICU 2.0
3865  */
3866 U_CAPI UChar32 U_EXPORT2
3867 u_forDigit(int32_t digit, int8_t radix);
3868 
3869 #if !UCONFIG_NO_NORMALIZATION
3870 /**
3871  * Get the FC_NFKC_Closure property string for a character.
3872  * See Unicode Standard Annex #15 for details, search for "FC_NFKC_Closure"
3873  * or for "FNC": http://www.unicode.org/reports/tr15/
3874  *
3875  * @param c The character (code point) for which to get the FC_NFKC_Closure string.
3876  *             It must be <code>0<=c<=0x10ffff</code>.
3877  * @param dest Destination address for copying the string.
3878  *             The string will be zero-terminated if possible.
3879  *             If there is no FC_NFKC_Closure string,
3880  *             then the buffer will be set to the empty string.
3881  * @param destCapacity <code>==sizeof(dest)</code>
3882  * @param pErrorCode Pointer to a UErrorCode variable.
3883  * @return The length of the string, or 0 if there is no FC_NFKC_Closure string for this character.
3884  *         If the destCapacity is less than or equal to the length, then the buffer
3885  *         contains the truncated name and the returned length indicates the full
3886  *         length of the name.
3887  *         The length does not include the zero-termination.
3888  *
3889  * @stable ICU 2.2
3890  */
3891 U_CAPI int32_t U_EXPORT2
3892 u_getFC_NFKC_Closure(UChar32 c, UChar *dest, int32_t destCapacity, UErrorCode *pErrorCode);
3893 
3894 #endif
3895 
3896 
3897 U_CDECL_END
3898 
3899 #endif /*_UCHAR*/
3900 /*eof*/
3901