|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mot.iden.t9.T9
The T9 object houses all the T9 state information for a native side instance of a T9FieldInfo struct. The T9 object allows the Java environment to make use of the smart text entry capabilities the native T9 engine affords.
Field Summary | |
byte[] |
auxKorean
Korean information buffer. |
static int |
CURSOR_CHANGE
Used in our state change mask when a cursor change event occurs. |
static int |
DECIMAL_MODE
Used to put T9 in DECIMAL_MODE. |
int |
dwReserved
Reserved bits used by native T9 engine. |
int |
dwStateBits
Current State bits. |
static int |
EMAIL_MODE
Used to put T9 into email mode. |
static int |
EVTCTRL
The event ID used with control events to change the T9 engine's state. |
static int |
EVTCURSOR
The event ID used to set the cursor position. |
static int |
EVTEXPL
The event ID used when adding a character to the text buffer at the current cursor position. |
static int |
EVTKEY
The event ID used to when sending a key event. |
static int |
EVTNONE
T9 null event, no action performed on this event. |
static int |
EVTSETLANG
The event ID used to set a new language number. |
static int |
EVTSYMTOKEY
The event ID used to map a character to the ambiguous key it is identified with. |
static int |
EVTTEXTKEY
The event ID used when presetting the T9 text buffer with valid T9 words. |
static int |
EVTUDBFENCE
The event ID used to set the cutover point for mapping UDB words to a key sequence. |
static int |
INTEGER_MODE
Used to put T9 into integer mode. |
byte[] |
keyBuf
Korean key stroke buffer. |
static int |
KOREAN_SELECT_PAGE_CHANGE
Used in our state change mask when the shift modifier has changed. |
static int |
MAX_CHARACTERS
The max amount of characters a T9 engine can hold. |
int |
nBufLen
Length of current text. |
int |
nBufLenMax
Maximum length of current text. |
int |
nCursor
Current cursor position. |
int |
nLdbObjCnt
Count of LDB objects for current key sequence. |
static int |
NO_CHANGE
Used in our state change mask to signify no change. |
int |
nObjNum
Object number of word at cursor position. |
int |
nUdbFence
Selection list start point for UDB words. |
int |
nUdbObjCnt
Count of UDB objects for current key sequence. |
int |
nWordLen
Length of word at current cursor position. |
static int |
PASSWORD_MODE
Used to put T9 into password mode. |
static int |
PHONE_MODE
Used to put T9 into phone mode. |
char[] |
psAuxBuf
Shared auxillary key buffer only used in native. |
char[] |
psTxtBuf
The main T9 text buffer holding the entered text. |
byte[] |
pT9Private
Pointer to persistent memory for use by native T9 engine. |
char[] |
selectPage
Korean character selection page. |
static int |
SHIFT_CHANGE
Used in our state change mask when the shift modifier has changed. |
static int |
T9ARABIC_LANGUAGE
A bit mask for setting T9 to hebrew. |
static int |
T9CTRLADD
Used to force the T9 engine to scan for new words to add to the user database. |
static int |
T9CTRLCLRCAP
Turns off CAPS lock. |
static int |
T9CTRLCLRSHF
Turns off SHIFT. |
static int |
T9CTRLCLRSYM
Reverts from Symbol mode to the previous entry mode. |
static int |
T9CTRLSETCAP
Turns on CAPS lock. |
static int |
T9CTRLSETSHF
Turns on SHIFT. |
static int |
T9ENGLISH_LANGUAGE
A bit mask for setting T9 to english. |
static int |
T9EXTSPELL_MODE
Used to force T9 into retrieving multitap symbols from the host. |
static int |
T9FRENCH_LANGUAGE
A bit mask for setting T9 to french. |
static int |
T9HEBREW_LANGUAGE
A bit mask for setting T9 to hebrew. |
static int |
T9KEYRIGHT
Right key event. |
static int |
T9KOREAN_LANGUAGE
A bit mask for setting T9 to korean. |
static int |
T9KOREAN_SYLLABLE_MODE
Used to put T9 into Korean syllable mode. |
static int |
T9NUM_MODE
Used to put T9 into numeric mode. |
static int |
T9PORTUGUESE_LANGUAGE
A bit mask for setting T9 to portuguese. |
static int |
T9SPANISH_LANGUAGE
A bit mask for setting T9 to spanish. |
static int |
T9SPELL_MODE
Used to put T9 into spell (multitap) mode. |
static int |
T9SYM_MODE
Used to put T9 into symbol mode. |
static int |
T9WORD_MODE
Used to put T9 into word mode. |
static int |
URL_MODE
Used to put T9 into URL mode. |
short |
wSymbolClass
Symbol class of current LDB. |
Constructor Summary | |
T9()
Contructs an instance of T9 capable of holding the max amount of characters. |
|
T9(int length)
Contructs an instance of T9 capable of the specified amount of characters. |
|
T9(int length,
java.lang.String text)
Contructs an instance of T9 capable of the specified amount of characters and preset with the specified text. |
Method Summary | |
void |
addWordToUDB()
Add any new words in T9's text buffer to the UDB if UDB write is enabled. |
boolean |
autoCapsSentenceActive()
Returns true if auto-caps sentence is on. |
boolean |
autoCapsWordActive()
Returns true if auto-caps word is on. |
boolean |
capsActive()
Used to determine if CAPS lock is on. |
void |
clearAutoCapsSentence()
Turns off auto-caps sentence. |
void |
clearAutoCapsWord()
Turns off auto-caps word. |
void |
clearCaps()
Turns off CAPS lock. |
void |
clearShift()
Turns off Shift mode. |
void |
deleteText(int start,
int length)
Deletes text up to given length starting at the specified location. |
int |
getCursorPosition()
A helper method to return the current cursor position. |
java.lang.String |
getKoreanSelectPage()
Get the string stored in the Korean selection page. |
int |
getKoreanSelectPageLength()
Get the amount of characters currently in the Korean select page. |
int |
getKoreanSelectPageMax()
Get the max amount of characters that can be held in the Korean select page. |
int |
getLanguage()
A helper method to return the current language. |
int |
getMode()
A helper method to return the current entry mode. |
java.lang.String |
getString()
Returns the current text in the T9 engine. |
boolean |
getUDBWrite()
Returns true if the UDB is writeable. |
int |
getWordLength()
A helper method to return the current word length. |
void |
handleEvent(int mType,
int eventID)
Handles all T9 events. |
void |
handleKeyEvent(int eventID)
Helper method for timer and key events. |
boolean |
insertActive()
Used to determine if the T9 engine is currently disambiguating a multitapped character. |
void |
insertText(java.lang.String s,
int index,
boolean remove)
Inserts the specified string to the T9 text buffer at the specified insertion point. |
boolean |
numActive()
Used to determine if the current entry mode is Numeric mode. |
void |
setAutoCapsSentence()
Turns on auto-caps sentence. |
void |
setAutoCapsWord()
Turns on auto-caps word. |
void |
setCaps()
Turns on CAPS lock. |
void |
setCursor(int curPosition)
Sets the cursor position. |
void |
setLanguage(int language)
Sets the current language for word disambiguation. |
void |
setMode(int mode)
Set the entry mode. |
void |
setShift()
Turns on Shift mode. |
void |
setT9Listener(T9Listener listener)
Registers a T9Listener with this object for T9 state changes. |
void |
setText(java.lang.String str)
Sets the text in the T9 engine to the specified String. |
void |
setUDBWrite(boolean write)
Enables and disables UDB writeability. |
boolean |
shiftActive()
Used to determine if SHIFT is on. |
boolean |
spellActive()
Used to determine if the current entry mode is Spell (Multitap) mode. |
static void |
T9Terminate(T9 t9)
Native function to terminate this T9 engine. |
boolean |
wordActive()
Used to determine if the current entry mode is Word mode. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int EVTNONE
public static final int EVTSETLANG
public static final int EVTKEY
public static final int EVTTEXTKEY
public static final int EVTEXPL
public static final int EVTSYMTOKEY
public static final int EVTCTRL
public static final int EVTUDBFENCE
public static final int EVTCURSOR
public static final int T9ENGLISH_LANGUAGE
public static final int T9FRENCH_LANGUAGE
public static final int T9SPANISH_LANGUAGE
public static final int T9PORTUGUESE_LANGUAGE
public static final int T9KOREAN_LANGUAGE
public static final int T9HEBREW_LANGUAGE
public static final int T9ARABIC_LANGUAGE
public static final int T9WORD_MODE
public static final int T9SYM_MODE
public static final int T9NUM_MODE
public static final int T9EXTSPELL_MODE
public static final int T9SPELL_MODE
public static final int EMAIL_MODE
public static final int PASSWORD_MODE
public static final int URL_MODE
public static final int INTEGER_MODE
public static final int PHONE_MODE
public static final int DECIMAL_MODE
public static final int T9KOREAN_SYLLABLE_MODE
public static final int T9CTRLADD
public static final int T9CTRLSETCAP
public static final int T9CTRLCLRCAP
public static final int T9CTRLSETSHF
public static final int T9CTRLCLRSHF
public static final int T9CTRLCLRSYM
public static final int T9KEYRIGHT
public static final int NO_CHANGE
public static final int SHIFT_CHANGE
public static final int KOREAN_SELECT_PAGE_CHANGE
public static final int CURSOR_CHANGE
public static final int MAX_CHARACTERS
public char[] selectPage
public char[] psTxtBuf
public char[] psAuxBuf
public int nBufLenMax
public int nBufLen
public int nCursor
public int nWordLen
public int nObjNum
public short wSymbolClass
public int nLdbObjCnt
public int nUdbObjCnt
public int nUdbFence
public int dwStateBits
public byte[] pT9Private
public int dwReserved
public byte[] auxKorean
public byte[] keyBuf
Constructor Detail |
public T9() throws T9Exception
T9Exception
- if the T9 engine could not be started or on Gemini productpublic T9(int length) throws T9Exception
length
- the maximum amount of characters capable of being held
T9Exception
- if the T9 engine could not be started or on Gemini product.public T9(int length, java.lang.String text) throws T9Exception
length
- the maximum amount of characters capable of being heldtext
- the text to preset the T9 engine with
T9Exception
- if the T9 engine could not be started or on Gemini product.Method Detail |
public void handleEvent(int mType, int eventID) throws T9Exception
mType
- the event typeeventID
- logical key ID value, symbol value, logical control ID value,
number of expired timer or parameter for various control events
T9Exception
- if the T9 engine could not handle the event or on Gemini
product.public void handleKeyEvent(int eventID) throws T9Exception
eventID
- key ID value or timerout event ID value
T9Exception
- if the T9 engine could not handle the event or on Gemini
product.public static final void T9Terminate(T9 t9) throws T9Exception
t9
- the instance to be terminated
T9Exception
- if the T9 engine could not properly terminate or on Gemini
product.public int getCursorPosition()
public int getWordLength()
public int getMode()
public int getLanguage()
public void setT9Listener(T9Listener listener)
listener
- the listener registering for state changes, do nothing on
Gemini product.public void setCursor(int curPosition)
curPosition
- the cursor position to set, do nothing on Gemini product.public void setLanguage(int language) throws T9Exception
language
- the ID of the desired language
T9Exception
- if the specified language cannot be set or on Gemini productpublic void setMode(int mode) throws T9Exception
mode
- the mode to be set
T9Exception
- if the entry mode cannot be set or on Gemini productpublic void setCaps() throws T9Exception
T9Exception
- if CAPS lock cannot be turned on or on Gemini product.public void clearCaps() throws T9Exception
T9Exception
- if CAPS lock cannot be turned off or on Gemini product.public boolean insertActive()
public boolean capsActive()
public boolean shiftActive()
public boolean wordActive()
public boolean spellActive()
public boolean numActive()
public java.lang.String getString()
public java.lang.String getKoreanSelectPage()
public int getKoreanSelectPageMax()
public int getKoreanSelectPageLength()
public void setShift() throws T9Exception
T9Exception
- if Shift mode cannot be turned on or on Gemini productpublic void clearShift() throws T9Exception
T9Exception
- if Shift mode cannot be turned on or on Gemini product.public void setAutoCapsSentence()
public void setAutoCapsWord()
public void clearAutoCapsSentence()
public void clearAutoCapsWord()
public boolean autoCapsSentenceActive()
public boolean autoCapsWordActive()
public void setUDBWrite(boolean write)
public boolean getUDBWrite()
public void addWordToUDB() throws T9Exception
T9Exception
public void setText(java.lang.String str) throws T9Exception
str
- the String to preset the engine with
T9Exception
- if the String cannot be set or on Gemini productpublic void insertText(java.lang.String s, int index, boolean remove) throws T9Exception
s
- the string to be insertedindex
- insertion locationremove
- if true, overflow text is removed
T9Exception
public void deleteText(int start, int length)
start
- deletion start locationlength
- amount of text to be removed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |