MSpeechRecognitionCustomCommandImplementor Class Reference

class MSpeechRecognitionCustomCommandImplementor

This is the main class of Speech Recognition Custom Commands Implementor.

Since
8.0
Public Member Functions
void MSrAddPronunciationL ( TLexiconID , TModelBankID , TModelID , TPronunciationID &)
void MSrAddRuleL ( TGrammarID , TLexiconID , TPronunciationID , TRuleID &)
void MSrCancel ()
void MSrCommitChangesL ()
void MSrCreateGrammarL ( TGrammarID &)
void MSrCreateLexiconL ( TLexiconID &)
void MSrCreateModelBankL ( TModelBankID &)
void MSrEndRecSessionL ()
void MSrGetAllClientGrammarIDsL ( RArray < TGrammarID > &)
void MSrGetAllClientLexiconIDsL ( RArray < TLexiconID > &)
void MSrGetAllClientModelBankIDsL ( RArray < TModelBankID > &)
void MSrGetAllGrammarIDsL ( RArray < TGrammarID > &)
void MSrGetAllLexiconIDsL ( RArray < TLexiconID > &)
void MSrGetAllModelBankIDsL ( RArray < TModelBankID > &)
void MSrGetAllModelIDsL ( TModelBankID , RArray < TModelID > &)
void MSrGetAllPronunciationIDsL ( TLexiconID , RArray < TPronunciationID > &)
void MSrGetAllRuleIDsL ( TGrammarID , RArray < TRuleID > &)
void MSrGetAvailableStorageL ( TInt &)
void MSrGetEnginePropertiesL (const RArray < TInt > &, RArray < TInt > &)
void MSrGetModelCountL ( TModelBankID , TInt &)
void MSrGetRuleValidityL ( TGrammarID , TRuleID , TBool &)
void MSrGetUtteranceDurationL ( TModelBankID , TModelID , TTimeIntervalMicroSeconds32 &)
void MSrLoadEngineParametersL (const RArray < TInt > &, const RArray < TInt > &)
void MSrLoadGrammarL ( TGrammarID )
void MSrLoadLexiconL ( TLexiconID )
void MSrLoadModelsL ( TModelBankID )
void MSrPlayUtteranceL ( TModelBankID , TModelID )
void MSrRecognizeL ( CSDClientResultSet &)
void MSrRecordL ( TTimeIntervalMicroSeconds32 )
void MSrRemoveGrammarL ( TGrammarID )
void MSrRemoveLexiconL ( TLexiconID )
void MSrRemoveModelBankL ( TModelBankID )
void MSrRemoveModelL ( TModelBankID , TModelID )
void MSrRemovePronunciationL ( TLexiconID , TPronunciationID )
void MSrRemoveRuleL ( TGrammarID , TRuleID )
void MSrSetClientUid ( TUid )
void MSrStartRecSessionL ( TRecognitionMode )
void MSrTrainL ( TModelBankID , TModelID &)
void MSrUnloadRuleL ( TGrammarID , TRuleID )

Member Functions Documentation

MSrAddPronunciationL(TLexiconID, TModelBankID, TModelID, TPronunciationID &)

void MSrAddPronunciationL ( TLexiconID aLexiconID,
TModelBankID aModelBankID,
TModelID aModelID,
TPronunciationID & aPronunciationID
) [pure virtual]

Adds a new pronunciation for the given model into the specified lexicon.

Since
8.0

Parameters

TLexiconID aLexiconID The lexicon ID to where the new pronunciation is added.
TModelBankID aModelBankID The model bank ID.
TModelID aModelID The model ID.
TPronunciationID & aPronunciationID A reference to where a new pronunciation ID is assigned.

MSrAddRuleL(TGrammarID, TLexiconID, TPronunciationID, TRuleID &)

void MSrAddRuleL ( TGrammarID aGrammarID,
TLexiconID aLexiconID,
TPronunciationID aPronunciationID,
TRuleID & aRuleID
) [pure virtual]

Adds a new rule for the given pronunciation into the specified grammar.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID, where the new rule is added to
TLexiconID aLexiconID The lexicon ID.
TPronunciationID aPronunciationID The pronunciation ID.
TRuleID & aRuleID A reference where a new rule ID is assigned to.

MSrCancel()

void MSrCancel ( ) [pure virtual]

Cancels the current operation.

Since
8.0

MSrCommitChangesL()

void MSrCommitChangesL ( ) [pure virtual]

Commit uncommited changes to the database.

Since
8.0

MSrCreateGrammarL(TGrammarID &)

void MSrCreateGrammarL ( TGrammarID & aGrammarID ) [pure virtual]

Creates a new grammar.

Since
8.0

Parameters

TGrammarID & aGrammarID A reference where the grammar ID is stored.

MSrCreateLexiconL(TLexiconID &)

void MSrCreateLexiconL ( TLexiconID & aLexiconID ) [pure virtual]

Creates a new lexicon.

Since
8.0

Parameters

TLexiconID & aLexiconID A reference where the lexicon ID is stored.

MSrCreateModelBankL(TModelBankID &)

void MSrCreateModelBankL ( TModelBankID & aModelBankID ) [pure virtual]

Creates a new model bank.

Since
8.0

Parameters

TModelBankID & aModelBankID A reference to where a new model bank ID is assigned.

MSrEndRecSessionL()

void MSrEndRecSessionL ( ) [pure virtual]

Ends the current recognition session. Resources allocated for recognition are freed.

Since
8.0

MSrGetAllClientGrammarIDsL(RArray< TGrammarID > &)

void MSrGetAllClientGrammarIDsL ( RArray < TGrammarID > & aGrammarIDs ) [pure virtual]

Returns all grammar IDs that are owned by the client.

Since
8.0

Parameters

RArray < TGrammarID > & aGrammarIDs A reference where grammar IDs are stored.

MSrGetAllClientLexiconIDsL(RArray< TLexiconID > &)

void MSrGetAllClientLexiconIDsL ( RArray < TLexiconID > & aLexiconIDs ) [pure virtual]

Returns all lexicon IDs that are owned by the client.

Since
8.0

Parameters

RArray < TLexiconID > & aLexiconIDs A reference where the lexicon IDs are stored.

MSrGetAllClientModelBankIDsL(RArray< TModelBankID > &)

void MSrGetAllClientModelBankIDsL ( RArray < TModelBankID > & aModelBankIDs ) [pure virtual]

Returns all modelbank IDs that are owned by the client.

Since
8.0

Parameters

RArray < TModelBankID > & aModelBankIDs A reference where model bank IDs are stored.

MSrGetAllGrammarIDsL(RArray< TGrammarID > &)

void MSrGetAllGrammarIDsL ( RArray < TGrammarID > & aGrammarIDs ) [pure virtual]

Returns all grammar IDs.

Parameters

RArray < TGrammarID > & aGrammarIDs A reference where grammar IDs are stored.

MSrGetAllLexiconIDsL(RArray< TLexiconID > &)

void MSrGetAllLexiconIDsL ( RArray < TLexiconID > & aLexiconIDs ) [pure virtual]

Returns all lexicon IDs.

Parameters

RArray < TLexiconID > & aLexiconIDs A reference where lexicon IDs are stored.

MSrGetAllModelBankIDsL(RArray< TModelBankID > &)

void MSrGetAllModelBankIDsL ( RArray < TModelBankID > & aModelBankIDs ) [pure virtual]

Returns all modelbank IDs.

Since
8.0

Parameters

RArray < TModelBankID > & aModelBankIDs A reference where the model bank IDs are stored.

MSrGetAllModelIDsL(TModelBankID, RArray< TModelID > &)

void MSrGetAllModelIDsL ( TModelBankID aModelBankID,
RArray < TModelID > & aModelIDs
) [pure virtual]

Returns all model IDs that exist in the specified model bank.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.
RArray < TModelID > & aModelIDs A reference where model IDs are stored.

MSrGetAllPronunciationIDsL(TLexiconID, RArray< TPronunciationID > &)

void MSrGetAllPronunciationIDsL ( TLexiconID aLexiconID,
RArray < TPronunciationID > & aPronunciationIDs
) [pure virtual]

Returns all pronunciation IDs that exist in the specified lexicon.

Since
8.0

Parameters

TLexiconID aLexiconID The lexicon ID.
RArray < TPronunciationID > & aPronunciationIDs A reference where pronunciation IDs are stored.

MSrGetAllRuleIDsL(TGrammarID, RArray< TRuleID > &)

void MSrGetAllRuleIDsL ( TGrammarID aGrammarID,
RArray < TRuleID > & aRuleIDs
) [pure virtual]

Returns all rule IDs that exist in the specified grammar.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID.
RArray < TRuleID > & aRuleIDs A reference where rule IDs are stored.

MSrGetAvailableStorageL(TInt &)

void MSrGetAvailableStorageL ( TInt & aCount ) [pure virtual]

Returns the number of models available for training system wide, based on available disk space.

Since
8.0

Parameters

TInt & aCount A reference where the number of available models is set.

MSrGetEnginePropertiesL(const RArray< TInt > &, RArray< TInt > &)

void MSrGetEnginePropertiesL ( const RArray < TInt > & aPropertyId,
RArray < TInt > & aPropertyValue
) [pure virtual]

Returns the engine properties specified by the engine property ID array.

On return aPropertyValue contains an array of engine properties.

Since
8.0

Parameters

const RArray < TInt > & aPropertyId A constant reference to an array of engine property IDs.
RArray < TInt > & aPropertyValue A reference to an array of engine property values.

MSrGetModelCountL(TModelBankID, TInt &)

void MSrGetModelCountL ( TModelBankID aModelBankID,
TInt & aCount
) [pure virtual]

Returns the number of models in the specified model bank.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.
TInt & aCount A reference where the number of models is set.

MSrGetRuleValidityL(TGrammarID, TRuleID, TBool &)

void MSrGetRuleValidityL ( TGrammarID aGrammarID,
TRuleID aRuleID,
TBool & aValid
) [pure virtual]

Checks if the rule is valid or not.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID.
TRuleID aRuleID The rule ID.
TBool & aValid A reference where the validity of the rule is set.

MSrGetUtteranceDurationL(TModelBankID, TModelID, TTimeIntervalMicroSeconds32 &)

void MSrGetUtteranceDurationL ( TModelBankID aModelBankID,
TModelID aModelID,
TTimeIntervalMicroSeconds32 & aDuration
) [pure virtual]

Returns the duration of the utterance for the specified model.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.
TModelID aModelID The model ID.
TTimeIntervalMicroSeconds32 & aDuration A reference where the duration of utterance is set.

MSrLoadEngineParametersL(const RArray< TInt > &, const RArray< TInt > &)

void MSrLoadEngineParametersL ( const RArray < TInt > & aParameterId,
const RArray < TInt > & aParameterValue
) [pure virtual]

Unloads the specified parameters to the engine.

Since
8.0

Parameters

const RArray < TInt > & aParameterId An array of parameter IDs.
const RArray < TInt > & aParameterValue An array of parameter values.

MSrLoadGrammarL(TGrammarID)

void MSrLoadGrammarL ( TGrammarID aGrammarID ) [pure virtual]

Loads the specified grammar in into the recognizer; done prior to recognition.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID.

MSrLoadLexiconL(TLexiconID)

void MSrLoadLexiconL ( TLexiconID aLexiconID ) [pure virtual]

Loads the specified lexicon into the recognizer; done prior to recognition.

Since
8.0

Parameters

TLexiconID aLexiconID The lexicon ID.

MSrLoadModelsL(TModelBankID)

void MSrLoadModelsL ( TModelBankID aModelBankID ) [pure virtual]

Loads the specified model bank into the recognizer; done prior to recognition.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.

MSrPlayUtteranceL(TModelBankID, TModelID)

void MSrPlayUtteranceL ( TModelBankID aModelBankID,
TModelID aModelID
) [pure virtual]

Plays the previously trained utterance.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.
TModelID aModelID The model ID, whose utterance is played.

MSrRecognizeL(CSDClientResultSet &)

void MSrRecognizeL ( CSDClientResultSet & aResultSet ) [pure virtual]

Initiates recognition; performed following loading of model bank, lexicon, and grammar.

Since
8.0

Parameters

CSDClientResultSet & aResultSet A reference where the recognition result is set.

MSrRecordL(TTimeIntervalMicroSeconds32)

void MSrRecordL ( TTimeIntervalMicroSeconds32 aRecordTime ) [pure virtual]

Records user utterance for training and recognition.

Since
8.0

Parameters

TTimeIntervalMicroSeconds32 aRecordTime A recording time in microseconds.

MSrRemoveGrammarL(TGrammarID)

void MSrRemoveGrammarL ( TGrammarID aGrammarID ) [pure virtual]

Removes the specified grammar from the permanent storage.

Removing a grammar will remove all rules within the grammar.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID.

MSrRemoveLexiconL(TLexiconID)

void MSrRemoveLexiconL ( TLexiconID aLexiconID ) [pure virtual]

Removes the specified lexicon from the permanent storage.

Removing a lexicon will remove all pronunciations within the lexicon.

Since
8.0

Parameters

TLexiconID aLexiconID The lexicon ID.

MSrRemoveModelBankL(TModelBankID)

void MSrRemoveModelBankL ( TModelBankID aModelBankID ) [pure virtual]

Removes the specified model bank from the permanent storage.

Removing a model bank will remove all models within the model bank.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.

MSrRemoveModelL(TModelBankID, TModelID)

void MSrRemoveModelL ( TModelBankID aModelBankID,
TModelID aModelID
) [pure virtual]

Removes the specified model from the specified model bank permanently.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.
TModelID aModelID The model ID.

MSrRemovePronunciationL(TLexiconID, TPronunciationID)

void MSrRemovePronunciationL ( TLexiconID aLexiconID,
TPronunciationID aPronunciationID
) [pure virtual]

Removes the specified pronunciation from the specified lexicon permanently.

Since
8.0

Parameters

TLexiconID aLexiconID The lexicon ID.
TPronunciationID aPronunciationID The pronunciation ID.

MSrRemoveRuleL(TGrammarID, TRuleID)

void MSrRemoveRuleL ( TGrammarID aGrammarID,
TRuleID aRuleID
) [pure virtual]

Removes the specified rule from the specified grammar permanently.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID.
TRuleID aRuleID The rule ID.

MSrSetClientUid(TUid)

void MSrSetClientUid ( TUid aClientUid ) [pure virtual]

Sets the specified grammar client UID.

Parameters

TUid aClientUid The client UID.

MSrStartRecSessionL(TRecognitionMode)

void MSrStartRecSessionL ( TRecognitionMode aMode ) [pure virtual]

Starts a new recognition session.

Since
8.0

Parameters

TRecognitionMode aMode The recognition mode.

MSrTrainL(TModelBankID, TModelID &)

void MSrTrainL ( TModelBankID aModelBankID,
TModelID & aModelID
) [pure virtual]

Trains a new model into the specified model bank.

Since
8.0

Parameters

TModelBankID aModelBankID The model bank ID.
TModelID & aModelID A reference to where the new model ID is assigned.

MSrUnloadRuleL(TGrammarID, TRuleID)

void MSrUnloadRuleL ( TGrammarID aGrammarID,
TRuleID aRuleID
) [pure virtual]

Unloads the specified rule from the specified grammar in temporary memory, previously loaded with LoadGrammarL().

The rule in the permanent storage remains intact.

Since
8.0

Parameters

TGrammarID aGrammarID The grammar ID.
TRuleID aRuleID The rule ID.