pub struct DialogServiceConnector {
    pub properties: PropertyCollection,
    pub handle: SmartHandle<SPXRECOHANDLE>,
    /* private fields */
}
Expand description

DialogServiceConnector connects to a speech enabled dialog backend.

Fields

properties: PropertyCollectionhandle: SmartHandle<SPXRECOHANDLE>

Implementations

NewDialogServiceConnectorFromConfig creates a dialog service connector from a dialog service config and an audio config. Users should use this function to create a dialog service connector.

Sends an activity to the backing dialog.

ListenOnceAsync starts a listening session that will terminate after the first utterance.

StartKeywordRecognitionAsync initiates keyword recognition.

StopKeywordRecognitionAsync stops keyword recognition.

Sets the authorization token that will be used for connecting to the service. Note: The caller needs to ensure that the authorization token is valid. Before the authorization token expires, the caller needs to refresh it by calling this setter with a new valid token. Otherwise, the connector will encounter errors during its operation.

Sets the speech activity template. It is used to stamp properties from the template on the service generated activty for speech.

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.