Class AdaptiveMtTranslateResponse.Builder (2.33.0)

public static final class AdaptiveMtTranslateResponse.Builder extends GeneratedMessageV3.Builder<AdaptiveMtTranslateResponse.Builder> implements AdaptiveMtTranslateResponseOrBuilder

An AdaptiveMtTranslate response.

Protobuf type google.cloud.translation.v3.AdaptiveMtTranslateResponse

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllTranslations(Iterable<? extends AdaptiveMtTranslation> values)

public AdaptiveMtTranslateResponse.Builder addAllTranslations(Iterable<? extends AdaptiveMtTranslation> values)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.translate.v3.AdaptiveMtTranslation>
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public AdaptiveMtTranslateResponse.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

addTranslations(AdaptiveMtTranslation value)

public AdaptiveMtTranslateResponse.Builder addTranslations(AdaptiveMtTranslation value)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueAdaptiveMtTranslation
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

addTranslations(AdaptiveMtTranslation.Builder builderForValue)

public AdaptiveMtTranslateResponse.Builder addTranslations(AdaptiveMtTranslation.Builder builderForValue)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
builderForValueAdaptiveMtTranslation.Builder
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

addTranslations(int index, AdaptiveMtTranslation value)

public AdaptiveMtTranslateResponse.Builder addTranslations(int index, AdaptiveMtTranslation value)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameters
NameDescription
indexint
valueAdaptiveMtTranslation
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

addTranslations(int index, AdaptiveMtTranslation.Builder builderForValue)

public AdaptiveMtTranslateResponse.Builder addTranslations(int index, AdaptiveMtTranslation.Builder builderForValue)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameters
NameDescription
indexint
builderForValueAdaptiveMtTranslation.Builder
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

addTranslationsBuilder()

public AdaptiveMtTranslation.Builder addTranslationsBuilder()

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
AdaptiveMtTranslation.Builder

addTranslationsBuilder(int index)

public AdaptiveMtTranslation.Builder addTranslationsBuilder(int index)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
indexint
Returns
TypeDescription
AdaptiveMtTranslation.Builder

build()

public AdaptiveMtTranslateResponse build()
Returns
TypeDescription
AdaptiveMtTranslateResponse

buildPartial()

public AdaptiveMtTranslateResponse buildPartial()
Returns
TypeDescription
AdaptiveMtTranslateResponse

clear()

public AdaptiveMtTranslateResponse.Builder clear()
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public AdaptiveMtTranslateResponse.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

clearLanguageCode()

public AdaptiveMtTranslateResponse.Builder clearLanguageCode()

Output only. The translation's language code.

string language_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public AdaptiveMtTranslateResponse.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

clearTranslations()

public AdaptiveMtTranslateResponse.Builder clearTranslations()

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

clone()

public AdaptiveMtTranslateResponse.Builder clone()
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

getDefaultInstanceForType()

public AdaptiveMtTranslateResponse getDefaultInstanceForType()
Returns
TypeDescription
AdaptiveMtTranslateResponse

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getLanguageCode()

public String getLanguageCode()

Output only. The translation's language code.

string language_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The languageCode.

getLanguageCodeBytes()

public ByteString getLanguageCodeBytes()

Output only. The translation's language code.

string language_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for languageCode.

getTranslations(int index)

public AdaptiveMtTranslation getTranslations(int index)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
indexint
Returns
TypeDescription
AdaptiveMtTranslation

getTranslationsBuilder(int index)

public AdaptiveMtTranslation.Builder getTranslationsBuilder(int index)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
indexint
Returns
TypeDescription
AdaptiveMtTranslation.Builder

getTranslationsBuilderList()

public List<AdaptiveMtTranslation.Builder> getTranslationsBuilderList()

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
List<Builder>

getTranslationsCount()

public int getTranslationsCount()

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

getTranslationsList()

public List<AdaptiveMtTranslation> getTranslationsList()

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
List<AdaptiveMtTranslation>

getTranslationsOrBuilder(int index)

public AdaptiveMtTranslationOrBuilder getTranslationsOrBuilder(int index)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
indexint
Returns
TypeDescription
AdaptiveMtTranslationOrBuilder

getTranslationsOrBuilderList()

public List<? extends AdaptiveMtTranslationOrBuilder> getTranslationsOrBuilderList()

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
List<? extends com.google.cloud.translate.v3.AdaptiveMtTranslationOrBuilder>

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(AdaptiveMtTranslateResponse other)

public AdaptiveMtTranslateResponse.Builder mergeFrom(AdaptiveMtTranslateResponse other)
Parameter
NameDescription
otherAdaptiveMtTranslateResponse
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public AdaptiveMtTranslateResponse.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public AdaptiveMtTranslateResponse.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final AdaptiveMtTranslateResponse.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

removeTranslations(int index)

public AdaptiveMtTranslateResponse.Builder removeTranslations(int index)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
indexint
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public AdaptiveMtTranslateResponse.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

setLanguageCode(String value)

public AdaptiveMtTranslateResponse.Builder setLanguageCode(String value)

Output only. The translation's language code.

string language_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueString

The languageCode to set.

Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

This builder for chaining.

setLanguageCodeBytes(ByteString value)

public AdaptiveMtTranslateResponse.Builder setLanguageCodeBytes(ByteString value)

Output only. The translation's language code.

string language_code = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueByteString

The bytes for languageCode to set.

Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public AdaptiveMtTranslateResponse.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides

setTranslations(int index, AdaptiveMtTranslation value)

public AdaptiveMtTranslateResponse.Builder setTranslations(int index, AdaptiveMtTranslation value)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameters
NameDescription
indexint
valueAdaptiveMtTranslation
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

setTranslations(int index, AdaptiveMtTranslation.Builder builderForValue)

public AdaptiveMtTranslateResponse.Builder setTranslations(int index, AdaptiveMtTranslation.Builder builderForValue)

Output only. The translation.

repeated .google.cloud.translation.v3.AdaptiveMtTranslation translations = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameters
NameDescription
indexint
builderForValueAdaptiveMtTranslation.Builder
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder

setUnknownFields(UnknownFieldSet unknownFields)

public final AdaptiveMtTranslateResponse.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
AdaptiveMtTranslateResponse.Builder
Overrides