Class TranslationModelMetadata.Builder (2.43.0)

public static final class TranslationModelMetadata.Builder extends GeneratedMessageV3.Builder<TranslationModelMetadata.Builder> implements TranslationModelMetadataOrBuilder

Model metadata that is specific to translation.

Protobuf type google.cloud.automl.v1beta1.TranslationModelMetadata

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public TranslationModelMetadata.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

build()

public TranslationModelMetadata build()
Returns
Type Description
TranslationModelMetadata

buildPartial()

public TranslationModelMetadata buildPartial()
Returns
Type Description
TranslationModelMetadata

clear()

public TranslationModelMetadata.Builder clear()
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

clearBaseModel()

public TranslationModelMetadata.Builder clearBaseModel()

The resource name of the model to use as a baseline to train the custom model. If unset, we use the default base model provided by Google Translate. Format: projects/{project_id}/locations/{location_id}/models/{model_id}

string base_model = 1;

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public TranslationModelMetadata.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public TranslationModelMetadata.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

clearSourceLanguageCode()

public TranslationModelMetadata.Builder clearSourceLanguageCode()

Output only. Inferred from the dataset. The source languge (The BCP-47 language code) that is used for training.

string source_language_code = 2;

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

clearTargetLanguageCode()

public TranslationModelMetadata.Builder clearTargetLanguageCode()

Output only. The target languge (The BCP-47 language code) that is used for training.

string target_language_code = 3;

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

clone()

public TranslationModelMetadata.Builder clone()
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

getBaseModel()

public String getBaseModel()

The resource name of the model to use as a baseline to train the custom model. If unset, we use the default base model provided by Google Translate. Format: projects/{project_id}/locations/{location_id}/models/{model_id}

string base_model = 1;

Returns
Type Description
String

The baseModel.

getBaseModelBytes()

public ByteString getBaseModelBytes()

The resource name of the model to use as a baseline to train the custom model. If unset, we use the default base model provided by Google Translate. Format: projects/{project_id}/locations/{location_id}/models/{model_id}

string base_model = 1;

Returns
Type Description
ByteString

The bytes for baseModel.

getDefaultInstanceForType()

public TranslationModelMetadata getDefaultInstanceForType()
Returns
Type Description
TranslationModelMetadata

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getSourceLanguageCode()

public String getSourceLanguageCode()

Output only. Inferred from the dataset. The source languge (The BCP-47 language code) that is used for training.

string source_language_code = 2;

Returns
Type Description
String

The sourceLanguageCode.

getSourceLanguageCodeBytes()

public ByteString getSourceLanguageCodeBytes()

Output only. Inferred from the dataset. The source languge (The BCP-47 language code) that is used for training.

string source_language_code = 2;

Returns
Type Description
ByteString

The bytes for sourceLanguageCode.

getTargetLanguageCode()

public String getTargetLanguageCode()

Output only. The target languge (The BCP-47 language code) that is used for training.

string target_language_code = 3;

Returns
Type Description
String

The targetLanguageCode.

getTargetLanguageCodeBytes()

public ByteString getTargetLanguageCodeBytes()

Output only. The target languge (The BCP-47 language code) that is used for training.

string target_language_code = 3;

Returns
Type Description
ByteString

The bytes for targetLanguageCode.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(TranslationModelMetadata other)

public TranslationModelMetadata.Builder mergeFrom(TranslationModelMetadata other)
Parameter
Name Description
other TranslationModelMetadata
Returns
Type Description
TranslationModelMetadata.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public TranslationModelMetadata.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
TranslationModelMetadata.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public TranslationModelMetadata.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final TranslationModelMetadata.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

setBaseModel(String value)

public TranslationModelMetadata.Builder setBaseModel(String value)

The resource name of the model to use as a baseline to train the custom model. If unset, we use the default base model provided by Google Translate. Format: projects/{project_id}/locations/{location_id}/models/{model_id}

string base_model = 1;

Parameter
Name Description
value String

The baseModel to set.

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

setBaseModelBytes(ByteString value)

public TranslationModelMetadata.Builder setBaseModelBytes(ByteString value)

The resource name of the model to use as a baseline to train the custom model. If unset, we use the default base model provided by Google Translate. Format: projects/{project_id}/locations/{location_id}/models/{model_id}

string base_model = 1;

Parameter
Name Description
value ByteString

The bytes for baseModel to set.

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public TranslationModelMetadata.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

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

public TranslationModelMetadata.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
TranslationModelMetadata.Builder
Overrides

setSourceLanguageCode(String value)

public TranslationModelMetadata.Builder setSourceLanguageCode(String value)

Output only. Inferred from the dataset. The source languge (The BCP-47 language code) that is used for training.

string source_language_code = 2;

Parameter
Name Description
value String

The sourceLanguageCode to set.

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

setSourceLanguageCodeBytes(ByteString value)

public TranslationModelMetadata.Builder setSourceLanguageCodeBytes(ByteString value)

Output only. Inferred from the dataset. The source languge (The BCP-47 language code) that is used for training.

string source_language_code = 2;

Parameter
Name Description
value ByteString

The bytes for sourceLanguageCode to set.

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

setTargetLanguageCode(String value)

public TranslationModelMetadata.Builder setTargetLanguageCode(String value)

Output only. The target languge (The BCP-47 language code) that is used for training.

string target_language_code = 3;

Parameter
Name Description
value String

The targetLanguageCode to set.

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

setTargetLanguageCodeBytes(ByteString value)

public TranslationModelMetadata.Builder setTargetLanguageCodeBytes(ByteString value)

Output only. The target languge (The BCP-47 language code) that is used for training.

string target_language_code = 3;

Parameter
Name Description
value ByteString

The bytes for targetLanguageCode to set.

Returns
Type Description
TranslationModelMetadata.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final TranslationModelMetadata.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
TranslationModelMetadata.Builder
Overrides