pub struct SessionsClient { /* private fields */ }
Expand description

Google Dialogflow sessions client. Used for detect intent API. Is cloneable!

Implementations

Creates new sessions client using GCP project JSON credentials This client should be used for synchronous invocation (detect_intent)

Returns sender than can be used to stream in audio bytes. This method will take the sender out of the option leaving None in its place. No additional sender can be retrieved from session client after this call. When sender is dropped respective stream will be closed.

Returns sender than can be used to stream in audio bytes. This method will take the sender out of the option leaving None in its place. No additional sender can be retrieved from session client after this call. When sender is dropped respective stream will be closed.

Drops audio sender so that respective stream can be closed.

Convenience function so that client does not have to create full StreamingDetectIntentRequest and can just pass audio bytes vector instead.

Calls detect_intent API of underlying GRPC SessionClient.

Convenience function to check if DetectIntentResponse represents end of conversation. If so, returns true, otherwise false.

Convenience function to return properly formatted session string for detect intent call.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

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.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

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

Wrap the input message T in a tonic::Request

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

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.