Home
last modified time | relevance | path

Searched refs:TrieMap (Results 1 – 5 of 5) sorted by relevance

/packages/inputmethods/LatinIME/native/jni/src/dictionary/utils/
Dtrie_map.cpp23 const int TrieMap::INVALID_INDEX = -1;
24 const int TrieMap::FIELD0_SIZE = 4;
25 const int TrieMap::FIELD1_SIZE = 3;
26 const int TrieMap::ENTRY_SIZE = FIELD0_SIZE + FIELD1_SIZE;
27 const uint32_t TrieMap::VALUE_FLAG = 0x400000;
28 const uint32_t TrieMap::VALUE_MASK = 0x3FFFFF;
29 const uint32_t TrieMap::INVALID_VALUE_IN_KEY_VALUE_ENTRY = VALUE_MASK;
30 const uint32_t TrieMap::TERMINAL_LINK_FLAG = 0x800000;
31 const uint32_t TrieMap::TERMINAL_LINK_MASK = 0x7FFFFF;
32 const int TrieMap::NUM_OF_BITS_USED_FOR_ONE_LEVEL = 5;
[all …]
Dtrie_map.h37 class TrieMap {
66 IterationResult(const TrieMap *const trieMap, const int key, const uint64_t value, in IterationResult()
92 const TrieMap *const mTrieMap;
98 TrieMapIterator(const TrieMap *const trieMap, const int bitmapEntryIndex) in TrieMapIterator()
131 const TrieMap *const mTrieMap;
132 std::vector<TrieMap::TableIterationState> mStateStack;
145 TrieMapRange(const TrieMap *const trieMap, const int bitmapEntryIndex) in TrieMapRange()
160 const TrieMap *const mTrieMap;
167 TrieMap();
169 TrieMap(const ReadWriteByteArrayView buffer);
[all …]
/packages/inputmethods/LatinIME/native/jni/tests/dictionary/utils/
Dtrie_map_test.cpp32 TrieMap trieMap; in TEST()
52 TrieMap trieMap; in TEST()
70 const TrieMap::Result result = trieMap.getRoot(10); in TEST()
72 EXPECT_EQ(TrieMap::INVALID_INDEX, result.mNextLevelBitmapEntryIndex); in TEST()
80 TrieMap trieMap; in TEST()
91 TrieMap trieMap; in TEST()
99 std::uniform_int_distribution<uint64_t> valueDistribution(0, TrieMap::MAX_VALUE); in TEST()
118 TrieMap trieMap; in TEST()
131 std::uniform_int_distribution<uint64_t> valueDistribution(0, TrieMap::MAX_VALUE); in TEST()
148 EXPECT_NE(TrieMap::INVALID_INDEX, nextLevelBitmapEntryIndex); in TEST()
[all …]
/packages/inputmethods/LatinIME/native/jni/src/dictionary/structure/v4/content/
Dlanguage_model_dict_content.cpp51 if (nextBitmapEntryIndex == TrieMap::INVALID_INDEX) { in getWordAttributes()
67 const TrieMap::Result result = mTrieMap.get(wordId, bitmapEntryIndices[i]); in getWordAttributes()
120 if (bitmapEntryIndex == TrieMap::INVALID_INDEX) { in getNgramProbabilityEntry()
123 const TrieMap::Result result = mTrieMap.get(wordId, bitmapEntryIndex); in getNgramProbabilityEntry()
137 if (bitmapEntryIndex == TrieMap::INVALID_INDEX) { in setNgramProbabilityEntry()
146 if (bitmapEntryIndex == TrieMap::INVALID_INDEX) { in removeNgramProbabilityEntry()
162 const TrieMap::Result result = mTrieMap.getRoot(wordId); in exportAllNgramEntriesRelatedToWord()
163 if (!result.mIsValid || result.mNextLevelBitmapEntryIndex == TrieMap::INVALID_INDEX) { in exportAllNgramEntriesRelatedToWord()
276 const TrieMap::TrieMapRange trieMapRange, const int nextLevelBitmapEntryIndex) { in runGCInner()
299 const TrieMap::Result result = mTrieMap.get(wordId, lastBitmapEntryIndex); in createAndGetBitmapEntryIndex()
[all …]
Dlanguage_model_dict_content.h65 EntryIterator(const TrieMap::TrieMapIterator &trieMapIterator, in EntryIterator()
70 const TrieMap::TrieMapIterator::IterationResult &result = *mTrieMapIterator;
88 TrieMap::TrieMapIterator mTrieMapIterator;
95 EntryRange(const TrieMap::TrieMapRange trieMapRange, const bool hasHistoricalInfo) in EntryRange()
110 const TrieMap::TrieMapRange mTrieMapRange;
234 TrieMap mTrieMap;
239 const TrieMap::TrieMapRange trieMapRange, const int nextLevelBitmapEntryIndex);