Package com.google.firestore.admin.v1
Class Index
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
com.google.firestore.admin.v1.Index
- All Implemented Interfaces:
IndexOrBuilder,com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Serializable
@Generated
public final class Index
extends com.google.protobuf.GeneratedMessage
implements IndexOrBuilder
Cloud Firestore indexes enable simple and complex queries against documents in a database.Protobuf type
google.firestore.admin.v1.Index- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumAPI Scope defines the APIs (Firestore Native, or Firestore in Datastore Mode) that are supported for queries.static final classCloud Firestore indexes enable simple and complex queries against documents in a database.static enumThe density configuration for the index.static final classA field in an index.static interfacestatic enumQuery Scope defines the scope at which a query is run.static enumThe state of an index.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage
com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT, BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message, T extends Object>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessage
com.google.protobuf.AbstractMessage.BuilderParentNested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessage
alwaysUseFieldBuilders, loggedPre22TypeNames, unknownFieldsFields inherited from class com.google.protobuf.AbstractMessage
memoizedSizeFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleanThe API scope supported by this index.intThe API scope supported by this index.static IndexImmutable.intImmutable.static final com.google.protobuf.Descriptors.DescriptorgetFields(int index) The fields supported by this index.intThe fields supported by this index.The fields supported by this index.getFieldsOrBuilder(int index) The fields supported by this index.List<? extends Index.IndexFieldOrBuilder>The fields supported by this index.booleanOptional.getName()Output only.com.google.protobuf.ByteStringOutput only.com.google.protobuf.Parser<Index>Indexes with a collection query scope specified allow queries against a collection that is the child of a specific document, specified at query time, and that has the same collection ID.intIndexes with a collection query scope specified allow queries against a collection that is the child of a specific document, specified at query time, and that has the same collection ID.intintOptional.getState()Output only.intOutput only.booleanOptional.inthashCode()protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanstatic Index.Builderstatic Index.BuildernewBuilder(Index prototype) protected Index.BuildernewBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent) static IndexparseDelimitedFrom(InputStream input) static IndexparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static IndexparseFrom(byte[] data) static IndexparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static IndexparseFrom(com.google.protobuf.ByteString data) static IndexparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static IndexparseFrom(com.google.protobuf.CodedInputStream input) static IndexparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static IndexparseFrom(InputStream input) static IndexparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static IndexparseFrom(ByteBuffer data) static IndexparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<Index>parser()voidwriteTo(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessage
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagMethods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashFields, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER- See Also:
-
QUERY_SCOPE_FIELD_NUMBER
public static final int QUERY_SCOPE_FIELD_NUMBER- See Also:
-
API_SCOPE_FIELD_NUMBER
public static final int API_SCOPE_FIELD_NUMBER- See Also:
-
FIELDS_FIELD_NUMBER
public static final int FIELDS_FIELD_NUMBER- See Also:
-
STATE_FIELD_NUMBER
public static final int STATE_FIELD_NUMBER- See Also:
-
DENSITY_FIELD_NUMBER
public static final int DENSITY_FIELD_NUMBER- See Also:
-
MULTIKEY_FIELD_NUMBER
public static final int MULTIKEY_FIELD_NUMBER- See Also:
-
SHARD_COUNT_FIELD_NUMBER
public static final int SHARD_COUNT_FIELD_NUMBER- See Also:
-
UNIQUE_FIELD_NUMBER
public static final int UNIQUE_FIELD_NUMBER- See Also:
-
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage
-
getName
Output only. A server defined name for this index. The form of this name for composite indexes will be: `projects/{project_id}/databases/{database_id}/collectionGroups/{collection_id}/indexes/{composite_index_id}` For single field indexes, this field will be empty.string name = 1;- Specified by:
getNamein interfaceIndexOrBuilder- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()Output only. A server defined name for this index. The form of this name for composite indexes will be: `projects/{project_id}/databases/{database_id}/collectionGroups/{collection_id}/indexes/{composite_index_id}` For single field indexes, this field will be empty.string name = 1;- Specified by:
getNameBytesin interfaceIndexOrBuilder- Returns:
- The bytes for name.
-
getQueryScopeValue
public int getQueryScopeValue()Indexes with a collection query scope specified allow queries against a collection that is the child of a specific document, specified at query time, and that has the same collection ID. Indexes with a collection group query scope specified allow queries against all collections descended from a specific document, specified at query time, and that have the same collection ID as this index.
.google.firestore.admin.v1.Index.QueryScope query_scope = 2;- Specified by:
getQueryScopeValuein interfaceIndexOrBuilder- Returns:
- The enum numeric value on the wire for queryScope.
-
getQueryScope
Indexes with a collection query scope specified allow queries against a collection that is the child of a specific document, specified at query time, and that has the same collection ID. Indexes with a collection group query scope specified allow queries against all collections descended from a specific document, specified at query time, and that have the same collection ID as this index.
.google.firestore.admin.v1.Index.QueryScope query_scope = 2;- Specified by:
getQueryScopein interfaceIndexOrBuilder- Returns:
- The queryScope.
-
getApiScopeValue
public int getApiScopeValue()The API scope supported by this index.
.google.firestore.admin.v1.Index.ApiScope api_scope = 5;- Specified by:
getApiScopeValuein interfaceIndexOrBuilder- Returns:
- The enum numeric value on the wire for apiScope.
-
getApiScope
The API scope supported by this index.
.google.firestore.admin.v1.Index.ApiScope api_scope = 5;- Specified by:
getApiScopein interfaceIndexOrBuilder- Returns:
- The apiScope.
-
getFieldsList
The fields supported by this index. For composite indexes, this requires a minimum of 2 and a maximum of 100 fields. The last field entry is always for the field path `__name__`. If, on creation, `__name__` was not specified as the last field, it will be added automatically with the same direction as that of the last field defined. If the final field in a composite index is not directional, the `__name__` will be ordered ASCENDING (unless explicitly specified). For single field indexes, this will always be exactly one entry with a field path equal to the field path of the associated field.
repeated .google.firestore.admin.v1.Index.IndexField fields = 3;- Specified by:
getFieldsListin interfaceIndexOrBuilder
-
getFieldsOrBuilderList
The fields supported by this index. For composite indexes, this requires a minimum of 2 and a maximum of 100 fields. The last field entry is always for the field path `__name__`. If, on creation, `__name__` was not specified as the last field, it will be added automatically with the same direction as that of the last field defined. If the final field in a composite index is not directional, the `__name__` will be ordered ASCENDING (unless explicitly specified). For single field indexes, this will always be exactly one entry with a field path equal to the field path of the associated field.
repeated .google.firestore.admin.v1.Index.IndexField fields = 3;- Specified by:
getFieldsOrBuilderListin interfaceIndexOrBuilder
-
getFieldsCount
public int getFieldsCount()The fields supported by this index. For composite indexes, this requires a minimum of 2 and a maximum of 100 fields. The last field entry is always for the field path `__name__`. If, on creation, `__name__` was not specified as the last field, it will be added automatically with the same direction as that of the last field defined. If the final field in a composite index is not directional, the `__name__` will be ordered ASCENDING (unless explicitly specified). For single field indexes, this will always be exactly one entry with a field path equal to the field path of the associated field.
repeated .google.firestore.admin.v1.Index.IndexField fields = 3;- Specified by:
getFieldsCountin interfaceIndexOrBuilder
-
getFields
The fields supported by this index. For composite indexes, this requires a minimum of 2 and a maximum of 100 fields. The last field entry is always for the field path `__name__`. If, on creation, `__name__` was not specified as the last field, it will be added automatically with the same direction as that of the last field defined. If the final field in a composite index is not directional, the `__name__` will be ordered ASCENDING (unless explicitly specified). For single field indexes, this will always be exactly one entry with a field path equal to the field path of the associated field.
repeated .google.firestore.admin.v1.Index.IndexField fields = 3;- Specified by:
getFieldsin interfaceIndexOrBuilder
-
getFieldsOrBuilder
The fields supported by this index. For composite indexes, this requires a minimum of 2 and a maximum of 100 fields. The last field entry is always for the field path `__name__`. If, on creation, `__name__` was not specified as the last field, it will be added automatically with the same direction as that of the last field defined. If the final field in a composite index is not directional, the `__name__` will be ordered ASCENDING (unless explicitly specified). For single field indexes, this will always be exactly one entry with a field path equal to the field path of the associated field.
repeated .google.firestore.admin.v1.Index.IndexField fields = 3;- Specified by:
getFieldsOrBuilderin interfaceIndexOrBuilder
-
getStateValue
public int getStateValue()Output only. The serving state of the index.
.google.firestore.admin.v1.Index.State state = 4;- Specified by:
getStateValuein interfaceIndexOrBuilder- Returns:
- The enum numeric value on the wire for state.
-
getState
Output only. The serving state of the index.
.google.firestore.admin.v1.Index.State state = 4;- Specified by:
getStatein interfaceIndexOrBuilder- Returns:
- The state.
-
getDensityValue
public int getDensityValue()Immutable. The density configuration of the index.
.google.firestore.admin.v1.Index.Density density = 6 [(.google.api.field_behavior) = IMMUTABLE];- Specified by:
getDensityValuein interfaceIndexOrBuilder- Returns:
- The enum numeric value on the wire for density.
-
getDensity
Immutable. The density configuration of the index.
.google.firestore.admin.v1.Index.Density density = 6 [(.google.api.field_behavior) = IMMUTABLE];- Specified by:
getDensityin interfaceIndexOrBuilder- Returns:
- The density.
-
getMultikey
public boolean getMultikey()Optional. Whether the index is multikey. By default, the index is not multikey. For non-multikey indexes, none of the paths in the index definition reach or traverse an array, except via an explicit array index. For multikey indexes, at most one of the paths in the index definition reach or traverse an array, except via an explicit array index. Violations will result in errors. Note this field only applies to index with MONGODB_COMPATIBLE_API ApiScope.
bool multikey = 7 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getMultikeyin interfaceIndexOrBuilder- Returns:
- The multikey.
-
getShardCount
public int getShardCount()Optional. The number of shards for the index.
int32 shard_count = 8 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getShardCountin interfaceIndexOrBuilder- Returns:
- The shardCount.
-
getUnique
public boolean getUnique()Optional. Whether it is an unique index. Unique index ensures all values for the indexed field(s) are unique across documents.
bool unique = 10 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getUniquein interfaceIndexOrBuilder- Returns:
- The unique.
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage
-
writeTo
- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessage- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessage
-
equals
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.google.protobuf.AbstractMessage
-
parseFrom
public static Index parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Index parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Index parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Index parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Index parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Index parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static Index parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static Index parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static Index parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
- Overrides:
newBuilderForTypein classcom.google.protobuf.AbstractMessage
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessage
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-