java.lang.Object | |
↳ | android.service.textservice.SpellCheckerService.Session |
This abstract class should be overridden by a concrete implementation of a spell checker.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Request to abort all tasks executed in SpellChecker.
| |||||||||||
Request to close this session.
| |||||||||||
This is called after the class is initialized, at which point it knows it can call
getLocale() etc...
| |||||||||||
Get sentence suggestions for specified texts in an array of TextInfo.
| |||||||||||
Get suggestions for specified text in TextInfo.
| |||||||||||
A batch process of onGetSuggestions.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Request to abort all tasks executed in SpellChecker. This function will run on the incoming IPC thread. So, this is not called on the main thread, but will be called in series on another thread.
Request to close this session. This function will run on the incoming IPC thread. So, this is not called on the main thread, but will be called in series on another thread.
This is called after the class is initialized, at which point it knows it can call getLocale() etc...
Get sentence suggestions for specified texts in an array of TextInfo.
The default implementation splits the input text to words and returns
SentenceSuggestionsInfo
which contains suggestions for each word.
This function will run on the incoming IPC thread.
So, this is not called on the main thread,
but will be called in series on another thread.
When you override this method, make sure that suggestionsLimit is applied to suggestions
that share the same start position and length.
textInfos | an array of the text metadata |
---|---|
suggestionsLimit | the maximum number of suggestions to be returned |
SentenceSuggestionsInfo
returned by
onGetSuggestions(TextInfo, int)
Get suggestions for specified text in TextInfo. This function will run on the incoming IPC thread. So, this is not called on the main thread, but will be called in series on another thread.
textInfo | the text metadata |
---|---|
suggestionsLimit | the maximum number of suggestions to be returned |
A batch process of onGetSuggestions. This function will run on the incoming IPC thread. So, this is not called on the main thread, but will be called in series on another thread.
textInfos | an array of the text metadata |
---|---|
suggestionsLimit | the maximum number of suggestions to be returned |
sequentialWords | true if textInfos can be treated as sequential words. |
SentenceSuggestionsInfo
returned by
onGetSuggestions(TextInfo, int)