Enum radicle_surf::file_system::directory::DirectoryContents[][src]

pub enum DirectoryContents {
    File {
        name: Label,
        file: File,
    },
    Directory(Directory),
}

DirectoryContents is an enumeration of what a Directory can contain and is used for when we are iterating through a Directory.

Variants

File

The File variant contains the file’s name and the File itself.

Show fields

Fields of File

name: Label

The name of the file.

file: File

The file data.

Directory(Directory)

The Directory variant contains a sub-directory to the current one.

Implementations

impl DirectoryContents[src]

pub fn label(&self) -> Label[src]

Get a label for the DirectoryContents, either the name of the File or the name of the Directory.

Trait Implementations

impl Clone for DirectoryContents[src]

impl Debug for DirectoryContents[src]

impl Eq for DirectoryContents[src]

impl PartialEq<DirectoryContents> for DirectoryContents[src]

impl StructuralEq for DirectoryContents[src]

impl StructuralPartialEq for DirectoryContents[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> Conv for T

impl<T> Conv for T

impl<T> FmtForward for T

impl<T> From<T> for T[src]

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

impl<T> Pipe for T where
    T: ?Sized

impl<T> Pipe for T

impl<T> PipeAsRef for T

impl<T> PipeBorrow for T

impl<T> PipeDeref for T

impl<T> PipeRef for T

impl<T> Tap for T

impl<T> Tap for T

impl<T, U> TapAsRef<U> for T where
    U: ?Sized

impl<T, U> TapBorrow<U> for T where
    U: ?Sized

impl<T> TapDeref for T

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> TryConv for T

impl<T> TryConv for T

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.