JSR-043: JTAPI-1.4

javax.telephony.media.provider
Class S200_ASREvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--javax.telephony.media.provider.EventObject
              |
              +--javax.telephony.media.provider.Base.Event
                    |
                    +--javax.telephony.media.provider.Base.MediaServiceEvent
                          |
                          +--javax.telephony.media.provider.Base.ResourceEvent
                                |
                                +--javax.telephony.media.provider.Base_ASREvent
                                      |
                                      +--javax.telephony.media.provider.S200_ASREvent
All Implemented Interfaces:
ASRConstants, ASREvent, Async_ASREvent, Async.Event, Async.MediaServiceEvent, Async.ResourceEvent, Dispatcher.DispatchableEvent, MediaConstants, MediaEvent, MediaServiceConstants, MediaServiceEvent, ResourceConstants, ResourceEvent, java.io.Serializable

public class S200_ASREvent
extends Base_ASREvent

Defines the accessor methods used by S.200 ASR Events.

Since:
JTAPI-1.4
See Also:
Serialized Form

Inner classes inherited from class javax.telephony.media.provider.Base.Event
Base.Event.SyncInterruptedException
 
Inner classes inherited from class javax.telephony.media.ASREvent
ASREvent.TokenSequence
 
Fields inherited from interface javax.telephony.media.MediaServiceConstants
ev_BindAndConnect, ev_BindToCall, ev_BindToServiceName, ev_BindToTerminal, ev_BindToTerminalName, ev_Configure, ev_Connected, ev_DelegateToService, ev_Disconnected, ev_GetConfigSpec, ev_GetConfiguration, ev_GetParameters, ev_GetTerminal, ev_GetTerminalName, ev_GetUserValues, ev_GroupStop, ev_Release, ev_ReleaseDelegated, ev_ReleaseToDestroy, ev_ReleaseToService, ev_ReleaseToTag, ev_Retrieve, ev_Retrieved, ev_SetParameters, ev_SetUserDictionary, ev_SetUserValues, ev_TerminalIdle, ev_TriggerRTC
 
Fields inherited from interface javax.telephony.media.MediaConstants
e_OK, q_Duration, q_Standard, q_Stop
 
Fields inherited from interface javax.telephony.media.ResourceConstants
e_Disconnected, FOREVER, q_Disconnected, q_RTC, rtcc_Disconnected, rtcc_TriggerRTC, v_Forever
 
