[go: up one dir, main page]

[][src]Struct jwalk::DirEntry

pub struct DirEntry { /* fields omitted */ }

Representation of a file or directory.

Methods

impl DirEntry[src]

pub fn depth(&self) -> usize[src]

Depth of this entry relative to the root directory where the walk started.

pub fn file_name(&self) -> &OsStr[src]

File name of this entry without leading path component.

pub fn file_type(&self) -> Result<&FileType, &Error>[src]

File type for the file that this entry points at.

This function will not traverse symlinks.

pub fn path(&self) -> PathBuf[src]

Path to the file that this entry represents.

The path is created by joining the parent_spec path with the filename of this entry.

pub fn metadata(&self) -> Result<&Metadata, &Error>[src]

Metadata for the file that this entry points at.

This function will not traverse symlinks.

pub fn set_children_spec(&mut self, children_spec: Option<ReadDirSpec>)[src]

Set ReadDirSpec used for reading this entry's children. This is set by default for any directory entry. The process_entries callback may call entry.set_children_spec(None) to skip descending into a particular directory.

pub fn read_children_error(&self) -> Option<&Error>[src]

Error generated when reading this entry's children.

Trait Implementations

impl Debug for DirEntry[src]

Auto Trait Implementations

impl Send for DirEntry

impl !Sync for DirEntry

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]