pub enum Body {
Inline(Vec<u8>),
Blob {
hash: ContentHash,
len: u64,
},
}Expand description
A record body. Inline stores bytes directly in the record; Blob
references content held out-of-line in a content-addressed BlobStore,
so byte-identical bodies (e.g. code-graph slices shared across worktrees)
are stored once. See ADR 0012.
Variants§
Inline(Vec<u8>)
Blob
Content stored out-of-line under hash in a BlobStore; len is the
referenced content’s byte length. The record itself carries only the
reference — the bytes are fetched via BlobStore::get_blob.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Body
impl<'de> Deserialize<'de> for Body
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Body
impl StructuralPartialEq for Body
Auto Trait Implementations§
impl Freeze for Body
impl RefUnwindSafe for Body
impl Send for Body
impl Sync for Body
impl Unpin for Body
impl UnsafeUnpin for Body
impl UnwindSafe for Body
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more