Struct git2::DiffLine [−][src]
pub struct DiffLine<'a> { /* fields omitted */ }Structure describing a line (or data span) of a diff.
Methods
impl<'a> DiffLine<'a>[src]
impl<'a> DiffLine<'a>pub fn old_lineno(&self) -> Option<u32>[src]
pub fn old_lineno(&self) -> Option<u32>Line number in old file or None for added line
pub fn new_lineno(&self) -> Option<u32>[src]
pub fn new_lineno(&self) -> Option<u32>Line number in new file or None for deleted line
pub fn num_lines(&self) -> u32[src]
pub fn num_lines(&self) -> u32Number of newline characters in content
pub fn content_offset(&self) -> i64[src]
pub fn content_offset(&self) -> i64Offset in the original file to the content
pub fn content(&self) -> &[u8][src]
pub fn content(&self) -> &[u8]Content of this line as bytes.
pub fn origin(&self) -> char[src]
pub fn origin(&self) -> charSigil showing the origin of this DiffLine.
- Line context+- Line addition-- Line deletion=- Context (End of file)>- Add (End of file)<- Remove (End of file)F- File headerH- Hunk headerB- Line binary