Struct egui_file_dialog::DirectoryEntry 
source · pub struct DirectoryEntry {
    pub selected: bool,
    /* private fields */
}Expand description
Contains the metadata of a directory item.
This struct is mainly there so that the metadata can be loaded once and not that
a request has to be sent to the OS every frame using, for example, path.is_file().
Fields§
§selected: boolIf the item is marked as selected as part of a multi selection.
Implementations§
source§impl DirectoryEntry
 
impl DirectoryEntry
sourcepub fn from_path(config: &FileDialogConfig, path: &Path) -> Self
 
pub fn from_path(config: &FileDialogConfig, path: &Path) -> Self
Creates a new directory entry from a path
sourcepub fn path_eq(&self, other: &DirectoryEntry) -> bool
 
pub fn path_eq(&self, other: &DirectoryEntry) -> bool
Checks if the path of the current directory entry matches the other directory entry.
sourcepub fn is_dir(&self) -> bool
 
pub fn is_dir(&self) -> bool
Returns true if the item is a directory. False is returned if the item is a file or the path did not exist when the DirectoryEntry object was created.
sourcepub fn is_file(&self) -> bool
 
pub fn is_file(&self) -> bool
Returns true if the item is a file. False is returned if the item is a directory or the path did not exist when the DirectoryEntry object was created.
sourcepub fn is_system_file(&self) -> bool
 
pub fn is_system_file(&self) -> bool
Returns true if the item is a system file.
sourcepub fn to_path_buf(&self) -> PathBuf
 
pub fn to_path_buf(&self) -> PathBuf
Clones the path of the directory item.
Returns whether the path this DirectoryEntry points to is considered hidden.
Trait Implementations§
source§impl Clone for DirectoryEntry
 
impl Clone for DirectoryEntry
source§fn clone(&self) -> DirectoryEntry
 
fn clone(&self) -> DirectoryEntry
1.0.0 · source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for DirectoryEntry
 
impl Debug for DirectoryEntry
source§impl Default for DirectoryEntry
 
impl Default for DirectoryEntry
source§fn default() -> DirectoryEntry
 
fn default() -> DirectoryEntry
source§impl<'de> Deserialize<'de> for DirectoryEntry
 
impl<'de> Deserialize<'de> for DirectoryEntry
source§fn 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>,
Auto Trait Implementations§
impl Freeze for DirectoryEntry
impl RefUnwindSafe for DirectoryEntry
impl Send for DirectoryEntry
impl Sync for DirectoryEntry
impl Unpin for DirectoryEntry
impl UnwindSafe for DirectoryEntry
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
source§impl<T> CloneToUninit for Twhere
    T: Clone,
 
impl<T> CloneToUninit for Twhere
    T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
 
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit)