public static final class Document.Builder extends GeneratedMessageV3.Builder<Document.Builder> implements DocumentOrBuilder
A Firestore document. Must not exceed 1 MiB - 4 bytes.Protobuf type
google.firestore.v1beta1.Document
Modifier and Type | Method and Description |
---|---|
Document.Builder |
addRepeatedField(Descriptors.FieldDescriptor field,
java.lang.Object value) |
Document |
build() |
Document |
buildPartial() |
Document.Builder |
clear() |
Document.Builder |
clearCreateTime()
Output only.
|
Document.Builder |
clearField(Descriptors.FieldDescriptor field) |
Document.Builder |
clearFields() |
Document.Builder |
clearName()
The resource name of the document, for example
`projects/{project_id}/databases/{database_id}/documents/{document_path}`.
|
Document.Builder |
clearOneof(Descriptors.OneofDescriptor oneof) |
Document.Builder |
clearUpdateTime()
Output only.
|
Document.Builder |
clone() |
boolean |
containsFields(java.lang.String key)
The document's fields.
|
Timestamp |
getCreateTime()
Output only.
|
Timestamp.Builder |
getCreateTimeBuilder()
Output only.
|
TimestampOrBuilder |
getCreateTimeOrBuilder()
Output only.
|
Document |
getDefaultInstanceForType() |
static Descriptors.Descriptor |
getDescriptor() |
Descriptors.Descriptor |
getDescriptorForType() |
java.util.Map<java.lang.String,Value> |
getFields()
Deprecated.
|
int |
getFieldsCount()
The document's fields.
|
java.util.Map<java.lang.String,Value> |
getFieldsMap()
The document's fields.
|
Value |
getFieldsOrDefault(java.lang.String key,
Value defaultValue)
The document's fields.
|
Value |
getFieldsOrThrow(java.lang.String key)
The document's fields.
|
java.util.Map<java.lang.String,Value> |
getMutableFields()
Deprecated.
|
java.lang.String |
getName()
The resource name of the document, for example
`projects/{project_id}/databases/{database_id}/documents/{document_path}`.
|
ByteString |
getNameBytes()
The resource name of the document, for example
`projects/{project_id}/databases/{database_id}/documents/{document_path}`.
|
Timestamp |
getUpdateTime()
Output only.
|
Timestamp.Builder |
getUpdateTimeBuilder()
Output only.
|
TimestampOrBuilder |
getUpdateTimeOrBuilder()
Output only.
|
boolean |
hasCreateTime()
Output only.
|
boolean |
hasUpdateTime()
Output only.
|
protected GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
protected MapField |
internalGetMapField(int number) |
protected MapField |
internalGetMutableMapField(int number) |
boolean |
isInitialized() |
Document.Builder |
mergeCreateTime(Timestamp value)
Output only.
|
Document.Builder |
mergeFrom(CodedInputStream input,
ExtensionRegistryLite extensionRegistry) |
Document.Builder |
mergeFrom(Document other) |
Document.Builder |
mergeFrom(Message other) |
Document.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields) |
Document.Builder |
mergeUpdateTime(Timestamp value)
Output only.
|
Document.Builder |
putAllFields(java.util.Map<java.lang.String,Value> values)
The document's fields.
|
Document.Builder |
putFields(java.lang.String key,
Value value)
The document's fields.
|
Document.Builder |
removeFields(java.lang.String key)
The document's fields.
|
Document.Builder |
setCreateTime(Timestamp.Builder builderForValue)
Output only.
|
Document.Builder |
setCreateTime(Timestamp value)
Output only.
|
Document.Builder |
setField(Descriptors.FieldDescriptor field,
java.lang.Object value) |
Document.Builder |
setName(java.lang.String value)
The resource name of the document, for example
`projects/{project_id}/databases/{database_id}/documents/{document_path}`.
|
Document.Builder |
setNameBytes(ByteString value)
The resource name of the document, for example
`projects/{project_id}/databases/{database_id}/documents/{document_path}`.
|
Document.Builder |
setRepeatedField(Descriptors.FieldDescriptor field,
int index,
java.lang.Object value) |
Document.Builder |
setUnknownFields(UnknownFieldSet unknownFields) |
Document.Builder |
setUpdateTime(Timestamp.Builder builderForValue)
Output only.
|
Document.Builder |
setUpdateTime(Timestamp value)
Output only.
|
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, isClean, markClean, newBuilderForField, onBuilt, onChanged, setUnknownFieldsProto3
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
addAll, addAll, mergeFrom, newUninitializedMessageException
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
mergeFrom
public static final Descriptors.Descriptor getDescriptor()
protected MapField internalGetMapField(int number)
internalGetMapField
in class GeneratedMessageV3.Builder<Document.Builder>
protected MapField internalGetMutableMapField(int number)
internalGetMutableMapField
in class GeneratedMessageV3.Builder<Document.Builder>
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder clear()
clear
in interface Message.Builder
clear
in interface MessageLite.Builder
clear
in class GeneratedMessageV3.Builder<Document.Builder>
public Descriptors.Descriptor getDescriptorForType()
getDescriptorForType
in interface Message.Builder
getDescriptorForType
in interface MessageOrBuilder
getDescriptorForType
in class GeneratedMessageV3.Builder<Document.Builder>
public Document getDefaultInstanceForType()
getDefaultInstanceForType
in interface MessageLiteOrBuilder
getDefaultInstanceForType
in interface MessageOrBuilder
public Document build()
build
in interface Message.Builder
build
in interface MessageLite.Builder
public Document buildPartial()
buildPartial
in interface Message.Builder
buildPartial
in interface MessageLite.Builder
public Document.Builder clone()
clone
in interface Message.Builder
clone
in interface MessageLite.Builder
clone
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder setField(Descriptors.FieldDescriptor field, java.lang.Object value)
setField
in interface Message.Builder
setField
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder clearField(Descriptors.FieldDescriptor field)
clearField
in interface Message.Builder
clearField
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder clearOneof(Descriptors.OneofDescriptor oneof)
clearOneof
in interface Message.Builder
clearOneof
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, java.lang.Object value)
setRepeatedField
in interface Message.Builder
setRepeatedField
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder addRepeatedField(Descriptors.FieldDescriptor field, java.lang.Object value)
addRepeatedField
in interface Message.Builder
addRepeatedField
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder mergeFrom(Message other)
mergeFrom
in interface Message.Builder
mergeFrom
in class AbstractMessage.Builder<Document.Builder>
public Document.Builder mergeFrom(Document other)
public final boolean isInitialized()
isInitialized
in interface MessageLiteOrBuilder
isInitialized
in class GeneratedMessageV3.Builder<Document.Builder>
public Document.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
mergeFrom
in interface Message.Builder
mergeFrom
in interface MessageLite.Builder
mergeFrom
in class AbstractMessage.Builder<Document.Builder>
java.io.IOException
public java.lang.String getName()
The resource name of the document, for example `projects/{project_id}/databases/{database_id}/documents/{document_path}`.
string name = 1;
getName
in interface DocumentOrBuilder
public ByteString getNameBytes()
The resource name of the document, for example `projects/{project_id}/databases/{database_id}/documents/{document_path}`.
string name = 1;
getNameBytes
in interface DocumentOrBuilder
public Document.Builder setName(java.lang.String value)
The resource name of the document, for example `projects/{project_id}/databases/{database_id}/documents/{document_path}`.
string name = 1;
public Document.Builder clearName()
The resource name of the document, for example `projects/{project_id}/databases/{database_id}/documents/{document_path}`.
string name = 1;
public Document.Builder setNameBytes(ByteString value)
The resource name of the document, for example `projects/{project_id}/databases/{database_id}/documents/{document_path}`.
string name = 1;
public int getFieldsCount()
DocumentOrBuilder
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
getFieldsCount
in interface DocumentOrBuilder
public boolean containsFields(java.lang.String key)
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
containsFields
in interface DocumentOrBuilder
@Deprecated public java.util.Map<java.lang.String,Value> getFields()
getFieldsMap()
instead.getFields
in interface DocumentOrBuilder
public java.util.Map<java.lang.String,Value> getFieldsMap()
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
getFieldsMap
in interface DocumentOrBuilder
public Value getFieldsOrDefault(java.lang.String key, Value defaultValue)
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
getFieldsOrDefault
in interface DocumentOrBuilder
public Value getFieldsOrThrow(java.lang.String key)
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
getFieldsOrThrow
in interface DocumentOrBuilder
public Document.Builder clearFields()
public Document.Builder removeFields(java.lang.String key)
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
@Deprecated public java.util.Map<java.lang.String,Value> getMutableFields()
public Document.Builder putFields(java.lang.String key, Value value)
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
public Document.Builder putAllFields(java.util.Map<java.lang.String,Value> values)
The document's fields. The map keys represent field names. A simple field name contains only characters `a` to `z`, `A` to `Z`, `0` to `9`, or `_`, and must not start with `0` to `9` or `_`. For example, `foo_bar_17`. Field names matching the regular expression `__.*__` are reserved. Reserved field names are forbidden except in certain documented contexts. The map keys, represented as UTF-8, must not exceed 1,500 bytes and cannot be empty. Field paths may be used in other contexts to refer to structured fields defined here. For `map_value`, the field path is represented by the simple or quoted field names of the containing fields, delimited by `.`. For example, the structured field `"foo" : { map_value: { "x&y" : { string_value: "hello" }}}` would be represented by the field path `foo.x&y`. Within a field path, a quoted field name starts and ends with `` ` `` and may contain any character. Some characters, including `` ` ``, must be escaped using a `\`. For example, `` `x&y` `` represents `x&y` and `` `bak\`tik` `` represents `` bak`tik ``.
map<string, .google.firestore.v1beta1.Value> fields = 2;
public boolean hasCreateTime()
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
hasCreateTime
in interface DocumentOrBuilder
public Timestamp getCreateTime()
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
getCreateTime
in interface DocumentOrBuilder
public Document.Builder setCreateTime(Timestamp value)
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
public Document.Builder setCreateTime(Timestamp.Builder builderForValue)
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
public Document.Builder mergeCreateTime(Timestamp value)
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
public Document.Builder clearCreateTime()
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
public Timestamp.Builder getCreateTimeBuilder()
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
public TimestampOrBuilder getCreateTimeOrBuilder()
Output only. The time at which the document was created. This value increases monotonically when a document is deleted then recreated. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp create_time = 3;
getCreateTimeOrBuilder
in interface DocumentOrBuilder
public boolean hasUpdateTime()
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
hasUpdateTime
in interface DocumentOrBuilder
public Timestamp getUpdateTime()
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
getUpdateTime
in interface DocumentOrBuilder
public Document.Builder setUpdateTime(Timestamp value)
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
public Document.Builder setUpdateTime(Timestamp.Builder builderForValue)
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
public Document.Builder mergeUpdateTime(Timestamp value)
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
public Document.Builder clearUpdateTime()
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
public Timestamp.Builder getUpdateTimeBuilder()
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
public TimestampOrBuilder getUpdateTimeOrBuilder()
Output only. The time at which the document was last changed. This value is initally set to the `create_time` then increases monotonically with each change to the document. It can also be compared to values from other documents and the `read_time` of a query.
.google.protobuf.Timestamp update_time = 4;
getUpdateTimeOrBuilder
in interface DocumentOrBuilder
public final Document.Builder setUnknownFields(UnknownFieldSet unknownFields)
setUnknownFields
in interface Message.Builder
setUnknownFields
in class GeneratedMessageV3.Builder<Document.Builder>
public final Document.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
mergeUnknownFields
in interface Message.Builder
mergeUnknownFields
in class GeneratedMessageV3.Builder<Document.Builder>