public static final class Document.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder> implements DocumentOrBuilder
################################################################ # Represents the input to API methods.Protobuf type
google.cloud.language.v1.Document| Modifier and Type | Method and Description |
|---|---|
Document.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) |
Document |
build() |
Document |
buildPartial() |
Document.Builder |
clear() |
Document.Builder |
clearContent()
The content of the input in string format.
|
Document.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
Document.Builder |
clearGcsContentUri()
The Google Cloud Storage URI where the file content is located.
|
Document.Builder |
clearLanguage()
The language of the document (if not specified, the language is
automatically detected).
|
Document.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
Document.Builder |
clearSource() |
Document.Builder |
clearType()
Required.
|
Document.Builder |
clone() |
java.lang.String |
getContent()
The content of the input in string format.
|
com.google.protobuf.ByteString |
getContentBytes()
The content of the input in string format.
|
Document |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
java.lang.String |
getGcsContentUri()
The Google Cloud Storage URI where the file content is located.
|
com.google.protobuf.ByteString |
getGcsContentUriBytes()
The Google Cloud Storage URI where the file content is located.
|
java.lang.String |
getLanguage()
The language of the document (if not specified, the language is
automatically detected).
|
com.google.protobuf.ByteString |
getLanguageBytes()
The language of the document (if not specified, the language is
automatically detected).
|
Document.SourceCase |
getSourceCase() |
Document.Type |
getType()
Required.
|
int |
getTypeValue()
Required.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
Document.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
Document.Builder |
mergeFrom(Document other) |
Document.Builder |
mergeFrom(com.google.protobuf.Message other) |
Document.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
Document.Builder |
setContent(java.lang.String value)
The content of the input in string format.
|
Document.Builder |
setContentBytes(com.google.protobuf.ByteString value)
The content of the input in string format.
|
Document.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) |
Document.Builder |
setGcsContentUri(java.lang.String value)
The Google Cloud Storage URI where the file content is located.
|
Document.Builder |
setGcsContentUriBytes(com.google.protobuf.ByteString value)
The Google Cloud Storage URI where the file content is located.
|
Document.Builder |
setLanguage(java.lang.String value)
The language of the document (if not specified, the language is
automatically detected).
|
Document.Builder |
setLanguageBytes(com.google.protobuf.ByteString value)
The language of the document (if not specified, the language is
automatically detected).
|
Document.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
java.lang.Object value) |
Document.Builder |
setType(Document.Type value)
Required.
|
Document.Builder |
setTypeValue(int value)
Required.
|
Document.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, newBuilderForField, onBuilt, onChanged, parseUnknownFieldfindInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, mergeFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic Document build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic Document buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic Document.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
setField in interface com.google.protobuf.Message.BuildersetField in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)
setRepeatedField in interface com.google.protobuf.Message.BuildersetRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
addRepeatedField in interface com.google.protobuf.Message.BuilderaddRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<Document.Builder>public Document.Builder mergeFrom(Document other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public Document.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<Document.Builder>java.io.IOExceptionpublic Document.SourceCase getSourceCase()
getSourceCase in interface DocumentOrBuilderpublic Document.Builder clearSource()
public int getTypeValue()
Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns an `INVALID_ARGUMENT` error.
.google.cloud.language.v1.Document.Type type = 1;getTypeValue in interface DocumentOrBuilderpublic Document.Builder setTypeValue(int value)
Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns an `INVALID_ARGUMENT` error.
.google.cloud.language.v1.Document.Type type = 1;public Document.Type getType()
Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns an `INVALID_ARGUMENT` error.
.google.cloud.language.v1.Document.Type type = 1;getType in interface DocumentOrBuilderpublic Document.Builder setType(Document.Type value)
Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns an `INVALID_ARGUMENT` error.
.google.cloud.language.v1.Document.Type type = 1;public Document.Builder clearType()
Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns an `INVALID_ARGUMENT` error.
.google.cloud.language.v1.Document.Type type = 1;public java.lang.String getContent()
The content of the input in string format.
string content = 2;getContent in interface DocumentOrBuilderpublic com.google.protobuf.ByteString getContentBytes()
The content of the input in string format.
string content = 2;getContentBytes in interface DocumentOrBuilderpublic Document.Builder setContent(java.lang.String value)
The content of the input in string format.
string content = 2;public Document.Builder clearContent()
The content of the input in string format.
string content = 2;public Document.Builder setContentBytes(com.google.protobuf.ByteString value)
The content of the input in string format.
string content = 2;public java.lang.String getGcsContentUri()
The Google Cloud Storage URI where the file content is located. This URI must be of the form: gs://bucket_name/object_name. For more details, see https://cloud.google.com/storage/docs/reference-uris. NOTE: Cloud Storage object versioning is not supported.
string gcs_content_uri = 3;getGcsContentUri in interface DocumentOrBuilderpublic com.google.protobuf.ByteString getGcsContentUriBytes()
The Google Cloud Storage URI where the file content is located. This URI must be of the form: gs://bucket_name/object_name. For more details, see https://cloud.google.com/storage/docs/reference-uris. NOTE: Cloud Storage object versioning is not supported.
string gcs_content_uri = 3;getGcsContentUriBytes in interface DocumentOrBuilderpublic Document.Builder setGcsContentUri(java.lang.String value)
The Google Cloud Storage URI where the file content is located. This URI must be of the form: gs://bucket_name/object_name. For more details, see https://cloud.google.com/storage/docs/reference-uris. NOTE: Cloud Storage object versioning is not supported.
string gcs_content_uri = 3;public Document.Builder clearGcsContentUri()
The Google Cloud Storage URI where the file content is located. This URI must be of the form: gs://bucket_name/object_name. For more details, see https://cloud.google.com/storage/docs/reference-uris. NOTE: Cloud Storage object versioning is not supported.
string gcs_content_uri = 3;public Document.Builder setGcsContentUriBytes(com.google.protobuf.ByteString value)
The Google Cloud Storage URI where the file content is located. This URI must be of the form: gs://bucket_name/object_name. For more details, see https://cloud.google.com/storage/docs/reference-uris. NOTE: Cloud Storage object versioning is not supported.
string gcs_content_uri = 3;public java.lang.String getLanguage()
The language of the document (if not specified, the language is automatically detected). Both ISO and BCP-47 language codes are accepted.<br> [Language Support](https://cloud.google.com/natural-language/docs/languages) lists currently supported languages for each API method. If the language (either specified by the caller or automatically detected) is not supported by the called API method, an `INVALID_ARGUMENT` error is returned.
string language = 4;getLanguage in interface DocumentOrBuilderpublic com.google.protobuf.ByteString getLanguageBytes()
The language of the document (if not specified, the language is automatically detected). Both ISO and BCP-47 language codes are accepted.<br> [Language Support](https://cloud.google.com/natural-language/docs/languages) lists currently supported languages for each API method. If the language (either specified by the caller or automatically detected) is not supported by the called API method, an `INVALID_ARGUMENT` error is returned.
string language = 4;getLanguageBytes in interface DocumentOrBuilderpublic Document.Builder setLanguage(java.lang.String value)
The language of the document (if not specified, the language is automatically detected). Both ISO and BCP-47 language codes are accepted.<br> [Language Support](https://cloud.google.com/natural-language/docs/languages) lists currently supported languages for each API method. If the language (either specified by the caller or automatically detected) is not supported by the called API method, an `INVALID_ARGUMENT` error is returned.
string language = 4;public Document.Builder clearLanguage()
The language of the document (if not specified, the language is automatically detected). Both ISO and BCP-47 language codes are accepted.<br> [Language Support](https://cloud.google.com/natural-language/docs/languages) lists currently supported languages for each API method. If the language (either specified by the caller or automatically detected) is not supported by the called API method, an `INVALID_ARGUMENT` error is returned.
string language = 4;public Document.Builder setLanguageBytes(com.google.protobuf.ByteString value)
The language of the document (if not specified, the language is automatically detected). Both ISO and BCP-47 language codes are accepted.<br> [Language Support](https://cloud.google.com/natural-language/docs/languages) lists currently supported languages for each API method. If the language (either specified by the caller or automatically detected) is not supported by the called API method, an `INVALID_ARGUMENT` error is returned.
string language = 4;public final Document.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>public final Document.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Document.Builder>