aboutsummaryrefslogtreecommitdiffstats
path: root/native/src/words_priority_queue_pool.h
diff options
context:
space:
mode:
authorsatok <satok@google.com>2012-01-16 00:20:06 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2012-01-16 00:20:06 -0800
commit53c4248c6f33891ec76cd0f5054c00eea2f7957c (patch)
treeb75b4042868fc705a056854d4b33fa9bad533c74 /native/src/words_priority_queue_pool.h
parent65b489cd76e8ae4898bf4788c013f245487cb1d7 (diff)
parent67e13976b78619ec7bc45b5377a9f5da2534cfd5 (diff)
downloadlatinime-53c4248c6f33891ec76cd0f5054c00eea2f7957c.tar.gz
latinime-53c4248c6f33891ec76cd0f5054c00eea2f7957c.tar.xz
latinime-53c4248c6f33891ec76cd0f5054c00eea2f7957c.zip
am 67e13976: Merge "Store suggestions for each input length for missing space algorithm etc."
* commit '67e13976b78619ec7bc45b5377a9f5da2534cfd5': Store suggestions for each input length for missing space algorithm etc.
Diffstat (limited to 'native/src/words_priority_queue_pool.h')
-rw-r--r--native/src/words_priority_queue_pool.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/native/src/words_priority_queue_pool.h b/native/src/words_priority_queue_pool.h
index bf9619e19..5fa254852 100644
--- a/native/src/words_priority_queue_pool.h
+++ b/native/src/words_priority_queue_pool.h
@@ -58,6 +58,21 @@ class WordsPriorityQueuePool {
return mSubQueues2[id];
}
+ inline void clearAll() {
+ mMasterQueue->clear();
+ for (int i = 0; i < SUB_QUEUE_MAX_COUNT; ++i) {
+ mSubQueues1[i]->clear();
+ mSubQueues2[i]->clear();
+ }
+ }
+
+ void dumpSubQueue1TopSuggestions() {
+ AKLOGI("DUMP SUBQUEUE1 TOP SUGGESTIONS");
+ for (int i = 0; i < SUB_QUEUE_MAX_COUNT; ++i) {
+ mSubQueues1[i]->dumpTopWord();
+ }
+ }
+
private:
WordsPriorityQueue* mMasterQueue;
WordsPriorityQueue* mSubQueues1[SUB_QUEUE_MAX_COUNT];