Function massa_execution_worker::datastore_scan::scan_datastore
source · 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 queryprefix: prefix to filter keysstart_key: start key of the rangeend_key: end key of the rangecount: 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.