Fields inherited from interface javax.telephony.media.ASRConstants
a_AutomaticTraining, a_ContextType, a_Date, a_DefaultRules, a_DetectionType, a_EchoCancellation, a_IntermediateResults, a_Label, a_Language, a_LoadableContext, a_LoadedContext, a_NumberRepetitions, a_NumberWordsRequested, a_OutputType, a_PrivateRules, a_PublicRules, a_RepeatRecognition, a_ResourceName, a_ResourceVendor, a_ResourceVersion, a_ResultPresentation, a_Rules, a_Size, a_SpeakerType, a_SpecificUtterance, a_Spotting, a_Trainable, a_Training, a_TrainingModifiable, a_TrainingType, a_UtteranceType, a_UtteranceValidation, a_Variant, e_BadContainerName, e_BadContext, e_Exists, e_IncorrectContext, e_NoExists, e_NotSupported, ev_ContextCopy, ev_ContextCreate, ev_ContextGetParameters, ev_ContextRemove, ev_ContextSetParameters, ev_GetFinalResults, ev_GetResults, ev_GetRuleExpansion, ev_Idle, ev_IntermediateResultsReady, ev_InvalidUtterance, ev_RecognitionStarted, ev_Recognize, ev_RetrieveRecognition, ev_SetRuleExpansion, ev_Start, ev_Stop, ev_UpdateParameters, ev_ValidUtterance, ev_WordCommit, ev_WordCreate, ev_WordDeleteLastUtterance, ev_WordDeleteTraining, ev_WordDestroy, ev_WordTrain, p_ActiveContexts, p_ActiveRules, p_ActiveWords, p_AutomaticTraining, p_ContextType, p_DetectionType, p_Duration, p_EchoCancellation, p_EnabledEvents, p_FinalTimeout, p_GrammarBargeInThreshold, p_InitialTimeout, p_Label, p_Language, p_LoadedContexts, p_LoadedWords, p_NumberRepetitions, p_NumberWordsRequested, p_OutputType, p_PlayInput, p_PrivateRules, p_PublicRules, p_ResultPresentation, p_ResultType, p_Rules, p_Size, p_SpeakerType, p_SpecificUtterance, p_Spotting, p_StartPaused, p_State, p_StoreInput, p_TopChoices, p_Trainable, p_TrainingType, p_UpdateParametersList, p_UtteranceType, p_Variant, q_Complete, q_Failure, q_InitialTimeout, q_Rejected, q_Silence, q_Stop, q_Success, q_Unsuccessful, q_Warning, rtca_Idle, rtca_Start, rtca_Stop, rtca_UpdateParameters, rtcc_GrammarBargeIn, rtcc_InvalidUtterance, rtcc_Recognize, rtcc_RecognizeStarted, rtcc_Silence, rtcc_SpecificUtterance, rtcc_SpeechDetected, rtcc_TrainStarted, rtcc_ValidUtteranceFinal, rtcc_ValidUtteranceFound, rtcc_WordTrain, rtcc_WordTrained, v_AddTraining, v_Class, v_Collision, v_Complete, v_Continuous, v_Dependent, v_Discrete, v_Final, v_FromResource, v_Garbage, v_GrammarTag, v_Identification, v_Idle, v_Immutable, v_Inconsistent, v_Independent, v_Intermediate, v_Mutable, v_Noisy, v_Normal, v_NotModifiable, v_NotReady, v_Phonetic, v_Ready, v_RecognitionPaused, v_Recognizing, v_ResultsAvailable, v_Retrain, v_Silence, v_Speech, v_Success, v_Text, v_ToResource, v_ToResourceTraining, v_Training, v_TrainingPaused, v_TypeI, v_TypeII, v_Verification, v_WordTrained
 
Constructor Summary
S200_ASREvent(java.lang.Object source, Symbol eventID)
          Create specific completion or non-transaction event from ASR.
S200_ASREvent(java.lang.Object source, Symbol eventID, boolean isNonTrans)
          Constructor for non-trans vesion
 
Method Summary
 java.util.Dictionary getContextDictionary()
          Return a Dictionary containing the context parameters.
 java.lang.String getContextName()
          Return the name of the affected context.
 int getNumberOfSequences()
          The number of TokenSequences available.
 Symbol getReadiness()
          Return a Symbol telling if the word has been sufficiently trained.
 Symbol getResultPresentation()
          Return a Symbol indicating the type of results.
 java.lang.String getRuleExpansion()
          Return the rule expansion from getRuleExpansion.
 ASREvent.TokenSequence getTokenSequence(int seqNum)
          Return one recognition sequence.
 Symbol getTrainingResult()
          Return a Symbol describing the results of training.
 java.lang.String getWordName()
          Return the name of the affected word.
 void setFields()
          extract Result values from payload into local fields.
 
Methods inherited from class javax.telephony.media.provider.Base_ASREvent
dispatch
 
Methods inherited from class javax.telephony.media.provider.Base.ResourceEvent
getRTCTrigger, throwIfMediaResourceException
 
Methods inherited from class javax.telephony.media.provider.Base.MediaServiceEvent
getMediaService
 
Methods inherited from class javax.telephony.media.provider.Base.Event
done, getError, getEventID, getException, getPayload, getQualifier, getSubError, getWarning, isDone, setError, setFields, setFields, setPayload, setQualifier, setSubError, throwIfRuntimeException, toString, waitForEventDone, waitForEventDone, waitForListenersDone
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface javax.telephony.media.async.Async.ResourceEvent
throwIfMediaResourceException
 
Methods inherited from interface javax.telephony.media.async.Async.Event
isDone, throwIfRuntimeException, waitForEventDone, waitForEventDone, waitForListenersDone
 
Methods inherited from interface javax.telephony.media.MediaEvent
getError, getEventID, getException, getPayload, getQualifier, getSubError, getWarning
 
