pub struct ListedFileDiff {
pub path: String,
pub old_path: Option<String>,
pub status: DiffStatus,
pub old_mode: Option<String>,
pub new_mode: Option<String>,
pub binary: bool,
pub similarity: Option<u32>,
pub stat: Option<LineStat>,
pub structured: Option<StructuredFileDiff>,
pub combined: Option<CombinedStructuredTextDiff>,
pub combined_status: Option<String>,
}Expand description
One changed file with optional patch body or line counts.
Fields§
§path: StringDisplay path (new side, or old for deletions).
old_path: Option<String>Pre-rename path when it differs from Self::path.
status: DiffStatusChange kind.
old_mode: Option<String>Old git mode (octal), when present.
new_mode: Option<String>New git mode (octal), when present.
binary: boolEither side looks like a binary blob.
similarity: Option<u32>Rename/copy similarity (0–100), when applicable.
stat: Option<LineStat>Line counts when DiffDetail::Stat was requested.
structured: Option<StructuredFileDiff>Structured hunks when DiffDetail::Patch was requested.
combined: Option<CombinedStructuredTextDiff>Combined (--cc) hunks for merge commits; mutually exclusive with Self::structured.
combined_status: Option<String>Per-parent status letters for combined merge name-status (e.g. MM, DD).
Trait Implementations§
impl Eq for FileDiff
impl StructuralPartialEq for FileDiff
Auto Trait Implementations§
impl Freeze for FileDiff
impl RefUnwindSafe for FileDiff
impl Send for FileDiff
impl Sync for FileDiff
impl Unpin for FileDiff
impl UnsafeUnpin for FileDiff
impl UnwindSafe for FileDiff
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