/// Position of an entry's value on disk.
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
#[repr(C)]
pub struct DiskLoc {
pub offset: u32,
pub len: u32,
pub file_id: u16,
pub shard_id: u8,
_pad: u8,
}
impl DiskLoc {
#[inline]
pub fn new(shard_id: u8, file_id: u16, offset: u32, len: u32) -> Self {
Self {
offset,
len,
file_id,
shard_id,
_pad: 0,
}
}
}