Methods inherited from interface javax.telephony.media.MediaServiceEvent
getMediaService
 
Methods inherited from interface javax.telephony.media.ResourceEvent
getRTCTrigger
 

Constructor Detail

S200_ASREvent

public S200_ASREvent(java.lang.Object source,
                     Symbol eventID)
Create specific completion or non-transaction event from ASR.
Parameters:
source - the Object that created this EventObject.
eventID - a Symbol that identifies this event: ASR.ev_Recognize

S200_ASREvent

public S200_ASREvent(java.lang.Object source,
                     Symbol eventID,
                     boolean isNonTrans)
Constructor for non-trans vesion
Method Detail

setFields

public void setFields()
extract Result values from payload into local fields.

getResultPresentation

public Symbol getResultPresentation()
Description copied from interface: ASREvent
Return a Symbol indicating the type of results.
Overrides:
getResultPresentation in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
one of the Symbols ASRConstants.v_TypeI or ASRConstants.v_TypeII.

getNumberOfSequences

public int getNumberOfSequences()
Description copied from interface: ASREvent
The number of TokenSequences available. For eventID equal ASR.ev_recognize this will be at most 1.
Overrides:
getNumberOfSequences in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
the int number of TokenSequences available for this event.

getTokenSequence

public ASREvent.TokenSequence getTokenSequence(int seqNum)
Description copied from interface: ASREvent
Return one recognition sequence. Sequences are ranked in order of likelihood of being correct. Sequence number zero is the most likely.

This presentation may be sub-optimal for Type-I results.

If sequenceNumber is out of range null is returned.

Overrides:
getTokenSequence in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Parameters:
sequenceNumber - an int specifying the sequence to be returned; valid values are non-negative and less than getNumberOfSequences().
Returns:
a TokenSequence containing the specified row of results.
See Also:
ASR.getResults(), ASR.getFinalResults(), ASR.recognize()

getContextDictionary

public java.util.Dictionary getContextDictionary()
Description copied from interface: ASREvent
Return a Dictionary containing the context parameters.

Overrides:
getContextDictionary in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
context parameter Dictionary.
See Also:
ASR.contextGetParameters

getRuleExpansion

public java.lang.String getRuleExpansion()
Description copied from interface: ASREvent
Return the rule expansion from getRuleExpansion.

Overrides:
getRuleExpansion in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
a String which is the rule expansion.
See Also:
ASR.getRuleExpansion()

getWordName

public java.lang.String getWordName()
Description copied from interface: ASREvent
Return the name of the affected word.

Overrides:
getWordName in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
a String which is the name of the word.
See Also:
ASR.wordCommit(), ASR.wordCreate(), ASR.wordDeleteTraining(), ASR.wordDestroy(), ASR.wordTrain()

getContextName

public java.lang.String getContextName()
Description copied from interface: ASREvent
Return the name of the affected context.
Overrides:
getContextName in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
a String which is the context name.
See Also:
ASR.contextRemove(), ASR.wordCommit(), ASR.wordCreate(), ASR.wordDeleteLastUtterance(), ASR.wordDeleteTraining(), ASR.wordDestroy(), ASR.wordTrain()

getReadiness

public Symbol getReadiness()
Description copied from interface: ASREvent
Return a Symbol telling if the word has been sufficiently trained. It is used to determine whether more training is required before the Word can be committed; this value describes the overall state of the Word being trained.
Overrides:
getReadiness in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
one of ASRConstants.v_Ready, ASRConstants.v_NotReady, ASRConstants.v_Complete.
See Also:
ASR.wordTrain()

getTrainingResult

public Symbol getTrainingResult()
Description copied from interface: ASREvent
Return a Symbol describing the results of training.
Overrides:
getTrainingResult in class Base_ASREvent
Following copied from interface: javax.telephony.media.ASREvent
Returns:
one of ASRConstants.v_Success, ASRConstants.v_Collision, ASRConstants.v_Inconsistent, ASRConstants.v_Noisy.
See Also:
ASR.wordTrain()

JSR-043: JTAPI-1.4

Send comments to: JSR-43@ectf.org