pub fn scan_datastore(
    addr: &Address,
    prefix: &[u8],
    start_key: Bound<Vec<u8>>,
    end_key: Bound<Vec<u8>>,
    count: Option<u32>,
    final_state: Arc<RwLock<dyn FinalStateController>>,
    active_history: Arc<RwLock<ActiveHistory>>,
    added_changes: Option<&LedgerChanges>,
) -> (Option<BTreeSet<Vec<u8>>>, Option<BTreeSet<Vec<u8>>>)
Expand description

Gets a copy of a datastore keys for a given address

§Arguments

  • addr: address to query
  • prefix: prefix to filter keys
  • start_key: start key of the range
  • end_key: end key of the range
  • count: maximum number of keys to return

§Returns

A tuple of two Option<BTreeSet<Vec<u8>>>: None means that the address does not exist. The first element is the final state keys, the second element is the speculative keys.