Trait Node
Source pub trait Node:
'static
+ Any
+ Send
+ Sync {
// Required methods
fn to_any(self: Arc<Self>) -> Arc<dyn Any + Send + Sync>;
fn parent(&self) -> Option<Arc<dyn Node>>;
fn filetype(&self) -> FileType;
fn id(&self) -> Arc<InodeId>;
fn open_dir<'async_trait>(
self: Arc<Self>,
) -> Pin<Box<dyn Future<Output = Result<Box<dyn WasiDir>, Error>> + Send + 'async_trait>>
where Self: 'async_trait;
fn open_file<'life0, 'async_trait>(
self: Arc<Self>,
path: &'life0 str,
dir: bool,
read: bool,
write: bool,
flags: FdFlags,
) -> Pin<Box<dyn Future<Output = Result<Box<dyn WasiFile>, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
// Provided method
fn root(self: &Arc<Self>) -> Arc<dyn Node>
where Self: Sized { ... }
}