fi.hut.tml.xsmiles.speech
Class RecognizerImpl
java.lang.Object
ResultAdapter
fi.hut.tml.xsmiles.speech.RecognizerImpl
- All Implemented Interfaces:
- Recognizer
- public class RecognizerImpl
- extends ResultAdapter
- implements Recognizer
- Author:
- honkkis
- See Also:
- Serialized Form
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
testGrammarStr
public java.lang.String testGrammarStr
STATUS_NOT_INITIALIZED
protected final int STATUS_NOT_INITIALIZED
- See Also:
- Constant Field Values
STATUS_PAUSED
protected final int STATUS_PAUSED
- See Also:
- Constant Field Values
STATUS_STARTED
protected final int STATUS_STARTED
- See Also:
- Constant Field Values
should_stop
protected boolean should_stop
status
protected int status
listeners
public java.util.Vector listeners
RecognizerImpl
public RecognizerImpl()
setGrammar
public void setGrammar(java.io.Reader r)
throws java.lang.Exception
- Specified by:
setGrammar in interface Recognizer
- Throws:
java.lang.Exception
init
protected void init()
start
public void start()
addXResultListener
public void addXResultListener(XRecognizerListener l)
- Specified by:
addXResultListener in interface Recognizer
removeXResultListener
public void removeXResultListener(XRecognizerListener l)
stop
public void stop()
recognize
protected Result recognize()
- TODO: return a result object
- Returns:
getLastResult
public java.util.Vector getLastResult()
getOneResultSync
public java.lang.String getOneResultSync()
- Specified by:
getOneResultSync in interface Recognizer
getOneResultAsync
public void getOneResultAsync()
- Description copied from interface:
Recognizer
- gets one result asynchronously, note that you have to set the result listener, in order to get the results, since
this method returns immediately
- Specified by:
getOneResultAsync in interface Recognizer
stopRecognizing
public void stopRecognizing()
- Specified by:
stopRecognizing in interface Recognizer
X-Smiles 1.2