public static enum StreamingRecognizeResponse.SpeechEventType extends Enum<StreamingRecognizeResponse.SpeechEventType> implements com.google.protobuf.ProtocolMessageEnum
Indicates the type of speech event.Protobuf enum
google.cloud.speech.v1.StreamingRecognizeResponse.SpeechEventType| Enum Constant and Description |
|---|
END_OF_SINGLE_UTTERANCE
This event indicates that the server has detected the end of the user's
speech utterance and expects no additional speech.
|
SPEECH_ACTIVITY_BEGIN
This event indicates that the server has detected the beginning of human
voice activity in the stream.
|
SPEECH_ACTIVITY_END
This event indicates that the server has detected the end of human voice
activity in the stream.
|
SPEECH_ACTIVITY_TIMEOUT
This event indicates that the user-set timeout for speech activity begin
or end has exceeded.
|
SPEECH_EVENT_UNSPECIFIED
No speech event specified.
|
UNRECOGNIZED |
| Modifier and Type | Field and Description |
|---|---|
static int |
END_OF_SINGLE_UTTERANCE_VALUE
This event indicates that the server has detected the end of the user's
speech utterance and expects no additional speech.
|
static int |
SPEECH_ACTIVITY_BEGIN_VALUE
This event indicates that the server has detected the beginning of human
voice activity in the stream.
|
static int |
SPEECH_ACTIVITY_END_VALUE
This event indicates that the server has detected the end of human voice
activity in the stream.
|
static int |
SPEECH_ACTIVITY_TIMEOUT_VALUE
This event indicates that the user-set timeout for speech activity begin
or end has exceeded.
|
static int |
SPEECH_EVENT_UNSPECIFIED_VALUE
No speech event specified.
|
| Modifier and Type | Method and Description |
|---|---|
static StreamingRecognizeResponse.SpeechEventType |
forNumber(int value) |
static com.google.protobuf.Descriptors.EnumDescriptor |
getDescriptor() |
com.google.protobuf.Descriptors.EnumDescriptor |
getDescriptorForType() |
int |
getNumber() |
com.google.protobuf.Descriptors.EnumValueDescriptor |
getValueDescriptor() |
static com.google.protobuf.Internal.EnumLiteMap<StreamingRecognizeResponse.SpeechEventType> |
internalGetValueMap() |
static StreamingRecognizeResponse.SpeechEventType |
valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) |
static StreamingRecognizeResponse.SpeechEventType |
valueOf(int value)
Deprecated.
Use
forNumber(int) instead. |
static StreamingRecognizeResponse.SpeechEventType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static StreamingRecognizeResponse.SpeechEventType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final StreamingRecognizeResponse.SpeechEventType SPEECH_EVENT_UNSPECIFIED
No speech event specified.
SPEECH_EVENT_UNSPECIFIED = 0;public static final StreamingRecognizeResponse.SpeechEventType END_OF_SINGLE_UTTERANCE
This event indicates that the server has detected the end of the user's speech utterance and expects no additional speech. Therefore, the server will not process additional audio (although it may subsequently return additional results). The client should stop sending additional audio data, half-close the gRPC connection, and wait for any additional results until the server closes the gRPC connection. This event is only sent if `single_utterance` was set to `true`, and is not used otherwise.
END_OF_SINGLE_UTTERANCE = 1;public static final StreamingRecognizeResponse.SpeechEventType SPEECH_ACTIVITY_BEGIN
This event indicates that the server has detected the beginning of human voice activity in the stream. This event can be returned multiple times if speech starts and stops repeatedly throughout the stream. This event is only sent if `voice_activity_events` is set to true.
SPEECH_ACTIVITY_BEGIN = 2;public static final StreamingRecognizeResponse.SpeechEventType SPEECH_ACTIVITY_END
This event indicates that the server has detected the end of human voice activity in the stream. This event can be returned multiple times if speech starts and stops repeatedly throughout the stream. This event is only sent if `voice_activity_events` is set to true.
SPEECH_ACTIVITY_END = 3;public static final StreamingRecognizeResponse.SpeechEventType SPEECH_ACTIVITY_TIMEOUT
This event indicates that the user-set timeout for speech activity begin or end has exceeded. Upon receiving this event, the client is expected to send a half close. Further audio will not be processed.
SPEECH_ACTIVITY_TIMEOUT = 4;public static final StreamingRecognizeResponse.SpeechEventType UNRECOGNIZED
public static final int SPEECH_EVENT_UNSPECIFIED_VALUE
No speech event specified.
SPEECH_EVENT_UNSPECIFIED = 0;public static final int END_OF_SINGLE_UTTERANCE_VALUE
This event indicates that the server has detected the end of the user's speech utterance and expects no additional speech. Therefore, the server will not process additional audio (although it may subsequently return additional results). The client should stop sending additional audio data, half-close the gRPC connection, and wait for any additional results until the server closes the gRPC connection. This event is only sent if `single_utterance` was set to `true`, and is not used otherwise.
END_OF_SINGLE_UTTERANCE = 1;public static final int SPEECH_ACTIVITY_BEGIN_VALUE
This event indicates that the server has detected the beginning of human voice activity in the stream. This event can be returned multiple times if speech starts and stops repeatedly throughout the stream. This event is only sent if `voice_activity_events` is set to true.
SPEECH_ACTIVITY_BEGIN = 2;public static final int SPEECH_ACTIVITY_END_VALUE
This event indicates that the server has detected the end of human voice activity in the stream. This event can be returned multiple times if speech starts and stops repeatedly throughout the stream. This event is only sent if `voice_activity_events` is set to true.
SPEECH_ACTIVITY_END = 3;public static final int SPEECH_ACTIVITY_TIMEOUT_VALUE
This event indicates that the user-set timeout for speech activity begin or end has exceeded. Upon receiving this event, the client is expected to send a half close. Further audio will not be processed.
SPEECH_ACTIVITY_TIMEOUT = 4;public static StreamingRecognizeResponse.SpeechEventType[] values()
for (StreamingRecognizeResponse.SpeechEventType c : StreamingRecognizeResponse.SpeechEventType.values()) System.out.println(c);
public static StreamingRecognizeResponse.SpeechEventType valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic final int getNumber()
getNumber in interface com.google.protobuf.Internal.EnumLitegetNumber in interface com.google.protobuf.ProtocolMessageEnum@Deprecated public static StreamingRecognizeResponse.SpeechEventType valueOf(int value)
forNumber(int) instead.value - The numeric wire value of the corresponding enum entry.public static StreamingRecognizeResponse.SpeechEventType forNumber(int value)
value - The numeric wire value of the corresponding enum entry.public static com.google.protobuf.Internal.EnumLiteMap<StreamingRecognizeResponse.SpeechEventType> internalGetValueMap()
public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor()
getValueDescriptor in interface com.google.protobuf.ProtocolMessageEnumpublic final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.ProtocolMessageEnumpublic static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor()
public static StreamingRecognizeResponse.SpeechEventType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)
Copyright © 2024 Google LLC. All rights reserved.