Struct git2::TreeEntry [−][src]
pub struct TreeEntry<'tree> { /* fields omitted */ }Expand description
A structure representing an entry inside of a tree. An entry is borrowed from a tree.
Implementations
impl<'tree> TreeEntry<'tree>[src]
impl<'tree> TreeEntry<'tree>[src]pub fn name(&self) -> Option<&str>[src]
pub fn name(&self) -> Option<&str>[src]Get the filename of a tree entry
Returns None if the name is not valid utf-8
pub fn name_bytes(&self) -> &[u8]ⓘ[src]
pub fn name_bytes(&self) -> &[u8]ⓘ[src]Get the filename of a tree entry
pub fn to_object<'a>(&self, repo: &'a Repository) -> Result<Object<'a>, Error>[src]
pub fn to_object<'a>(&self, repo: &'a Repository) -> Result<Object<'a>, Error>[src]Convert a tree entry to the object it points to.
pub fn kind(&self) -> Option<ObjectType>[src]
pub fn kind(&self) -> Option<ObjectType>[src]Get the type of the object pointed by the entry
pub fn filemode_raw(&self) -> i32[src]
pub fn filemode_raw(&self) -> i32[src]Get the raw UNIX file attributes of a tree entry
Trait Implementations
impl<'a> Ord for TreeEntry<'a>[src]
impl<'a> Ord for TreeEntry<'a>[src]impl<'a> PartialOrd<TreeEntry<'a>> for TreeEntry<'a>[src]
impl<'a> PartialOrd<TreeEntry<'a>> for TreeEntry<'a>[src]fn partial_cmp(&self, other: &TreeEntry<'a>) -> Option<Ordering>[src]
fn partial_cmp(&self, other: &TreeEntry<'a>) -> Option<Ordering>[src]This method returns an ordering between self and other values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool1.0.0[src]This method tests less than (for self and other) and is used by the < operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool1.0.0[src]This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
impl<'a> Eq for TreeEntry<'a>[src]
Auto Trait Implementations
impl<'tree> RefUnwindSafe for TreeEntry<'tree>
impl<'tree> !Send for TreeEntry<'tree>
impl<'tree> !Sync for TreeEntry<'tree>
impl<'tree> Unpin for TreeEntry<'tree>
impl<'tree> UnwindSafe for TreeEntry<'tree>
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]pub fn borrow_mut(&mut self) -> &mut T[src]
pub fn borrow_mut(&mut self) -> &mut T[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone, [src]
impl<T> ToOwned for T where
T: Clone, [src]type Owned = T
type Owned = TThe resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn to_owned(&self) -> T[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)[src]
pub fn clone_into(&self, target: &mut T)[src]🔬 This is a nightly-only experimental API. (toowned_clone_into)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more