Class BargeInConfig.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<BargeInConfig.Builder>
com.google.cloud.dialogflow.v2beta1.BargeInConfig.Builder
- All Implemented Interfaces:
BargeInConfigOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- BargeInConfig
public static final class BargeInConfig.Builder
extends com.google.protobuf.GeneratedMessage.Builder<BargeInConfig.Builder>
implements BargeInConfigOrBuilder
Configuration of the barge-in behavior. Barge-in instructs the API to return a detected utterance at a proper time while the client is playing back the response audio from a previous request. When the client sees the utterance, it should stop the playback and immediately get ready for receiving the responses for the current request. The barge-in handling requires the client to start streaming audio input as soon as it starts playing back the audio from the previous response. The playback is modeled into two phases: * No barge-in phase: which goes first and during which speech detection should not be carried out. * Barge-in phase: which follows the no barge-in phase and during which the API starts speech detection and may inform the client that an utterance has been detected. Note that no-speech event is not expected in this phase. The client provides this configuration in terms of the durations of those two phases. The durations are measured in terms of the audio length from the start of the input audio. The flow goes like below: ``` --> Time without speech detection | utterance only | utterance or no-speech event | | +-------------+ | +------------+ | +---------------+ ----------+ no barge-in +-|-+ barge-in +-|-+ normal period +----------- +-------------+ | +------------+ | +---------------+ ``` No-speech event is a response with END_OF_UTTERANCE without any transcript following up.Protobuf type
google.cloud.dialogflow.v2beta1.BargeInConfig-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Duration that is not eligible for barge-in at the beginning of the input audio.Total duration for the playback at the beginning of the input audio.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.Descriptorcom.google.protobuf.DurationDuration that is not eligible for barge-in at the beginning of the input audio.com.google.protobuf.Duration.BuilderDuration that is not eligible for barge-in at the beginning of the input audio.com.google.protobuf.DurationOrBuilderDuration that is not eligible for barge-in at the beginning of the input audio.com.google.protobuf.DurationTotal duration for the playback at the beginning of the input audio.com.google.protobuf.Duration.BuilderTotal duration for the playback at the beginning of the input audio.com.google.protobuf.DurationOrBuilderTotal duration for the playback at the beginning of the input audio.booleanDuration that is not eligible for barge-in at the beginning of the input audio.booleanTotal duration for the playback at the beginning of the input audio.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFrom(BargeInConfig other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) mergeNoBargeInDuration(com.google.protobuf.Duration value) Duration that is not eligible for barge-in at the beginning of the input audio.mergeTotalDuration(com.google.protobuf.Duration value) Total duration for the playback at the beginning of the input audio.setNoBargeInDuration(com.google.protobuf.Duration value) Duration that is not eligible for barge-in at the beginning of the input audio.setNoBargeInDuration(com.google.protobuf.Duration.Builder builderForValue) Duration that is not eligible for barge-in at the beginning of the input audio.setTotalDuration(com.google.protobuf.Duration value) Total duration for the playback at the beginning of the input audio.setTotalDuration(com.google.protobuf.Duration.Builder builderForValue) Total duration for the playback at the beginning of the input audio.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<BargeInConfig.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<BargeInConfig.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<BargeInConfig.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<BargeInConfig.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<BargeInConfig.Builder>
-
mergeFrom
public BargeInConfig.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<BargeInConfig.Builder>- Throws:
IOException
-
hasNoBargeInDuration
public boolean hasNoBargeInDuration()Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1;- Specified by:
hasNoBargeInDurationin interfaceBargeInConfigOrBuilder- Returns:
- Whether the noBargeInDuration field is set.
-
getNoBargeInDuration
public com.google.protobuf.Duration getNoBargeInDuration()Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1;- Specified by:
getNoBargeInDurationin interfaceBargeInConfigOrBuilder- Returns:
- The noBargeInDuration.
-
setNoBargeInDuration
Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1; -
setNoBargeInDuration
public BargeInConfig.Builder setNoBargeInDuration(com.google.protobuf.Duration.Builder builderForValue) Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1; -
mergeNoBargeInDuration
Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1; -
clearNoBargeInDuration
Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1; -
getNoBargeInDurationBuilder
public com.google.protobuf.Duration.Builder getNoBargeInDurationBuilder()Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1; -
getNoBargeInDurationOrBuilder
public com.google.protobuf.DurationOrBuilder getNoBargeInDurationOrBuilder()Duration that is not eligible for barge-in at the beginning of the input audio.
.google.protobuf.Duration no_barge_in_duration = 1;- Specified by:
getNoBargeInDurationOrBuilderin interfaceBargeInConfigOrBuilder
-
hasTotalDuration
public boolean hasTotalDuration()Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2;- Specified by:
hasTotalDurationin interfaceBargeInConfigOrBuilder- Returns:
- Whether the totalDuration field is set.
-
getTotalDuration
public com.google.protobuf.Duration getTotalDuration()Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2;- Specified by:
getTotalDurationin interfaceBargeInConfigOrBuilder- Returns:
- The totalDuration.
-
setTotalDuration
Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2; -
setTotalDuration
Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2; -
mergeTotalDuration
Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2; -
clearTotalDuration
Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2; -
getTotalDurationBuilder
public com.google.protobuf.Duration.Builder getTotalDurationBuilder()Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2; -
getTotalDurationOrBuilder
public com.google.protobuf.DurationOrBuilder getTotalDurationOrBuilder()Total duration for the playback at the beginning of the input audio.
.google.protobuf.Duration total_duration = 2;- Specified by:
getTotalDurationOrBuilderin interfaceBargeInConfigOrBuilder
-