Package com.google.cloud.translate.v3
Class RomanizeTextRequest.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<RomanizeTextRequest.Builder>
com.google.cloud.translate.v3.RomanizeTextRequest.Builder
- All Implemented Interfaces:
RomanizeTextRequestOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- RomanizeTextRequest
public static final class RomanizeTextRequest.Builder
extends com.google.protobuf.GeneratedMessage.Builder<RomanizeTextRequest.Builder>
implements RomanizeTextRequestOrBuilder
The request message for synchronous romanization.Protobuf type
google.cloud.translation.v3.RomanizeTextRequest-
Method Summary
Modifier and TypeMethodDescriptionaddAllContents(Iterable<String> values) Required.addContents(String value) Required.addContentsBytes(com.google.protobuf.ByteString value) Required.build()clear()Required.Required.Optional.getContents(int index) Required.com.google.protobuf.ByteStringgetContentsBytes(int index) Required.intRequired.com.google.protobuf.ProtocolStringListRequired.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorRequired.com.google.protobuf.ByteStringRequired.Optional.com.google.protobuf.ByteStringOptional.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFrom(RomanizeTextRequest other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setContents(int index, String value) Required.Required.setParentBytes(com.google.protobuf.ByteString value) Required.setSourceLanguageCode(String value) Optional.setSourceLanguageCodeBytes(com.google.protobuf.ByteString value) Optional.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<RomanizeTextRequest.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<RomanizeTextRequest.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<RomanizeTextRequest.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<RomanizeTextRequest.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<RomanizeTextRequest.Builder>
-
mergeFrom
public RomanizeTextRequest.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<RomanizeTextRequest.Builder>- Throws:
IOException
-
getParent
Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-number-or-id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global calls, use `projects/{project-number-or-id}/locations/global` or `projects/{project-number-or-id}`.string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }- Specified by:
getParentin interfaceRomanizeTextRequestOrBuilder- Returns:
- The parent.
-
getParentBytes
public com.google.protobuf.ByteString getParentBytes()Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-number-or-id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global calls, use `projects/{project-number-or-id}/locations/global` or `projects/{project-number-or-id}`.string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }- Specified by:
getParentBytesin interfaceRomanizeTextRequestOrBuilder- Returns:
- The bytes for parent.
-
setParent
Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-number-or-id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global calls, use `projects/{project-number-or-id}/locations/global` or `projects/{project-number-or-id}`.string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }- Parameters:
value- The parent to set.- Returns:
- This builder for chaining.
-
clearParent
Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-number-or-id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global calls, use `projects/{project-number-or-id}/locations/global` or `projects/{project-number-or-id}`.string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }- Returns:
- This builder for chaining.
-
setParentBytes
Required. Project or location to make a call. Must refer to a caller's project. Format: `projects/{project-number-or-id}/locations/{location-id}` or `projects/{project-number-or-id}`. For global calls, use `projects/{project-number-or-id}/locations/global` or `projects/{project-number-or-id}`.string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }- Parameters:
value- The bytes for parent to set.- Returns:
- This builder for chaining.
-
getContentsList
public com.google.protobuf.ProtocolStringList getContentsList()Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getContentsListin interfaceRomanizeTextRequestOrBuilder- Returns:
- A list containing the contents.
-
getContentsCount
public int getContentsCount()Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getContentsCountin interfaceRomanizeTextRequestOrBuilder- Returns:
- The count of contents.
-
getContents
Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getContentsin interfaceRomanizeTextRequestOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The contents at the given index.
-
getContentsBytes
public com.google.protobuf.ByteString getContentsBytes(int index) Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getContentsBytesin interfaceRomanizeTextRequestOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the contents at the given index.
-
setContents
Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
index- The index to set the value at.value- The contents to set.- Returns:
- This builder for chaining.
-
addContents
Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The contents to add.- Returns:
- This builder for chaining.
-
addAllContents
Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
values- The contents to add.- Returns:
- This builder for chaining.
-
clearContents
Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
addContentsBytes
Required. The content of the input in string format.
repeated string contents = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The bytes of the contents to add.- Returns:
- This builder for chaining.
-
getSourceLanguageCode
Optional. The ISO-639 language code of the input text if known, for example, "hi" or "zh". Supported language codes are listed in [Language Support](https://cloud.google.com/translate/docs/languages#roman). If the source language isn't specified, the API attempts to identify the source language automatically and returns the source language for each content in the response.
string source_language_code = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getSourceLanguageCodein interfaceRomanizeTextRequestOrBuilder- Returns:
- The sourceLanguageCode.
-
getSourceLanguageCodeBytes
public com.google.protobuf.ByteString getSourceLanguageCodeBytes()Optional. The ISO-639 language code of the input text if known, for example, "hi" or "zh". Supported language codes are listed in [Language Support](https://cloud.google.com/translate/docs/languages#roman). If the source language isn't specified, the API attempts to identify the source language automatically and returns the source language for each content in the response.
string source_language_code = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getSourceLanguageCodeBytesin interfaceRomanizeTextRequestOrBuilder- Returns:
- The bytes for sourceLanguageCode.
-
setSourceLanguageCode
Optional. The ISO-639 language code of the input text if known, for example, "hi" or "zh". Supported language codes are listed in [Language Support](https://cloud.google.com/translate/docs/languages#roman). If the source language isn't specified, the API attempts to identify the source language automatically and returns the source language for each content in the response.
string source_language_code = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The sourceLanguageCode to set.- Returns:
- This builder for chaining.
-
clearSourceLanguageCode
Optional. The ISO-639 language code of the input text if known, for example, "hi" or "zh". Supported language codes are listed in [Language Support](https://cloud.google.com/translate/docs/languages#roman). If the source language isn't specified, the API attempts to identify the source language automatically and returns the source language for each content in the response.
string source_language_code = 2 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setSourceLanguageCodeBytes
Optional. The ISO-639 language code of the input text if known, for example, "hi" or "zh". Supported language codes are listed in [Language Support](https://cloud.google.com/translate/docs/languages#roman). If the source language isn't specified, the API attempts to identify the source language automatically and returns the source language for each content in the response.
string source_language_code = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for sourceLanguageCode to set.- Returns:
- This builder for chaining.
-