pub struct FileChange {
pub path: String,
pub old_path: Option<String>,
pub change_type: ChangeType,
pub old_blob_sha: Option<String>,
pub new_blob_sha: Option<String>,
pub hunks: Vec<DiffHunk>,
}Expand description
A file change within a commit.
Fields§
§path: StringPath to the file.
old_path: Option<String>Previous path (for renames/copies).
change_type: ChangeTypeType of change made to the file.
old_blob_sha: Option<String>SHA hash of the old blob (None for added files).
new_blob_sha: Option<String>SHA hash of the new blob (None for deleted files).
hunks: Vec<DiffHunk>Diff hunks showing the actual changes.
Trait Implementations§
Source§impl Clone for FileChange
impl Clone for FileChange
Source§fn clone(&self) -> FileChange
fn clone(&self) -> FileChange
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileChange
impl Debug for FileChange
Source§impl<'de> Deserialize<'de> for FileChange
impl<'de> Deserialize<'de> for FileChange
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
Auto Trait Implementations§
impl Freeze for FileChange
impl RefUnwindSafe for FileChange
impl Send for FileChange
impl Sync for FileChange
impl Unpin for FileChange
impl UnwindSafe for FileChange
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