public static final class Key.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder> implements KeyOrBuilder
A unique identifier for an entity. If a key's partition ID or any of its path kinds or names are reserved/read-only, the key is reserved/read-only. A reserved/read-only key is forbidden in certain documented contexts.Protobuf type
google.datastore.v1.Key
Modifier and Type | Method and Description |
---|---|
Key.Builder |
addAllPath(Iterable<? extends Key.PathElement> values)
The entity path.
|
Key.Builder |
addPath(int index,
Key.PathElement.Builder builderForValue)
The entity path.
|
Key.Builder |
addPath(int index,
Key.PathElement value)
The entity path.
|
Key.Builder |
addPath(Key.PathElement.Builder builderForValue)
The entity path.
|
Key.Builder |
addPath(Key.PathElement value)
The entity path.
|
Key.PathElement.Builder |
addPathBuilder()
The entity path.
|
Key.PathElement.Builder |
addPathBuilder(int index)
The entity path.
|
Key.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
Key |
build() |
Key |
buildPartial() |
Key.Builder |
clear() |
Key.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
Key.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
Key.Builder |
clearPartitionId()
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
Key.Builder |
clearPath()
The entity path.
|
Key.Builder |
clone() |
Key |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
PartitionId |
getPartitionId()
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
PartitionId.Builder |
getPartitionIdBuilder()
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
PartitionIdOrBuilder |
getPartitionIdOrBuilder()
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
Key.PathElement |
getPath(int index)
The entity path.
|
Key.PathElement.Builder |
getPathBuilder(int index)
The entity path.
|
List<Key.PathElement.Builder> |
getPathBuilderList()
The entity path.
|
int |
getPathCount()
The entity path.
|
List<Key.PathElement> |
getPathList()
The entity path.
|
Key.PathElementOrBuilder |
getPathOrBuilder(int index)
The entity path.
|
List<? extends Key.PathElementOrBuilder> |
getPathOrBuilderList()
The entity path.
|
boolean |
hasPartitionId()
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
Key.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
Key.Builder |
mergeFrom(Key other) |
Key.Builder |
mergeFrom(com.google.protobuf.Message other) |
Key.Builder |
mergePartitionId(PartitionId value)
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
Key.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
Key.Builder |
removePath(int index)
The entity path.
|
Key.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
Key.Builder |
setPartitionId(PartitionId.Builder builderForValue)
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
Key.Builder |
setPartitionId(PartitionId value)
Entities are partitioned into subsets, currently identified by a project
ID and namespace ID.
|
Key.Builder |
setPath(int index,
Key.PathElement.Builder builderForValue)
The entity path.
|
Key.Builder |
setPath(int index,
Key.PathElement value)
The entity path.
|
Key.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
Key.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder clear()
clear
in interface com.google.protobuf.Message.Builder
clear
in interface com.google.protobuf.MessageLite.Builder
clear
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType
in interface com.google.protobuf.Message.Builder
getDescriptorForType
in interface com.google.protobuf.MessageOrBuilder
getDescriptorForType
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key getDefaultInstanceForType()
getDefaultInstanceForType
in interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType
in interface com.google.protobuf.MessageOrBuilder
public Key build()
build
in interface com.google.protobuf.Message.Builder
build
in interface com.google.protobuf.MessageLite.Builder
public Key buildPartial()
buildPartial
in interface com.google.protobuf.Message.Builder
buildPartial
in interface com.google.protobuf.MessageLite.Builder
public Key.Builder clone()
clone
in interface com.google.protobuf.Message.Builder
clone
in interface com.google.protobuf.MessageLite.Builder
clone
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField
in interface com.google.protobuf.Message.Builder
setField
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField
in interface com.google.protobuf.Message.Builder
clearField
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof
in interface com.google.protobuf.Message.Builder
clearOneof
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField
in interface com.google.protobuf.Message.Builder
setRepeatedField
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField
in interface com.google.protobuf.Message.Builder
addRepeatedField
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom
in interface com.google.protobuf.Message.Builder
mergeFrom
in class com.google.protobuf.AbstractMessage.Builder<Key.Builder>
public Key.Builder mergeFrom(Key other)
public final boolean isInitialized()
isInitialized
in interface com.google.protobuf.MessageLiteOrBuilder
isInitialized
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public Key.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom
in interface com.google.protobuf.Message.Builder
mergeFrom
in interface com.google.protobuf.MessageLite.Builder
mergeFrom
in class com.google.protobuf.AbstractMessage.Builder<Key.Builder>
IOException
public boolean hasPartitionId()
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
hasPartitionId
in interface KeyOrBuilder
public PartitionId getPartitionId()
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
getPartitionId
in interface KeyOrBuilder
public Key.Builder setPartitionId(PartitionId value)
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
public Key.Builder setPartitionId(PartitionId.Builder builderForValue)
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
public Key.Builder mergePartitionId(PartitionId value)
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
public Key.Builder clearPartitionId()
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
public PartitionId.Builder getPartitionIdBuilder()
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
public PartitionIdOrBuilder getPartitionIdOrBuilder()
Entities are partitioned into subsets, currently identified by a project ID and namespace ID. Queries are scoped to a single partition.
.google.datastore.v1.PartitionId partition_id = 1;
getPartitionIdOrBuilder
in interface KeyOrBuilder
public List<Key.PathElement> getPathList()
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
getPathList
in interface KeyOrBuilder
public int getPathCount()
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
getPathCount
in interface KeyOrBuilder
public Key.PathElement getPath(int index)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
getPath
in interface KeyOrBuilder
public Key.Builder setPath(int index, Key.PathElement value)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder setPath(int index, Key.PathElement.Builder builderForValue)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder addPath(Key.PathElement value)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder addPath(int index, Key.PathElement value)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder addPath(Key.PathElement.Builder builderForValue)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder addPath(int index, Key.PathElement.Builder builderForValue)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder addAllPath(Iterable<? extends Key.PathElement> values)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder clearPath()
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.Builder removePath(int index)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.PathElement.Builder getPathBuilder(int index)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.PathElementOrBuilder getPathOrBuilder(int index)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
getPathOrBuilder
in interface KeyOrBuilder
public List<? extends Key.PathElementOrBuilder> getPathOrBuilderList()
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
getPathOrBuilderList
in interface KeyOrBuilder
public Key.PathElement.Builder addPathBuilder()
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public Key.PathElement.Builder addPathBuilder(int index)
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public List<Key.PathElement.Builder> getPathBuilderList()
The entity path. An entity path consists of one or more elements composed of a kind and a string or numerical identifier, which identify entities. The first element identifies a _root entity_, the second element identifies a _child_ of the root entity, the third element identifies a child of the second entity, and so forth. The entities identified by all prefixes of the path are called the element's _ancestors_. An entity path is always fully complete: *all* of the entity's ancestors are required to be in the path along with the entity identifier itself. The only exception is that in some documented cases, the identifier in the last path element (for the entity) itself may be omitted. For example, the last path element of the key of `Mutation.insert` may have no identifier. A path can never be empty, and a path can have at most 100 elements.
repeated .google.datastore.v1.Key.PathElement path = 2;
public final Key.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields
in interface com.google.protobuf.Message.Builder
setUnknownFields
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
public final Key.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields
in interface com.google.protobuf.Message.Builder
mergeUnknownFields
in class com.google.protobuf.GeneratedMessageV3.Builder<Key.Builder>
Copyright © 2023 Google LLC. All rights reserved.