Skip to main content

Module index_picker

Module index_picker 

Source
Expand description

Sum-index pickers. Parallels count’s index_picker.rs.

Two strict-coverage pickers:

  • find_summable_index_for_where_clauses: returns the summable: "<prop>" index whose properties exactly match the Equal/In where-clause fields and whose summed property equals the request’s sum_property. None on miss (no partial coverage).
  • find_range_summable_index_for_where_clauses: returns the rangeSummable: true index whose Equal/In prefix covers the non-range clauses AND whose last property is the range terminator. None on miss.

Reject-on-miss is the load-bearing contract: callers landing in “no covering index” return WhereClauseOnNonIndexedProperty so the prover and verifier reject the same set of inputs (same as count).

Functions§

find_range_summable_index_for_where_clauses
Find a rangeSummable: true index whose properties cover the non-range Equal/In clauses as a prefix AND whose last property is the range terminator. The summed property must match sum_property.
find_summable_index_for_where_clauses
Find a summable: "<prop>" index whose properties exactly cover the Equal/In where-clause fields AND whose summed property name equals the request’s sum_property.