Struct git2::BlameHunk [−][src]
Structure that represents a blame hunk.
Implementations
impl<'blame> BlameHunk<'blame>[src]
pub fn final_commit_id(&self) -> Oid[src]
Returns OID of the commit where this line was last changed
pub fn final_signature(&self) -> Signature<'_>[src]
Returns signature of the commit.
pub fn final_start_line(&self) -> usize[src]
Returns line number where this hunk begins.
Note that the start line is counting from 1.
pub fn orig_commit_id(&self) -> Oid[src]
Returns the OID of the commit where this hunk was found.
This will usually be the same as final_commit_id,
except when BlameOptions::track_copies_any_commit_copies has been
turned on
pub fn orig_signature(&self) -> Signature<'_>[src]
Returns signature of the commit.
pub fn orig_start_line(&self) -> usize[src]
Returns line number where this hunk begins.
Note that the start line is counting from 1.
pub fn path(&self) -> Option<&Path>[src]
Returns path to the file where this hunk originated.
Note: None could be returned for non-unicode paths on Widnows.
pub fn is_boundary(&self) -> bool[src]
Tests whether this hunk has been tracked to a boundary commit (the root, or the commit specified in git_blame_options.oldest_commit).
pub fn lines_in_hunk(&self) -> usize[src]
Returns number of lines in this hunk.
Auto Trait Implementations
impl<'blame> RefUnwindSafe for BlameHunk<'blame>
impl<'blame> !Send for BlameHunk<'blame>
impl<'blame> !Sync for BlameHunk<'blame>
impl<'blame> Unpin for BlameHunk<'blame>
impl<'blame> UnwindSafe for BlameHunk<'blame>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,