public interface TranslateTextRequestOrBuilder
extends com.google.protobuf.MessageOrBuilder
| Modifier and Type | Method and Description |
|---|---|
String |
getContents(int index)
Required.
|
com.google.protobuf.ByteString |
getContentsBytes(int index)
Required.
|
int |
getContentsCount()
Required.
|
List<String> |
getContentsList()
Required.
|
TranslateTextGlossaryConfig |
getGlossaryConfig()
Optional.
|
TranslateTextGlossaryConfigOrBuilder |
getGlossaryConfigOrBuilder()
Optional.
|
String |
getMimeType()
Optional.
|
com.google.protobuf.ByteString |
getMimeTypeBytes()
Optional.
|
String |
getModel()
Optional.
|
com.google.protobuf.ByteString |
getModelBytes()
Optional.
|
String |
getParent()
Optional.
|
com.google.protobuf.ByteString |
getParentBytes()
Optional.
|
String |
getSourceLanguageCode()
Optional.
|
com.google.protobuf.ByteString |
getSourceLanguageCodeBytes()
Optional.
|
String |
getTargetLanguageCode()
Required.
|
com.google.protobuf.ByteString |
getTargetLanguageCodeBytes()
Required.
|
boolean |
hasGlossaryConfig()
Optional.
|
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneofList<String> getContentsList()
Required. The content of the input in string format. We recommend the total contents to be less than 30k codepoints. Please use BatchTranslateText for larger text.
repeated string contents = 1;int getContentsCount()
Required. The content of the input in string format. We recommend the total contents to be less than 30k codepoints. Please use BatchTranslateText for larger text.
repeated string contents = 1;String getContents(int index)
Required. The content of the input in string format. We recommend the total contents to be less than 30k codepoints. Please use BatchTranslateText for larger text.
repeated string contents = 1;com.google.protobuf.ByteString getContentsBytes(int index)
Required. The content of the input in string format. We recommend the total contents to be less than 30k codepoints. Please use BatchTranslateText for larger text.
repeated string contents = 1;String getMimeType()
Optional. The format of the source text, for example, "text/html", "text/plain". If left blank, the MIME type is assumed to be "text/html".
string mime_type = 3;com.google.protobuf.ByteString getMimeTypeBytes()
Optional. The format of the source text, for example, "text/html", "text/plain". If left blank, the MIME type is assumed to be "text/html".
string mime_type = 3;String getSourceLanguageCode()
Optional. The BCP-47 language code of the input text if known, for example, "en-US" or "sr-Latn". Supported language codes are listed in Language Support. If the source language isn't specified, the API attempts to identify the source language automatically and returns the the source language within the response.
string source_language_code = 4;com.google.protobuf.ByteString getSourceLanguageCodeBytes()
Optional. The BCP-47 language code of the input text if known, for example, "en-US" or "sr-Latn". Supported language codes are listed in Language Support. If the source language isn't specified, the API attempts to identify the source language automatically and returns the the source language within the response.
string source_language_code = 4;String getTargetLanguageCode()
Required. The BCP-47 language code to use for translation of the input text, set to one of the language codes listed in Language Support.
string target_language_code = 5;com.google.protobuf.ByteString getTargetLanguageCodeBytes()
Required. The BCP-47 language code to use for translation of the input text, set to one of the language codes listed in Language Support.
string target_language_code = 5;String getParent()
Optional. Only used when making regionalized call.
Format:
projects/{project-id}/locations/{location-id}.
Only custom model/glossary within the same location-id can be used.
Otherwise 400 is returned.
string parent = 8;com.google.protobuf.ByteString getParentBytes()
Optional. Only used when making regionalized call.
Format:
projects/{project-id}/locations/{location-id}.
Only custom model/glossary within the same location-id can be used.
Otherwise 400 is returned.
string parent = 8;String getModel()
Optional. The `model` type requested for this translation.
The format depends on model type:
1. Custom models:
projects/{project-id}/locations/{location-id}/models/{model-id}.
2. General (built-in) models:
projects/{project-id}/locations/{location-id}/models/general/nmt
projects/{project-id}/locations/{location-id}/models/general/base
For global (non-regionalized) requests, use {location-id} 'global'.
For example,
projects/{project-id}/locations/global/models/general/nmt
If missing, the system decides which google base model to use.
string model = 6;com.google.protobuf.ByteString getModelBytes()
Optional. The `model` type requested for this translation.
The format depends on model type:
1. Custom models:
projects/{project-id}/locations/{location-id}/models/{model-id}.
2. General (built-in) models:
projects/{project-id}/locations/{location-id}/models/general/nmt
projects/{project-id}/locations/{location-id}/models/general/base
For global (non-regionalized) requests, use {location-id} 'global'.
For example,
projects/{project-id}/locations/global/models/general/nmt
If missing, the system decides which google base model to use.
string model = 6;boolean hasGlossaryConfig()
Optional. Glossary to be applied. The glossary needs to be in the same region as the model, otherwise an INVALID_ARGUMENT error is returned.
.google.cloud.translation.v3beta1.TranslateTextGlossaryConfig glossary_config = 7;TranslateTextGlossaryConfig getGlossaryConfig()
Optional. Glossary to be applied. The glossary needs to be in the same region as the model, otherwise an INVALID_ARGUMENT error is returned.
.google.cloud.translation.v3beta1.TranslateTextGlossaryConfig glossary_config = 7;TranslateTextGlossaryConfigOrBuilder getGlossaryConfigOrBuilder()
Optional. Glossary to be applied. The glossary needs to be in the same region as the model, otherwise an INVALID_ARGUMENT error is returned.
.google.cloud.translation.v3beta1.TranslateTextGlossaryConfig glossary_config = 7;Copyright © 2019 Google LLC. All rights reserved.