public static final class StreamingTranslateSpeechResult.TextTranslationResult.Builder extends GeneratedMessageV3.Builder<StreamingTranslateSpeechResult.TextTranslationResult.Builder> implements StreamingTranslateSpeechResult.TextTranslationResultOrBuilder
Text translation result.
Protobuf type
google.cloud.mediatranslation.v1beta1.StreamingTranslateSpeechResult.TextTranslationResult
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Overrides
build()
public StreamingTranslateSpeechResult.TextTranslationResult build()
buildPartial()
public StreamingTranslateSpeechResult.TextTranslationResult buildPartial()
clear()
public StreamingTranslateSpeechResult.TextTranslationResult.Builder clear()
Overrides
clearField(Descriptors.FieldDescriptor field)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder clearField(Descriptors.FieldDescriptor field)
Overrides
clearIsFinal()
public StreamingTranslateSpeechResult.TextTranslationResult.Builder clearIsFinal()
Output only. If false
, this StreamingTranslateSpeechResult
represents
an interim result that may change. If true
, this is the final time the
translation service will return this particular
StreamingTranslateSpeechResult
, the streaming translator will not
return any further hypotheses for this portion of the transcript and
corresponding audio.
bool is_final = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
clearOneof(Descriptors.OneofDescriptor oneof)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Overrides
clearTranslation()
public StreamingTranslateSpeechResult.TextTranslationResult.Builder clearTranslation()
Output only. The translated sentence.
string translation = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
clone()
public StreamingTranslateSpeechResult.TextTranslationResult.Builder clone()
Overrides
getDefaultInstanceForType()
public StreamingTranslateSpeechResult.TextTranslationResult getDefaultInstanceForType()
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Overrides
getIsFinal()
public boolean getIsFinal()
Output only. If false
, this StreamingTranslateSpeechResult
represents
an interim result that may change. If true
, this is the final time the
translation service will return this particular
StreamingTranslateSpeechResult
, the streaming translator will not
return any further hypotheses for this portion of the transcript and
corresponding audio.
bool is_final = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
---|
Type | Description |
boolean | The isFinal.
|
getTranslation()
public String getTranslation()
Output only. The translated sentence.
string translation = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
---|
Type | Description |
String | The translation.
|
getTranslationBytes()
public ByteString getTranslationBytes()
Output only. The translated sentence.
string translation = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
---|
Type | Description |
ByteString | The bytes for translation.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
mergeFrom(StreamingTranslateSpeechResult.TextTranslationResult other)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder mergeFrom(StreamingTranslateSpeechResult.TextTranslationResult other)
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Overrides
mergeFrom(Message other)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder mergeFrom(Message other)
Parameter |
---|
Name | Description |
other | Message
|
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final StreamingTranslateSpeechResult.TextTranslationResult.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Overrides
setField(Descriptors.FieldDescriptor field, Object value)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder setField(Descriptors.FieldDescriptor field, Object value)
Overrides
setIsFinal(boolean value)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder setIsFinal(boolean value)
Output only. If false
, this StreamingTranslateSpeechResult
represents
an interim result that may change. If true
, this is the final time the
translation service will return this particular
StreamingTranslateSpeechResult
, the streaming translator will not
return any further hypotheses for this portion of the transcript and
corresponding audio.
bool is_final = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
---|
Name | Description |
value | boolean
The isFinal to set.
|
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Overrides
setTranslation(String value)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder setTranslation(String value)
Output only. The translated sentence.
string translation = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
---|
Name | Description |
value | String
The translation to set.
|
setTranslationBytes(ByteString value)
public StreamingTranslateSpeechResult.TextTranslationResult.Builder setTranslationBytes(ByteString value)
Output only. The translated sentence.
string translation = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
---|
Name | Description |
value | ByteString
The bytes for translation to set.
|
setUnknownFields(UnknownFieldSet unknownFields)
public final StreamingTranslateSpeechResult.TextTranslationResult.Builder setUnknownFields(UnknownFieldSet unknownFields)
Overrides