编写android拼写检查程序.docVIP

  • 2
  • 0
  • 约8.7千字
  • 约 6页
  • 2018-03-05 发布于河南
  • 举报
编写android拼写检查程序

Spelling Checker Framework In This Document  HYPERLINK /guide/topics/text/spell-checker-framework.html \l SpellCheckLifeCycle Spell Check Lifecycle  HYPERLINK /guide/topics/text/spell-checker-framework.html \l SpellCheckImplementation Implementing a Spell Checker Service  HYPERLINK /guide/topics/text/spell-checker-framework.html \l SpellCheckClient Implementing a Spell Checker Client See also  HYPERLINK /resources/samples/SpellChecker/SampleSpellCheckerService/index.html Spell Checker Service sample app  HYPERLINK /resources/samples/SpellChecker/HelloSpellChecker/index.html Spell Checker Client sample app The Android platform offers a spelling checker framework that lets you implement and access spell checking in your application. The framework is one of the Text Service APIs offered by the Android platform. To use the framework in your app, you create a special type of Android service that generates a spelling checker session object. Based on text you provide, the session object returns spelling suggestions generated by the spelling checker. Spell Checker Lifecycle The following diagram shows the lifecycle of the spelling checker service: Figure 1. The spelling checker service lifecycle. To initiate spell checking, your app starts its implementation of the spelling checker service. Clients in your app, such as activities or individual UI elements, request a spelling checker session from the service, then use the session to get suggestions for text. As a client terminates its operation, it closes its spelling checker session. If necessary, your app can shut down the spelling checker service at any time. Implementing a Spell Checker Service To use the spelling checker framework in your app, add a spelling checker service component including the session object definition. You can also add to your app an optional activity that controls settings. You must also add an XML metadata file that describes the spelling checker service, and add the appr

文档评论(0)

1亿VIP精品文档

相关文档