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

Function decode_view_seq

atomic-core/src/pristine/tables.rs:877–881  ·  view source on GitHub ↗
(key: &[u8; 16])

Source from the content-addressed store, hash-verified

875/// Decode a view-sequence pair from 16 bytes
876#[inline]
877pub fn decode_view_seq(key: &[u8; 16]) -> (u64, u64) {
878 let view_id = u64::from_be_bytes(key[0..8].try_into().unwrap());
879 let seq = u64::from_be_bytes(key[8..16].try_into().unwrap());
880 (view_id, seq)
881}
882
883/// Encode a view-merkle pair as 40 bytes
884#[inline]

Callers 3

iter_changesMethod · 0.85
iter_changesMethod · 0.85

Calls 1

unwrapMethod · 0.45

Tested by 1