pub struct File {
pub file_path: String,
pub content: Option<String>,
pub source_env: String,
pub updated_at: String,
pub deleted: bool,
}Expand description
One memory file as returned by GET /sync.
content is an Option so a tombstoned row reports JSON null rather
than "": the server withholds deleted content so a pull cannot
resurrect it, and an empty string would be indistinguishable from a
genuinely empty file.
Fields§
§file_path: StringThe file’s path relative to the project’s memory directory.
content: Option<String>The file’s exact bytes, or None for a tombstone.
source_env: StringThe machine that last wrote this file.
updated_at: StringWhen it was last written, in the crate’s frozen timestamp format.
deleted: boolWhether this row is a tombstone, meaning a puller should delete its local copy.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for File
impl<'de> Deserialize<'de> for File
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 StructuralPartialEq for File
Auto Trait Implementations§
impl Freeze for File
impl RefUnwindSafe for File
impl Send for File
impl Sync for File
impl Unpin for File
impl UnsafeUnpin for File
impl UnwindSafe for File
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