Class StructuredQuery.Builder (3.7.2)

public static final class StructuredQuery.Builder extends GeneratedMessageV3.Builder<StructuredQuery.Builder> implements StructuredQueryOrBuilder

A Firestore query.

Protobuf type google.firestore.v1.StructuredQuery

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllFrom(Iterable<? extends StructuredQuery.CollectionSelector> values)

public StructuredQuery.Builder addAllFrom(Iterable<? extends StructuredQuery.CollectionSelector> values)

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Parameter
NameDescription
valuesIterable<? extends com.google.firestore.v1.StructuredQuery.CollectionSelector>
Returns
TypeDescription
StructuredQuery.Builder

addAllOrderBy(Iterable<? extends StructuredQuery.Order> values)

public StructuredQuery.Builder addAllOrderBy(Iterable<? extends StructuredQuery.Order> values)

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Parameter
NameDescription
valuesIterable<? extends com.google.firestore.v1.StructuredQuery.Order>
Returns
TypeDescription
StructuredQuery.Builder

addFrom(StructuredQuery.CollectionSelector value)

public StructuredQuery.Builder addFrom(StructuredQuery.CollectionSelector value)

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Parameter
NameDescription
valueStructuredQuery.CollectionSelector
Returns
TypeDescription
StructuredQuery.Builder

addFrom(StructuredQuery.CollectionSelector.Builder builderForValue)

public StructuredQuery.Builder addFrom(StructuredQuery.CollectionSelector.Builder builderForValue)

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Parameter
NameDescription
builderForValueStructuredQuery.CollectionSelector.Builder
Returns
TypeDescription
StructuredQuery.Builder

addFrom(int index, StructuredQuery.CollectionSelector value)

public StructuredQuery.Builder addFrom(int index, StructuredQuery.CollectionSelector value)

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Parameters
NameDescription
indexint
valueStructuredQuery.CollectionSelector
Returns
TypeDescription
StructuredQuery.Builder

addFrom(int index, StructuredQuery.CollectionSelector.Builder builderForValue)

public StructuredQuery.Builder addFrom(int index, StructuredQuery.CollectionSelector.Builder builderForValue)

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Parameters
NameDescription
indexint
builderForValueStructuredQuery.CollectionSelector.Builder
Returns
TypeDescription
StructuredQuery.Builder

addFromBuilder()

public StructuredQuery.CollectionSelector.Builder addFromBuilder()

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Returns
TypeDescription
StructuredQuery.CollectionSelector.Builder

addFromBuilder(int index)

public StructuredQuery.CollectionSelector.Builder addFromBuilder(int index)

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Parameter
NameDescription
indexint
Returns
TypeDescription
StructuredQuery.CollectionSelector.Builder

addOrderBy(StructuredQuery.Order value)

public StructuredQuery.Builder addOrderBy(StructuredQuery.Order value)

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Parameter
NameDescription
valueStructuredQuery.Order
Returns
TypeDescription
StructuredQuery.Builder

addOrderBy(StructuredQuery.Order.Builder builderForValue)

public StructuredQuery.Builder addOrderBy(StructuredQuery.Order.Builder builderForValue)

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Parameter
NameDescription
builderForValueStructuredQuery.Order.Builder
Returns
TypeDescription
StructuredQuery.Builder

addOrderBy(int index, StructuredQuery.Order value)

public StructuredQuery.Builder addOrderBy(int index, StructuredQuery.Order value)

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Parameters
NameDescription
indexint
valueStructuredQuery.Order
Returns
TypeDescription
StructuredQuery.Builder

addOrderBy(int index, StructuredQuery.Order.Builder builderForValue)

public StructuredQuery.Builder addOrderBy(int index, StructuredQuery.Order.Builder builderForValue)

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Parameters
NameDescription
indexint
builderForValueStructuredQuery.Order.Builder
Returns
TypeDescription
StructuredQuery.Builder

addOrderByBuilder()

public StructuredQuery.Order.Builder addOrderByBuilder()

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Returns
TypeDescription
StructuredQuery.Order.Builder

addOrderByBuilder(int index)

public StructuredQuery.Order.Builder addOrderByBuilder(int index)

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Parameter
NameDescription
indexint
Returns
TypeDescription
StructuredQuery.Order.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public StructuredQuery.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
StructuredQuery.Builder
Overrides

build()

public StructuredQuery build()
Returns
TypeDescription
StructuredQuery

buildPartial()

public StructuredQuery buildPartial()
Returns
TypeDescription
StructuredQuery

clear()

