Class Target.DocumentsTarget.Builder (3.36.0)

public static final class Target.DocumentsTarget.Builder extends GeneratedMessage.Builder<Target.DocumentsTarget.Builder> implements Target.DocumentsTargetOrBuilder

A target specified by a set of documents names.

Protobuf type google.firestore.v1.Target.DocumentsTarget

Static Methods

getDescriptor()

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

Methods

addAllDocuments(Iterable<String> values)

public Target.DocumentsTarget.Builder addAllDocuments(Iterable<String> values)

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Parameter
Name Description
values Iterable<String>

The documents to add.

Returns
Type Description
Target.DocumentsTarget.Builder

This builder for chaining.

addDocuments(String value)

public Target.DocumentsTarget.Builder addDocuments(String value)

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Parameter
Name Description
value String

The documents to add.

Returns
Type Description
Target.DocumentsTarget.Builder

This builder for chaining.

addDocumentsBytes(ByteString value)

public Target.DocumentsTarget.Builder addDocumentsBytes(ByteString value)

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Parameter
Name Description
value ByteString

The bytes of the documents to add.

Returns
Type Description
Target.DocumentsTarget.Builder

This builder for chaining.

build()

public Target.DocumentsTarget build()
Returns
Type Description
Target.DocumentsTarget

buildPartial()

public Target.DocumentsTarget buildPartial()
Returns
Type Description
Target.DocumentsTarget

clear()

public Target.DocumentsTarget.Builder clear()
Returns
Type Description
Target.DocumentsTarget.Builder
Overrides

clearDocuments()

public Target.DocumentsTarget.Builder clearDocuments()

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Returns
Type Description
Target.DocumentsTarget.Builder

This builder for chaining.

getDefaultInstanceForType()

public Target.DocumentsTarget getDefaultInstanceForType()
Returns
Type Description
Target.DocumentsTarget

getDescriptorForType()

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

getDocuments(int index)

public String getDocuments(int index)

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The documents at the given index.

getDocumentsBytes(int index)

public ByteString getDocumentsBytes(int index)

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the documents at the given index.

getDocumentsCount()

public int getDocumentsCount()

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Returns
Type Description
int

The count of documents.

getDocumentsList()

public ProtocolStringList getDocumentsList()

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Returns
Type Description
ProtocolStringList

A list containing the documents.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(Target.DocumentsTarget other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setDocuments(int index, String value)

public Target.DocumentsTarget.Builder setDocuments(int index, String value)

The names of the documents to retrieve. In the format: projects/{project_id}/databases/{database_id}/documents/{document_path}. The request will fail if any of the document is not a child resource of the given database. Duplicate names will be elided.

repeated string documents = 2;

Parameters
Name Description
index int

The index to set the value at.

value String

The documents to set.

Returns
Type Description
Target.DocumentsTarget.Builder

This builder for chaining.