(
&self,
key: &[u8; 12],
)
| 1365 | } |
| 1366 | |
| 1367 | fn get_crdt_leaf( |
| 1368 | &self, |
| 1369 | key: &[u8; 12], |
| 1370 | ) -> PristineResult<Option<crate::crdt::tables::SerializedLeaf>> { |
| 1371 | use crate::crdt::tables::{decode_leaf_value, LEAVES}; |
| 1372 | let table = crdt_table_opt!(self, LEAVES); |
| 1373 | let result = match table.get(key)? { |
| 1374 | Some(guard) => { |
| 1375 | let bytes: [u8; 22] = *guard.value(); |
| 1376 | Some(decode_leaf_value(&bytes)) |
| 1377 | } |
| 1378 | None => None, |
| 1379 | }; |
| 1380 | Ok(result) |
| 1381 | } |
| 1382 | |
| 1383 | fn get_trunk_by_path(&self, path: &str) -> PristineResult<Option<crate::crdt::TrunkId>> { |
| 1384 | use crate::crdt::tables::{decode_trunk_id, PATH_TRUNK}; |
no test coverage detected