Class BatchGetDocumentsRequest.Builder (0.1.0)

public static final class BatchGetDocumentsRequest.Builder extends GeneratedMessage.Builder<BatchGetDocumentsRequest.Builder> implements BatchGetDocumentsRequestOrBuilder

Request message for DeveloperKnowledge.BatchGetDocuments.

Protobuf type google.developers.knowledge.v1.BatchGetDocumentsRequest

Static Methods

getDescriptor()

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

Methods

addAllNames(Iterable<String> values)

public BatchGetDocumentsRequest.Builder addAllNames(Iterable<String> values)

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
values Iterable<String>

The names to add.

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

addNames(String value)

public BatchGetDocumentsRequest.Builder addNames(String value)

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The names to add.

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

addNamesBytes(ByteString value)

public BatchGetDocumentsRequest.Builder addNamesBytes(ByteString value)

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes of the names to add.

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

build()

public BatchGetDocumentsRequest build()
Returns
Type Description
BatchGetDocumentsRequest

buildPartial()

public BatchGetDocumentsRequest buildPartial()
Returns
Type Description
BatchGetDocumentsRequest

clear()

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

clearNames()

public BatchGetDocumentsRequest.Builder clearNames()

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

clearView()

public BatchGetDocumentsRequest.Builder clearView()

Optional. Specifies the DocumentView of the document. If unspecified, DeveloperKnowledge.BatchGetDocuments defaults to DOCUMENT_VIEW_CONTENT.

.google.developers.knowledge.v1.DocumentView view = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

getDefaultInstanceForType()

public BatchGetDocumentsRequest getDefaultInstanceForType()
Returns
Type Description
BatchGetDocumentsRequest

getDescriptorForType()

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

getNames(int index)

public String getNames(int index)

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The names at the given index.

getNamesBytes(int index)

public ByteString getNamesBytes(int index)

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the names at the given index.

getNamesCount()

public int getNamesCount()

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
int

The count of names.

getNamesList()

public ProtocolStringList getNamesList()

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ProtocolStringList

A list containing the names.

getView()

public DocumentView getView()

Optional. Specifies the DocumentView of the document. If unspecified, DeveloperKnowledge.BatchGetDocuments defaults to DOCUMENT_VIEW_CONTENT.

.google.developers.knowledge.v1.DocumentView view = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
DocumentView

The view.

getViewValue()

public int getViewValue()

Optional. Specifies the DocumentView of the document. If unspecified, DeveloperKnowledge.BatchGetDocuments defaults to DOCUMENT_VIEW_CONTENT.

.google.developers.knowledge.v1.DocumentView view = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The enum numeric value on the wire for view.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(BatchGetDocumentsRequest other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setNames(int index, String value)

public BatchGetDocumentsRequest.Builder setNames(int index, String value)

Required. Specifies the names of the documents to retrieve. A maximum of 20 documents can be retrieved in a batch. The documents are returned in the same order as the names in the request.

Format: documents/{uri_without_scheme} Example: documents/docs.cloud.google.com/storage/docs/creating-buckets

repeated string names = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameters
Name Description
index int

The index to set the value at.

value String

The names to set.

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

setView(DocumentView value)

public BatchGetDocumentsRequest.Builder setView(DocumentView value)

Optional. Specifies the DocumentView of the document. If unspecified, DeveloperKnowledge.BatchGetDocuments defaults to DOCUMENT_VIEW_CONTENT.

.google.developers.knowledge.v1.DocumentView view = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value DocumentView

The view to set.

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.

setViewValue(int value)

public BatchGetDocumentsRequest.Builder setViewValue(int value)

Optional. Specifies the DocumentView of the document. If unspecified, DeveloperKnowledge.BatchGetDocuments defaults to DOCUMENT_VIEW_CONTENT.

.google.developers.knowledge.v1.DocumentView view = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The enum numeric value on the wire for view to set.

Returns
Type Description
BatchGetDocumentsRequest.Builder

This builder for chaining.