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
00050 typedef struct UMutableCPTrie UMutableCPTrie;
00051
00065 U_CAPI UMutableCPTrie * U_EXPORT2
00066 umutablecptrie_open(uint32_t initialValue, uint32_t errorValue, UErrorCode *pErrorCode);
00067
00077 U_CAPI UMutableCPTrie * U_EXPORT2
00078 umutablecptrie_clone(const UMutableCPTrie *other, UErrorCode *pErrorCode);
00079
00086 U_CAPI void U_EXPORT2
00087 umutablecptrie_close(UMutableCPTrie *trie);
00088
00098 U_CAPI UMutableCPTrie * U_EXPORT2
00099 umutablecptrie_fromUCPMap(const UCPMap *map, UErrorCode *pErrorCode);
00100
00110 U_CAPI UMutableCPTrie * U_EXPORT2
00111 umutablecptrie_fromUCPTrie(const UCPTrie *trie, UErrorCode *pErrorCode);
00112
00121 U_CAPI uint32_t U_EXPORT2
00122 umutablecptrie_get(const UMutableCPTrie *trie, UChar32 c);
00123
00153 U_CAPI UChar32 U_EXPORT2
00154 umutablecptrie_getRange(const UMutableCPTrie *trie, UChar32 start,
00155 UCPMapRangeOption option, uint32_t surrogateValue,
00156 UCPMapValueFilter *filter, const void *context, uint32_t *pValue);
00157
00167 U_CAPI void U_EXPORT2
00168 umutablecptrie_set(UMutableCPTrie *trie, UChar32 c, uint32_t value, UErrorCode *pErrorCode);
00169
00181 U_CAPI void U_EXPORT2
00182 umutablecptrie_setRange(UMutableCPTrie *trie,
00183 UChar32 start, UChar32 end,
00184 uint32_t value, UErrorCode *pErrorCode);
00185
00216 U_CAPI UCPTrie * U_EXPORT2
00217 umutablecptrie_buildImmutable(UMutableCPTrie *trie, UCPTrieType type, UCPTrieValueWidth valueWidth,
00218 UErrorCode *pErrorCode);
00219
00220 U_CDECL_END
00221
00222 #if U_SHOW_CPLUSPLUS_API
00223
00224 U_NAMESPACE_BEGIN
00225
00235 U_DEFINE_LOCAL_OPEN_POINTER(LocalUMutableCPTriePointer, UMutableCPTrie, umutablecptrie_close);
00236
00237 U_NAMESPACE_END
00238
00239 #endif
00240
00241 #endif