]> git.saurik.com Git - apple/icu.git/blob - icuSources/common/uset_imp.h
ICU-8.11.1.tar.gz
[apple/icu.git] / icuSources / common / uset_imp.h
1 /*
2 *******************************************************************************
3 *
4 * Copyright (C) 2004-2005, International Business Machines
5 * Corporation and others. All Rights Reserved.
6 *
7 *******************************************************************************
8 * file name: uset_imp.h
9 * encoding: US-ASCII
10 * tab size: 8 (not used)
11 * indentation:4
12 *
13 * created on: 2004sep07
14 * created by: Markus W. Scherer
15 *
16 * Internal USet definitions.
17 */
18
19 #ifndef __USET_IMP_H__
20 #define __USET_IMP_H__
21
22 #include "unicode/utypes.h"
23 #include "unicode/uset.h"
24
25 U_CDECL_BEGIN
26
27 typedef void U_CALLCONV
28 USetAdd(USet *set, UChar32 c);
29
30 typedef void U_CALLCONV
31 USetAddRange(USet *set, UChar32 start, UChar32 end);
32
33 typedef void U_CALLCONV
34 USetAddString(USet *set, const UChar *str, int32_t length);
35
36 typedef void U_CALLCONV
37 USetRemove(USet *set, UChar32 c);
38
39 /**
40 * Interface for adding items to a USet, to keep low-level code from
41 * statically depending on the USet implementation.
42 * Calls will look like sa->add(sa->set, c);
43 */
44 struct USetAdder {
45 USet *set;
46 USetAdd *add;
47 USetAddRange *addRange;
48 USetAddString *addString;
49 USetRemove *remove;
50 };
51 typedef struct USetAdder USetAdder;
52
53 U_CDECL_END
54
55 /**
56 * Get the set of "white space" characters in the sense of ICU rule
57 * parsers. Caller must close/delete result.
58 * Equivalent to the set of characters with the Pattern_White_Space Unicode property.
59 * Stable set of characters, won't change.
60 * See UAX #31 Identifier and Pattern Syntax: http://www.unicode.org/reports/tr31/
61 * @internal
62 */
63 U_CAPI USet* U_EXPORT2
64 uprv_openRuleWhiteSpaceSet(UErrorCode* ec);
65
66 #endif
67