Cloud Speech V2 Client - Class VoiceActivityTimeout (1.14.3)

Reference documentation and code samples for the Cloud Speech V2 Client class VoiceActivityTimeout.

Events that a timeout can be set on for voice activity.

Generated from protobuf message google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout

Namespace

Google \ Cloud \ Speech \ V2 \ StreamingRecognitionFeatures

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ speech_start_timeout Google\Protobuf\Duration

Duration to timeout the stream if no speech begins. If this is set and no speech is detected in this duration at the start of the stream, the server will close the stream.

↳ speech_end_timeout Google\Protobuf\Duration

Duration to timeout the stream after speech ends. If this is set and no speech is detected in this duration after speech was detected, the server will close the stream.

getSpeechStartTimeout

Duration to timeout the stream if no speech begins. If this is set and no speech is detected in this duration at the start of the stream, the server will close the stream.

Returns
TypeDescription
Google\Protobuf\Duration|null

hasSpeechStartTimeout

clearSpeechStartTimeout

setSpeechStartTimeout

Duration to timeout the stream if no speech begins. If this is set and no speech is detected in this duration at the start of the stream, the server will close the stream.

Parameter
NameDescription
var Google\Protobuf\Duration
Returns
TypeDescription
$this

getSpeechEndTimeout

Duration to timeout the stream after speech ends. If this is set and no speech is detected in this duration after speech was detected, the server will close the stream.

Returns
TypeDescription
Google\Protobuf\Duration|null

hasSpeechEndTimeout

clearSpeechEndTimeout

setSpeechEndTimeout

Duration to timeout the stream after speech ends. If this is set and no speech is detected in this duration after speech was detected, the server will close the stream.

Parameter
NameDescription
var Google\Protobuf\Duration
Returns
TypeDescription
$this