#define RBBISETB_H
#include "unicode/utypes.h"
+
+#if !UCONFIG_NO_BREAK_ITERATION
+
#include "unicode/uobject.h"
#include "rbbirb.h"
+#include "utrie2.h"
#include "uvector.h"
-struct UNewTrie;
-
U_NAMESPACE_BEGIN
//
RBBISetBuilder(RBBIRuleBuilder *rb);
~RBBISetBuilder();
- void build();
+ void buildRanges();
+ void buildTrie();
void addValToSets(UVector *sets, uint32_t val);
void addValToSet (RBBINode *usetNode, uint32_t val);
int32_t getNumCharCategories() const; // CharCategories are the same as input symbol set to the
UChar32 getFirstChar(int32_t val) const;
UBool sawBOF() const; // Indicate whether any references to the {bof} pseudo
// character were encountered.
+ /**
+ * Merge two character categories that have been identified as having equivalent behavior.
+ * The ranges belonging to the second category (table column) will be added to the first.
+ * @param categories the pair of categories to be merged.
+ */
+ void mergeCategories(IntPair categories);
+
+ static constexpr int32_t DICT_BIT = 0x4000;
+
#ifdef RBBI_DEBUG
void printSets();
void printRanges();
RangeDescriptor *fRangeList; // Head of the linked list of RangeDescriptors
- UNewTrie *fTrie; // The mapping TRIE that is the end result of processing
- uint32_t fTrieSize; // the Unicode Sets.
+ UTrie2 *fTrie; // The mapping TRIE that is the end result of processing
+ uint32_t fTrieSize; // the Unicode Sets.
// Groups correspond to character categories -
// groups of ranges that are in the same original UnicodeSets.
U_NAMESPACE_END
+
+#endif /* #if !UCONFIG_NO_BREAK_ITERATION */
+
#endif