pub enum ObjectExpansion {
AsIs,
TreeContents,
TreeAdditionsComparedToAncestor,
}Expand description
The way input objects are handled
Variants
AsIs
Don’t do anything with the input objects except for transforming them into pack entries
TreeContents
If the input object is a Commit then turn it into a pack entry. Additionally obtain its tree, turn it into a pack entry
along with all of its contents, that is nested trees, and any other objects reachable from it.
Otherwise, the same as AsIs.
This mode is useful if all reachable objects should be added, as in cloning a repository.
TreeAdditionsComparedToAncestor
If the input is a commit, obtain its ancestors and turn them into pack entries. Obtain the ancestor trees along with the commits
tree and turn them into pack entries. Finally obtain the added/changed objects when comparing the ancestor trees with the
current tree and turn them into entries as well.
Otherwise, the same as AsIs.
This mode is useful to build a pack containing only new objects compared to a previous state.
Trait Implementations
sourceimpl Clone for ObjectExpansion
impl Clone for ObjectExpansion
sourcefn clone(&self) -> ObjectExpansion
fn clone(&self) -> ObjectExpansion
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for ObjectExpansion
impl Debug for ObjectExpansion
sourceimpl Default for ObjectExpansion
impl Default for ObjectExpansion
sourceimpl<'de> Deserialize<'de> for ObjectExpansion
impl<'de> Deserialize<'de> for ObjectExpansion
sourcefn 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
sourceimpl Hash for ObjectExpansion
impl Hash for ObjectExpansion
sourceimpl Ord for ObjectExpansion
impl Ord for ObjectExpansion
sourceimpl PartialEq<ObjectExpansion> for ObjectExpansion
impl PartialEq<ObjectExpansion> for ObjectExpansion
sourceimpl PartialOrd<ObjectExpansion> for ObjectExpansion
impl PartialOrd<ObjectExpansion> for ObjectExpansion
sourcefn partial_cmp(&self, other: &ObjectExpansion) -> Option<Ordering>
fn partial_cmp(&self, other: &ObjectExpansion) -> Option<Ordering>
This method returns an ordering between self and other values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
sourceimpl Serialize for ObjectExpansion
impl Serialize for ObjectExpansion
impl Copy for ObjectExpansion
impl Eq for ObjectExpansion
impl StructuralEq for ObjectExpansion
impl StructuralPartialEq for ObjectExpansion
Auto Trait Implementations
impl RefUnwindSafe for ObjectExpansion
impl Send for ObjectExpansion
impl Sync for ObjectExpansion
impl Unpin for ObjectExpansion
impl UnwindSafe for ObjectExpansion
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
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more