value_log/handle.rs
1// Copyright (c) 2024-present, fjall-rs
2// This source code is licensed under both the Apache 2.0 and MIT License
3// (found in the LICENSE-* files in the repository)
4
5use crate::id::SegmentId;
6use std::hash::Hash;
7
8/// A value handle points into the value log
9#[allow(clippy::module_name_repetitions)]
10#[derive(Clone, Debug, Eq, Hash, PartialEq)]
11#[cfg_attr(feature = "serde", derive(serde::Deserialize, serde::Serialize))]
12pub struct ValueHandle {
13 /// Segment ID
14 pub segment_id: SegmentId,
15
16 /// Offset in file
17 pub offset: u64,
18}