Struct git2::ApplyOptions
source · [−]pub struct ApplyOptions<'cb> { /* private fields */ }
Expand description
Options to specify when applying a diff
Implementations
sourceimpl<'cb> ApplyOptions<'cb>
impl<'cb> ApplyOptions<'cb>
sourcepub fn check(&mut self, check: bool) -> &mut Self
pub fn check(&mut self, check: bool) -> &mut Self
Don’t actually make changes, just test that the patch applies.
sourcepub fn hunk_callback<F>(&mut self, cb: F) -> &mut Self where
F: FnMut(Option<DiffHunk<'_>>) -> bool + 'cb,
pub fn hunk_callback<F>(&mut self, cb: F) -> &mut Self where
F: FnMut(Option<DiffHunk<'_>>) -> bool + 'cb,
When applying a patch, callback that will be made per hunk.
sourcepub fn delta_callback<F>(&mut self, cb: F) -> &mut Self where
F: FnMut(Option<DiffDelta<'_>>) -> bool + 'cb,
pub fn delta_callback<F>(&mut self, cb: F) -> &mut Self where
F: FnMut(Option<DiffDelta<'_>>) -> bool + 'cb,
When applying a patch, callback that will be made per delta (file).
sourcepub unsafe fn raw(&mut self) -> *const git_apply_options
pub unsafe fn raw(&mut self) -> *const git_apply_options
Pointer to a raw git_stash_apply_options
Auto Trait Implementations
impl<'cb> !RefUnwindSafe for ApplyOptions<'cb>
impl<'cb> !Send for ApplyOptions<'cb>
impl<'cb> !Sync for ApplyOptions<'cb>
impl<'cb> Unpin for ApplyOptions<'cb>
impl<'cb> !UnwindSafe for ApplyOptions<'cb>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more