pub enum DriverChoice {
BuiltIn(BuiltinDriver),
Index(usize),
}
Expand description
The selection of the driver to use by a resource obtained with Platform::prepare_merge()
.
If available, an index into the drivers
field to access more diff-related information of the driver for items
at the given path, as previously determined by git-attributes.
merge
is set- Use the
BuiltinDriver::Text
- Use the
-merge
is unset- Use the
BuiltinDriver::Binary
- Use the
!merge
is unspecifiedmerge=name
- Search for a user-configured or built-in driver called
name
. - If not found, silently default to
BuiltinDriver::Text
- Search for a user-configured or built-in driver called
Note that drivers are queried even if there is no object available.
Variants§
BuiltIn(BuiltinDriver)
Use the given built-in driver to perform the merge.
Index(usize)
Use the user-provided driver program using the index into the platform drivers array.
Trait Implementations§
source§impl Clone for DriverChoice
impl Clone for DriverChoice
source§fn clone(&self) -> DriverChoice
fn clone(&self) -> DriverChoice
Returns a copy 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 DriverChoice
impl Debug for DriverChoice
source§impl Default for DriverChoice
impl Default for DriverChoice
source§impl Hash for DriverChoice
impl Hash for DriverChoice
source§impl Ord for DriverChoice
impl Ord for DriverChoice
source§fn cmp(&self, other: &DriverChoice) -> Ordering
fn cmp(&self, other: &DriverChoice) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for DriverChoice
impl PartialEq for DriverChoice
source§impl PartialOrd for DriverChoice
impl PartialOrd for DriverChoice
impl Copy for DriverChoice
impl Eq for DriverChoice
impl StructuralPartialEq for DriverChoice
Auto Trait Implementations§
impl Freeze for DriverChoice
impl RefUnwindSafe for DriverChoice
impl Send for DriverChoice
impl Sync for DriverChoice
impl Unpin for DriverChoice
impl UnwindSafe for DriverChoice
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)