public StructuredQuery.Builder clear()
Returns
TypeDescription
StructuredQuery.Builder
Overrides

clearEndAt()

public StructuredQuery.Builder clearEndAt()

A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

  • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

.google.firestore.v1.Cursor end_at = 8;

Returns
TypeDescription
StructuredQuery.Builder

clearField(Descriptors.FieldDescriptor field)

public StructuredQuery.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
StructuredQuery.Builder
Overrides

clearFrom()

public StructuredQuery.Builder clearFrom()

The collections to query.

repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

Returns
TypeDescription
StructuredQuery.Builder

clearLimit()

public StructuredQuery.Builder clearLimit()

The maximum number of results to return. Applies after all other constraints. Requires:

  • The value must be greater than or equal to zero if specified.

.google.protobuf.Int32Value limit = 5;

Returns
TypeDescription
StructuredQuery.Builder

clearOffset()

public StructuredQuery.Builder clearOffset()

The number of documents to skip before returning the first result. This applies after the constraints specified by the WHERE, START AT, & END AT but before the LIMIT clause. Requires:

  • The value must be greater than or equal to zero if specified.

int32 offset = 6;

Returns
TypeDescription
StructuredQuery.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public StructuredQuery.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
StructuredQuery.Builder
Overrides

clearOrderBy()

public StructuredQuery.Builder clearOrderBy()

The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

  • The order_by is required to reference all fields used with an inequality filter.
  • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
  • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
  • ORDER BY a becomes ORDER BY a ASC, name ASC
  • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
  • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
  • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

Returns
TypeDescription
StructuredQuery.Builder

clearSelect()

public StructuredQuery.Builder clearSelect()

The projection to return.

.google.firestore.v1.StructuredQuery.Projection select = 1;

Returns
TypeDescription
StructuredQuery.Builder

clearStartAt()

public StructuredQuery.Builder clearStartAt()

A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Returns
    TypeDescription
    StructuredQuery.Builder

    clearWhere()

    public StructuredQuery.Builder clearWhere()

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Returns
    TypeDescription
    StructuredQuery.Builder

    clone()

    public StructuredQuery.Builder clone()
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides

    getDefaultInstanceForType()

    public StructuredQuery getDefaultInstanceForType()
    Returns
    TypeDescription
    StructuredQuery

    getDescriptorForType()

    public Descriptors.Descriptor getDescriptorForType()
    Returns
    TypeDescription
    Descriptor
    Overrides

    getEndAt()

    public Cursor getEndAt()

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Returns
    TypeDescription
    Cursor

    The endAt.

    getEndAtBuilder()

    public Cursor.Builder getEndAtBuilder()

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Returns
    TypeDescription
    Cursor.Builder

    getEndAtOrBuilder()

    public CursorOrBuilder getEndAtOrBuilder()

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Returns
    TypeDescription
    CursorOrBuilder

    getFrom(int index)

    public StructuredQuery.CollectionSelector getFrom(int index)

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.CollectionSelector

    getFromBuilder(int index)

    public StructuredQuery.CollectionSelector.Builder getFromBuilder(int index)

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.CollectionSelector.Builder

    getFromBuilderList()

    public List<StructuredQuery.CollectionSelector.Builder> getFromBuilderList()

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Returns
    TypeDescription
    List<Builder>

    getFromCount()

    public int getFromCount()

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Returns
    TypeDescription
    int

    getFromList()

    public List<StructuredQuery.CollectionSelector> getFromList()

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Returns
    TypeDescription
    List<CollectionSelector>

    getFromOrBuilder(int index)

    public StructuredQuery.CollectionSelectorOrBuilder getFromOrBuilder(int index)

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.CollectionSelectorOrBuilder

    getFromOrBuilderList()

    public List<? extends StructuredQuery.CollectionSelectorOrBuilder> getFromOrBuilderList()

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Returns
    TypeDescription
    List<? extends com.google.firestore.v1.StructuredQuery.CollectionSelectorOrBuilder>

    getLimit()

    public Int32Value getLimit()

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Returns
    TypeDescription
    Int32Value

    The limit.

    getLimitBuilder()

    public Int32Value.Builder getLimitBuilder()

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Returns
    TypeDescription
    Builder

    getLimitOrBuilder()

    public Int32ValueOrBuilder getLimitOrBuilder()

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Returns
    TypeDescription
    Int32ValueOrBuilder

    getOffset()

    public int getOffset()

    The number of documents to skip before returning the first result. This applies after the constraints specified by the WHERE, START AT, & END AT but before the LIMIT clause. Requires:

    • The value must be greater than or equal to zero if specified.

    int32 offset = 6;

    Returns
    TypeDescription
    int

    The offset.

    getOrderBy(int index)

    public StructuredQuery.Order getOrderBy(int index)

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.Order

    getOrderByBuilder(int index)

    public StructuredQuery.Order.Builder getOrderByBuilder(int index)

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.Order.Builder

    getOrderByBuilderList()

    public List<StructuredQuery.Order.Builder> getOrderByBuilderList()

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Returns
    TypeDescription
    List<Builder>

    getOrderByCount()

    public int getOrderByCount()

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Returns
    TypeDescription
    int

    getOrderByList()

    public List<StructuredQuery.Order> getOrderByList()

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Returns
    TypeDescription
    List<Order>

    getOrderByOrBuilder(int index)

    public StructuredQuery.OrderOrBuilder getOrderByOrBuilder(int index)

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.OrderOrBuilder

    getOrderByOrBuilderList()

    public List<? extends StructuredQuery.OrderOrBuilder> getOrderByOrBuilderList()

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Returns
    TypeDescription
    List<? extends com.google.firestore.v1.StructuredQuery.OrderOrBuilder>

    getSelect()

    public StructuredQuery.Projection getSelect()

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Returns
    TypeDescription
    StructuredQuery.Projection

    The select.

    getSelectBuilder()

    public StructuredQuery.Projection.Builder getSelectBuilder()

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Returns
    TypeDescription
    StructuredQuery.Projection.Builder

    getSelectOrBuilder()

    public StructuredQuery.ProjectionOrBuilder getSelectOrBuilder()

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Returns
    TypeDescription
    StructuredQuery.ProjectionOrBuilder

    getStartAt()

    public Cursor getStartAt()

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Returns
    TypeDescription
    Cursor

    The startAt.

    getStartAtBuilder()

    public Cursor.Builder getStartAtBuilder()

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Returns
    TypeDescription
    Cursor.Builder

    getStartAtOrBuilder()

    public CursorOrBuilder getStartAtOrBuilder()

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Returns
    TypeDescription
    CursorOrBuilder

    getWhere()

    public StructuredQuery.Filter getWhere()

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Returns
    TypeDescription
    StructuredQuery.Filter

    The where.

    getWhereBuilder()

    public StructuredQuery.Filter.Builder getWhereBuilder()

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Returns
    TypeDescription
    StructuredQuery.Filter.Builder

    getWhereOrBuilder()

    public StructuredQuery.FilterOrBuilder getWhereOrBuilder()

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Returns
    TypeDescription
    StructuredQuery.FilterOrBuilder

    hasEndAt()

    public boolean hasEndAt()

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Returns
    TypeDescription
    boolean

    Whether the endAt field is set.

    hasLimit()

    public boolean hasLimit()

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Returns
    TypeDescription
    boolean

    Whether the limit field is set.

    hasSelect()

    public boolean hasSelect()

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Returns
    TypeDescription
    boolean

    Whether the select field is set.

    hasStartAt()

    public boolean hasStartAt()

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Returns
    TypeDescription
    boolean

    Whether the startAt field is set.

    hasWhere()

    public boolean hasWhere()

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Returns
    TypeDescription
    boolean

    Whether the where field is set.

    internalGetFieldAccessorTable()

    protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
    Returns
    TypeDescription
    FieldAccessorTable
    Overrides

    isInitialized()

    public final boolean isInitialized()
    Returns
    TypeDescription
    boolean
    Overrides

    mergeEndAt(Cursor value)

    public StructuredQuery.Builder mergeEndAt(Cursor value)

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Parameter
    NameDescription
    valueCursor
    Returns
    TypeDescription
    StructuredQuery.Builder

    mergeFrom(StructuredQuery other)

    public StructuredQuery.Builder mergeFrom(StructuredQuery other)
    Parameter
    NameDescription
    otherStructuredQuery
    Returns
    TypeDescription
    StructuredQuery.Builder

    mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

    public StructuredQuery.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
    Parameters
    NameDescription
    inputCodedInputStream
    extensionRegistryExtensionRegistryLite
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides Exceptions
    TypeDescription
    IOException

    mergeFrom(Message other)

    public StructuredQuery.Builder mergeFrom(Message other)
    Parameter
    NameDescription
    otherMessage
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides

    mergeLimit(Int32Value value)

    public StructuredQuery.Builder mergeLimit(Int32Value value)

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Parameter
    NameDescription
    valueInt32Value
    Returns
    TypeDescription
    StructuredQuery.Builder

    mergeSelect(StructuredQuery.Projection value)

    public StructuredQuery.Builder mergeSelect(StructuredQuery.Projection value)

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Parameter
    NameDescription
    valueStructuredQuery.Projection
    Returns
    TypeDescription
    StructuredQuery.Builder

    mergeStartAt(Cursor value)

    public StructuredQuery.Builder mergeStartAt(Cursor value)

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Parameter
    NameDescription
    valueCursor
    Returns
    TypeDescription
    StructuredQuery.Builder

    mergeUnknownFields(UnknownFieldSet unknownFields)

    public final StructuredQuery.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
    Parameter
    NameDescription
    unknownFieldsUnknownFieldSet
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides

    mergeWhere(StructuredQuery.Filter value)

    public StructuredQuery.Builder mergeWhere(StructuredQuery.Filter value)

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Parameter
    NameDescription
    valueStructuredQuery.Filter
    Returns
    TypeDescription
    StructuredQuery.Builder

    removeFrom(int index)

    public StructuredQuery.Builder removeFrom(int index)

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.Builder

    removeOrderBy(int index)

    public StructuredQuery.Builder removeOrderBy(int index)

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Parameter
    NameDescription
    indexint
    Returns
    TypeDescription
    StructuredQuery.Builder

    setEndAt(Cursor value)

    public StructuredQuery.Builder setEndAt(Cursor value)

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Parameter
    NameDescription
    valueCursor
    Returns
    TypeDescription
    StructuredQuery.Builder

    setEndAt(Cursor.Builder builderForValue)

    public StructuredQuery.Builder setEndAt(Cursor.Builder builderForValue)

    A potential prefix of a position in the result set to end the query at. This is similar to START_AT but with it controlling the end position rather than the start position. Requires:

    • The number of values cannot be greater than the number of fields specified in the ORDER BY clause.

    .google.firestore.v1.Cursor end_at = 8;

    Parameter
    NameDescription
    builderForValueCursor.Builder
    Returns
    TypeDescription
    StructuredQuery.Builder

    setField(Descriptors.FieldDescriptor field, Object value)

    public StructuredQuery.Builder setField(Descriptors.FieldDescriptor field, Object value)
    Parameters
    NameDescription
    fieldFieldDescriptor
    valueObject
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides

    setFrom(int index, StructuredQuery.CollectionSelector value)

    public StructuredQuery.Builder setFrom(int index, StructuredQuery.CollectionSelector value)

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Parameters
    NameDescription
    indexint
    valueStructuredQuery.CollectionSelector
    Returns
    TypeDescription
    StructuredQuery.Builder

    setFrom(int index, StructuredQuery.CollectionSelector.Builder builderForValue)

    public StructuredQuery.Builder setFrom(int index, StructuredQuery.CollectionSelector.Builder builderForValue)

    The collections to query.

    repeated .google.firestore.v1.StructuredQuery.CollectionSelector from = 2;

    Parameters
    NameDescription
    indexint
    builderForValueStructuredQuery.CollectionSelector.Builder
    Returns
    TypeDescription
    StructuredQuery.Builder

    setLimit(Int32Value value)

    public StructuredQuery.Builder setLimit(Int32Value value)

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Parameter
    NameDescription
    valueInt32Value
    Returns
    TypeDescription
    StructuredQuery.Builder

    setLimit(Int32Value.Builder builderForValue)

    public StructuredQuery.Builder setLimit(Int32Value.Builder builderForValue)

    The maximum number of results to return. Applies after all other constraints. Requires:

    • The value must be greater than or equal to zero if specified.

    .google.protobuf.Int32Value limit = 5;

    Parameter
    NameDescription
    builderForValueBuilder
    Returns
    TypeDescription
    StructuredQuery.Builder

    setOffset(int value)

    public StructuredQuery.Builder setOffset(int value)

    The number of documents to skip before returning the first result. This applies after the constraints specified by the WHERE, START AT, & END AT but before the LIMIT clause. Requires:

    • The value must be greater than or equal to zero if specified.

    int32 offset = 6;

    Parameter
    NameDescription
    valueint

    The offset to set.

    Returns
    TypeDescription
    StructuredQuery.Builder

    This builder for chaining.

    setOrderBy(int index, StructuredQuery.Order value)

    public StructuredQuery.Builder setOrderBy(int index, StructuredQuery.Order value)

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Parameters
    NameDescription
    indexint
    valueStructuredQuery.Order
    Returns
    TypeDescription
    StructuredQuery.Builder

    setOrderBy(int index, StructuredQuery.Order.Builder builderForValue)

    public StructuredQuery.Builder setOrderBy(int index, StructuredQuery.Order.Builder builderForValue)

    The order to apply to the query results. Firestore allows callers to provide a full ordering, a partial ordering, or no ordering at all. In all cases, Firestore guarantees a stable ordering through the following rules:

    • The order_by is required to reference all fields used with an inequality filter.
    • All fields that are required to be in the order_by but are not already present are appended in lexicographical ordering of the field name.
    • If an order on name is not specified, it is appended by default. Fields are appended with the same sort direction as the last order specified, or 'ASCENDING' if no order was specified. For example:
    • ORDER BY a becomes ORDER BY a ASC, name ASC
    • ORDER BY a DESC becomes ORDER BY a DESC, name DESC
    • WHERE a > 1 becomes WHERE a > 1 ORDER BY a ASC, name ASC
    • WHERE name > ... AND a > 1 becomes WHERE name > ... AND a > 1 ORDER BY a ASC, name ASC

    repeated .google.firestore.v1.StructuredQuery.Order order_by = 4;

    Parameters
    NameDescription
    indexint
    builderForValueStructuredQuery.Order.Builder
    Returns
    TypeDescription
    StructuredQuery.Builder

    setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

    public StructuredQuery.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
    Parameters
    NameDescription
    fieldFieldDescriptor
    indexint
    valueObject
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides

    setSelect(StructuredQuery.Projection value)

    public StructuredQuery.Builder setSelect(StructuredQuery.Projection value)

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Parameter
    NameDescription
    valueStructuredQuery.Projection
    Returns
    TypeDescription
    StructuredQuery.Builder

    setSelect(StructuredQuery.Projection.Builder builderForValue)

    public StructuredQuery.Builder setSelect(StructuredQuery.Projection.Builder builderForValue)

    The projection to return.

    .google.firestore.v1.StructuredQuery.Projection select = 1;

    Parameter
    NameDescription
    builderForValueStructuredQuery.Projection.Builder
    Returns
    TypeDescription
    StructuredQuery.Builder

    setStartAt(Cursor value)

    public StructuredQuery.Builder setStartAt(Cursor value)

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Parameter
    NameDescription
    valueCursor
    Returns
    TypeDescription
    StructuredQuery.Builder

    setStartAt(Cursor.Builder builderForValue)

    public StructuredQuery.Builder setStartAt(Cursor.Builder builderForValue)

    A potential prefix of a position in the result set to start the query at. The ordering of the result set is based on the ORDER BY clause of the original query. ` SELECT * FROM k WHERE a = 1 AND b > 2 ORDER BY b ASC, name ASC; This query's results are ordered by (b ASC, name ASC). Cursors can reference either the full ordering or a prefix of the location, though it cannot reference more fields than what are in the provided ORDER BY. Continuing off the example above, attaching the following start cursors will have varying impact:

    START BEFORE (2, /k/123): start the query right before a = 1 AND b > 2 AND name > /k/123.
  • START AFTER (10): start the query right after a = 1 AND b > 10. Unlike OFFSET which requires scanning over the first N results to skip, a start cursor allows the query to begin at a logical position. This position is not required to match an actual result, it will scan forward from this position to find the next document. Requires:
  • The number of values cannot be greater than the number of fields specified in the
  • ORDER BY` clause.

    .google.firestore.v1.Cursor start_at = 7;

    Parameter
    NameDescription
    builderForValueCursor.Builder
    Returns
    TypeDescription
    StructuredQuery.Builder

    setUnknownFields(UnknownFieldSet unknownFields)

    public final StructuredQuery.Builder setUnknownFields(UnknownFieldSet unknownFields)
    Parameter
    NameDescription
    unknownFieldsUnknownFieldSet
    Returns
    TypeDescription
    StructuredQuery.Builder
    Overrides

    setWhere(StructuredQuery.Filter value)

    public StructuredQuery.Builder setWhere(StructuredQuery.Filter value)

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Parameter
    NameDescription
    valueStructuredQuery.Filter
    Returns
    TypeDescription
    StructuredQuery.Builder

    setWhere(StructuredQuery.Filter.Builder builderForValue)

    public StructuredQuery.Builder setWhere(StructuredQuery.Filter.Builder builderForValue)

    The filter to apply.

    .google.firestore.v1.StructuredQuery.Filter where = 3;

    Parameter
    NameDescription
    builderForValueStructuredQuery.Filter.Builder
    Returns
    TypeDescription
    StructuredQuery.Builder