Class WordInfo.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<WordInfo.Builder>
com.google.cloud.videointelligence.v1.WordInfo.Builder
- All Implemented Interfaces:
WordInfoOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- WordInfo
public static final class WordInfo.Builder
extends com.google.protobuf.GeneratedMessage.Builder<WordInfo.Builder>
implements WordInfoOrBuilder
Word-specific information for recognized words. Word information is only included in the response when certain request parameters are set, such as `enable_word_time_offsets`.Protobuf type
google.cloud.videointelligence.v1.WordInfo-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Output only.Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word.Output only.Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word.The word corresponding to this set of information.floatOutput only.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.Descriptorcom.google.protobuf.DurationTime offset relative to the beginning of the audio, and corresponding to the end of the spoken word.com.google.protobuf.Duration.BuilderTime offset relative to the beginning of the audio, and corresponding to the end of the spoken word.com.google.protobuf.DurationOrBuilderTime offset relative to the beginning of the audio, and corresponding to the end of the spoken word.intOutput only.com.google.protobuf.DurationTime offset relative to the beginning of the audio, and corresponding to the start of the spoken word.com.google.protobuf.Duration.BuilderTime offset relative to the beginning of the audio, and corresponding to the start of the spoken word.com.google.protobuf.DurationOrBuilderTime offset relative to the beginning of the audio, and corresponding to the start of the spoken word.getWord()The word corresponding to this set of information.com.google.protobuf.ByteStringThe word corresponding to this set of information.booleanTime offset relative to the beginning of the audio, and corresponding to the end of the spoken word.booleanTime offset relative to the beginning of the audio, and corresponding to the start of the spoken word.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeEndTime(com.google.protobuf.Duration value) Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word.mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) mergeStartTime(com.google.protobuf.Duration value) Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word.setConfidence(float value) Output only.setEndTime(com.google.protobuf.Duration value) Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word.setEndTime(com.google.protobuf.Duration.Builder builderForValue) Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word.setSpeakerTag(int value) Output only.setStartTime(com.google.protobuf.Duration value) Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word.setStartTime(com.google.protobuf.Duration.Builder builderForValue) Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word.The word corresponding to this set of information.setWordBytes(com.google.protobuf.ByteString value) The word corresponding to this set of information.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<WordInfo.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<WordInfo.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<WordInfo.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<WordInfo.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<WordInfo.Builder>
-
mergeFrom
public WordInfo.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<WordInfo.Builder>- Throws:
IOException
-
hasStartTime
public boolean hasStartTime()Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1;- Specified by:
hasStartTimein interfaceWordInfoOrBuilder- Returns:
- Whether the startTime field is set.
-
getStartTime
public com.google.protobuf.Duration getStartTime()Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1;- Specified by:
getStartTimein interfaceWordInfoOrBuilder- Returns:
- The startTime.
-
setStartTime
Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1; -
setStartTime
Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1; -
mergeStartTime
Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1; -
clearStartTime
Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1; -
getStartTimeBuilder
public com.google.protobuf.Duration.Builder getStartTimeBuilder()Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1; -
getStartTimeOrBuilder
public com.google.protobuf.DurationOrBuilder getStartTimeOrBuilder()Time offset relative to the beginning of the audio, and corresponding to the start of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration start_time = 1;- Specified by:
getStartTimeOrBuilderin interfaceWordInfoOrBuilder
-
hasEndTime
public boolean hasEndTime()Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2;- Specified by:
hasEndTimein interfaceWordInfoOrBuilder- Returns:
- Whether the endTime field is set.
-
getEndTime
public com.google.protobuf.Duration getEndTime()Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2;- Specified by:
getEndTimein interfaceWordInfoOrBuilder- Returns:
- The endTime.
-
setEndTime
Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2; -
setEndTime
Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2; -
mergeEndTime
Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2; -
clearEndTime
Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2; -
getEndTimeBuilder
public com.google.protobuf.Duration.Builder getEndTimeBuilder()Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2; -
getEndTimeOrBuilder
public com.google.protobuf.DurationOrBuilder getEndTimeOrBuilder()Time offset relative to the beginning of the audio, and corresponding to the end of the spoken word. This field is only set if `enable_word_time_offsets=true` and only in the top hypothesis. This is an experimental feature and the accuracy of the time offset can vary.
.google.protobuf.Duration end_time = 2;- Specified by:
getEndTimeOrBuilderin interfaceWordInfoOrBuilder
-
getWord
The word corresponding to this set of information.
string word = 3;- Specified by:
getWordin interfaceWordInfoOrBuilder- Returns:
- The word.
-
getWordBytes
public com.google.protobuf.ByteString getWordBytes()The word corresponding to this set of information.
string word = 3;- Specified by:
getWordBytesin interfaceWordInfoOrBuilder- Returns:
- The bytes for word.
-
setWord
The word corresponding to this set of information.
string word = 3;- Parameters:
value- The word to set.- Returns:
- This builder for chaining.
-
clearWord
The word corresponding to this set of information.
string word = 3;- Returns:
- This builder for chaining.
-
setWordBytes
The word corresponding to this set of information.
string word = 3;- Parameters:
value- The bytes for word to set.- Returns:
- This builder for chaining.
-
getConfidence
public float getConfidence()Output only. The confidence estimate between 0.0 and 1.0. A higher number indicates an estimated greater likelihood that the recognized words are correct. This field is set only for the top alternative. This field is not guaranteed to be accurate and users should not rely on it to be always provided. The default of 0.0 is a sentinel value indicating `confidence` was not set.
float confidence = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getConfidencein interfaceWordInfoOrBuilder- Returns:
- The confidence.
-
setConfidence
Output only. The confidence estimate between 0.0 and 1.0. A higher number indicates an estimated greater likelihood that the recognized words are correct. This field is set only for the top alternative. This field is not guaranteed to be accurate and users should not rely on it to be always provided. The default of 0.0 is a sentinel value indicating `confidence` was not set.
float confidence = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Parameters:
value- The confidence to set.- Returns:
- This builder for chaining.
-
clearConfidence
Output only. The confidence estimate between 0.0 and 1.0. A higher number indicates an estimated greater likelihood that the recognized words are correct. This field is set only for the top alternative. This field is not guaranteed to be accurate and users should not rely on it to be always provided. The default of 0.0 is a sentinel value indicating `confidence` was not set.
float confidence = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- This builder for chaining.
-
getSpeakerTag
public int getSpeakerTag()Output only. A distinct integer value is assigned for every speaker within the audio. This field specifies which one of those speakers was detected to have spoken this word. Value ranges from 1 up to diarization_speaker_count, and is only set if speaker diarization is enabled.
int32 speaker_tag = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getSpeakerTagin interfaceWordInfoOrBuilder- Returns:
- The speakerTag.
-
setSpeakerTag
Output only. A distinct integer value is assigned for every speaker within the audio. This field specifies which one of those speakers was detected to have spoken this word. Value ranges from 1 up to diarization_speaker_count, and is only set if speaker diarization is enabled.
int32 speaker_tag = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Parameters:
value- The speakerTag to set.- Returns:
- This builder for chaining.
-
clearSpeakerTag
Output only. A distinct integer value is assigned for every speaker within the audio. This field specifies which one of those speakers was detected to have spoken this word. Value ranges from 1 up to diarization_speaker_count, and is only set if speaker diarization is enabled.
int32 speaker_tag = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Returns:
- This builder for chaining.
-