00001
00002
00003
00004
00005
00006
00007 #ifndef __UMUTABLECPTRIE_H__
00008 #define __UMUTABLECPTRIE_H__
00009
00010 #include "unicode/utypes.h"
00011
00012 #include "unicode/ucpmap.h"
00013 #include "unicode/ucptrie.h"
00014 #include "unicode/utf8.h"
00015
00016 #if U_SHOW_CPLUSPLUS_API
00017 #include "unicode/localpointer.h"
00018 #endif // U_SHOW_CPLUSPLUS_API
00019
00020 U_CDECL_BEGIN
00021
00049 typedef struct UMutableCPTrie UMutableCPTrie;
00050
00064 U_CAPI UMutableCPTrie * U_EXPORT2
00065 umutablecptrie_open(uint32_t initialValue, uint32_t errorValue, UErrorCode *pErrorCode);
00066
00076 U_CAPI UMutableCPTrie * U_EXPORT2
00077 umutablecptrie_clone(const UMutableCPTrie *other, UErrorCode *pErrorCode);
00078
00085 U_CAPI void U_EXPORT2
00086 umutablecptrie_close(UMutableCPTrie *trie);
00087
00097 U_CAPI UMutableCPTrie * U_EXPORT2
00098 umutablecptrie_fromUCPMap(const UCPMap *map, UErrorCode *pErrorCode);
00099
00109 U_CAPI UMutableCPTrie * U_EXPORT2
00110 umutablecptrie_fromUCPTrie(const UCPTrie *trie, UErrorCode *pErrorCode);
00111
00120 U_CAPI uint32_t U_EXPORT2
00121 umutablecptrie_get(const UMutableCPTrie *trie, UChar32 c);
00122
00152 U_CAPI UChar32 U_EXPORT2
00153 umutablecptrie_getRange(const UMutableCPTrie *trie, UChar32 start,
00154 UCPMapRangeOption option, uint32_t surrogateValue,
00155 UCPMapValueFilter *filter, const void *context, uint32_t *pValue);
00156
00166 U_CAPI void U_EXPORT2
00167 umutablecptrie_set(UMutableCPTrie *trie, UChar32 c, uint32_t value, UErrorCode *pErrorCode);
00168
00180 U_CAPI void U_EXPORT2
00181 umutablecptrie_setRange(UMutableCPTrie *trie,
00182 UChar32 start, UChar32 end,
00183 uint32_t value, UErrorCode *pErrorCode);
00184
00215 U_CAPI UCPTrie * U_EXPORT2
00216 umutablecptrie_buildImmutable(UMutableCPTrie *trie, UCPTrieType type, UCPTrieValueWidth valueWidth,
00217 UErrorCode *pErrorCode);
00218
00219 U_CDECL_END
00220
00221 #if U_SHOW_CPLUSPLUS_API
00222
00223 U_NAMESPACE_BEGIN
00224
00234 U_DEFINE_LOCAL_OPEN_POINTER(LocalUMutableCPTriePointer, UMutableCPTrie, umutablecptrie_close);
00235
00236 U_NAMESPACE_END
00237
00238 #endif
00239
00240 #endif