diff options
author | 2014-05-21 08:44:58 +0000 | |
---|---|---|
committer | 2014-05-21 08:44:58 +0000 | |
commit | 1c7a0b036461d52c7102682739971fee844e6049 (patch) | |
tree | 7c6a20591d4e5bb84e708d89aa75a9f8c7c22e33 /java/src/com/android/inputmethod/latin/PrevWordsInfo.java | |
parent | 2f3db0f38102f05d4c42bb39936e3b5fe97f5751 (diff) | |
parent | 17f326b7458c2bde2569e283a96e703755485328 (diff) | |
download | latinime-1c7a0b036461d52c7102682739971fee844e6049.tar.gz latinime-1c7a0b036461d52c7102682739971fee844e6049.tar.xz latinime-1c7a0b036461d52c7102682739971fee844e6049.zip |
am 17f326b7: Add beginning of sentence information in PrevWordsInfo.
* commit '17f326b7458c2bde2569e283a96e703755485328':
Add beginning of sentence information in PrevWordsInfo.
Diffstat (limited to 'java/src/com/android/inputmethod/latin/PrevWordsInfo.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/PrevWordsInfo.java | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/java/src/com/android/inputmethod/latin/PrevWordsInfo.java b/java/src/com/android/inputmethod/latin/PrevWordsInfo.java index 9d8543183..ecc8947db 100644 --- a/java/src/com/android/inputmethod/latin/PrevWordsInfo.java +++ b/java/src/com/android/inputmethod/latin/PrevWordsInfo.java @@ -16,6 +16,9 @@ package com.android.inputmethod.latin; +import android.util.Log; + +// TODO: Support multiple previous words for n-gram. public class PrevWordsInfo { // The previous word. May be null after resetting and before starting a new composing word, or // when there is no context like at the start of text for example. It can also be set to null @@ -23,7 +26,18 @@ public class PrevWordsInfo { // or a comma. public final String mPrevWord; + // TODO: Have sentence separator. + // Whether the current context is beginning of sentence or not. + public final boolean mIsBeginningOfSentence; + + // Beginning of sentence. + public PrevWordsInfo() { + mPrevWord = null; + mIsBeginningOfSentence = true; + } + public PrevWordsInfo(final String prevWord) { mPrevWord = prevWord; + mIsBeginningOfSentence = false; } } |