#[non_exhaustive]pub struct FileNodeView {
pub name: String,
pub path: String,
pub kind: FileNodeKind,
pub route_hint: Option<String>,
pub children: Option<Vec<FileNodeView>>,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringDisplay name (just the last path component, e.g. "users.json").
path: StringAbsolute path on disk.
kind: FileNodeKindWhat kind of filesystem node this is.
route_hint: Option<String>For files only — the URL path that would serve this file under
the dyn-route fallback (e.g. "/users" for users.json).
None for directories.
children: Option<Vec<FileNodeView>>Some(empty) for an unexpanded subdirectory, populated when
the embedder calls list_directory to expand. Always None
for files.
Trait Implementations§
Source§impl Clone for FileNodeView
impl Clone for FileNodeView
Source§fn clone(&self) -> FileNodeView
fn clone(&self) -> FileNodeView
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileNodeView
impl Debug for FileNodeView
Auto Trait Implementations§
impl Freeze for FileNodeView
impl RefUnwindSafe for FileNodeView
impl Send for FileNodeView
impl Sync for FileNodeView
impl Unpin for FileNodeView
impl UnsafeUnpin for FileNodeView
impl UnwindSafe for FileNodeView
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
Mutably borrows from an owned value. Read more