Disconnect app data search client after fetching all data.
Bug: 13138201 Change-Id: Ibaa3c2c22a4fe44ea23e92ce8576141bbad09b12main
parent
584e9c9c22
commit
2b72aa07a9
|
@ -232,6 +232,12 @@ public class DictionaryFacilitatorForSuggest {
|
|||
return null != mPersonalizationDictionary;
|
||||
}
|
||||
|
||||
public void flushPersonalizationDictionary() {
|
||||
if (hasPersonalizationDictionary()) {
|
||||
mPersonalizationDictionary.flush();
|
||||
}
|
||||
}
|
||||
|
||||
public void waitForLoadingMainDictionary(final long timeout, final TimeUnit unit)
|
||||
throws InterruptedException {
|
||||
mLatchForWaitingLoadingMainDictionary.await(timeout, unit);
|
||||
|
|
|
@ -68,6 +68,11 @@ public abstract class DecayingExpandableBinaryDictionaryBase extends ExpandableB
|
|||
dumpAllWordsForDebug();
|
||||
}
|
||||
// Flush pending writes.
|
||||
flush();
|
||||
// TODO: Quit depending on finalize() and really close the dictionary file.
|
||||
}
|
||||
|
||||
public void flush() {
|
||||
asyncFlushBinaryDictionary();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue