MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / iter_ref_mapping_bytes

Method iter_ref_mapping_bytes

atomic-core/src/pristine/txn/read.rs:3102–3114  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

3100 }
3101
3102 fn iter_ref_mapping_bytes(&self) -> PristineResult<Vec<(u64, Vec<u8>)>> {
3103 let table = match self.txn.open_table(REF_MAPPINGS) {
3104 Ok(table) => table,
3105 Err(redb::TableError::TableDoesNotExist(_)) => return Ok(Vec::new()),
3106 Err(error) => return Err(PristineError::from(error)),
3107 };
3108 let mut rows = Vec::new();
3109 for row in table.iter()? {
3110 let (key, value) = row?;
3111 rows.push((key.value(), value.value().to_vec()));
3112 }
3113 Ok(rows)
3114 }
3115}
3116
3117impl GitShaIndexTxnT for ReadTxn {

Callers 3

list_ref_mappingsMethod · 0.45

Calls 3

iterMethod · 0.45
pushMethod · 0.45
valueMethod · 0.45

Tested by

no test coverage detected