|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.rim.blackberry.api.spellcheck.SpellCheckEngineFactory
public class SpellCheckEngineFactory
Factory for creating spell checking objects
| Method Summary | ||
|---|---|---|
|
static SpellCheckUI |
createSpellCheckUI()
Creates an object for spell checking user interfaces. |
|
static SpellCheckEngine |
getEngine()
Creates and returns a spell checking engine for the language associated with the system's default locale. |
|
static boolean |
isSpellCheckSupported(Locale locale)
Returns whether or not spell checking is supported for the language associated with a particular locale. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static SpellCheckEngine getEngine()
SpellCheckEngine for the language
associated with the system's default locale.
UnsupportedLocaleException - if spell
checking is not supported for the language
associated with the system's default locale.public static SpellCheckUI createSpellCheckUI()
NOTE:
An application should only ever invoke this method once. It should store
a reference
to the returned object and use it each time a SpellCheckUI
object is required
instead of repeatedly invoking this method. Invoking this method more
than once in a given
application is undefined and may cause undefined behaviour, such as
instances interfering
with one another.
SpellCheckUI object.
IllegalStateException - if Application instance does not exist.public static boolean isSpellCheckSupported(Locale locale)
If a spell checking engine that exactly matches the language associated
with the
specified locale is not supported then this method attempts to find a
"close match".
For example, if the specified locale is "en" but the device does not have
that exact locale
installed but does have en_US installed then it will be considered a
"close match" and this
method will return true. However, if the specified locale
is Japanese, which
at the time of writing does not support spell checking, then this method
will return
false since there is no close match to Japanese that
supports spell checking.
As another example, suppose that "en_GB" was specified but the spell
check dictionary for
that language is not installed on the device, but the spell check
dictionary for "en_US"
is installed. Then this method will return false since the
two languages,
although similar, have different spell check dictionaries.
Note that the example above is just an example and does not guarantee that any particular locale does or does not support spell checking. The only way to definitively tell whether or not a device supports spell checking for a particular locale is to invoke this method.
locale - the locale to test for spell checking support;
if null use the
system's default locale.
true if spell checking is supported for the
language associated with
the specified locale; false otherwise.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal