Struct erg_compiler::module::graph::SharedModuleGraph
source · pub struct SharedModuleGraph(/* private fields */);
Implementations§
pub fn new() -> Self
pub fn get_node( &self, path: &NormalizedPathBuf ) -> Option<MappedRwLockReadGuard<'_, Node<NormalizedPathBuf, ()>>>
pub fn depends_on( &self, path: &NormalizedPathBuf, target: &NormalizedPathBuf ) -> bool
sourcepub fn children(&self, path: &NormalizedPathBuf) -> Set<NormalizedPathBuf>
pub fn children(&self, path: &NormalizedPathBuf) -> Set<NormalizedPathBuf>
(usually) path
is not contained
sourcepub fn ancestors(&self, path: &NormalizedPathBuf) -> Set<NormalizedPathBuf>
pub fn ancestors(&self, path: &NormalizedPathBuf) -> Set<NormalizedPathBuf>
(usually) path
is not contained
pub fn add_node_if_none(&self, path: &NormalizedPathBuf)
pub fn inc_ref( &self, referrer: &NormalizedPathBuf, depends_on: NormalizedPathBuf ) -> Result<(), IncRefError>
pub fn ref_inner(&self) -> RwLockReadGuard<'_, ModuleGraph>
pub fn remove(&self, path: &NormalizedPathBuf)
pub fn rename_path(&self, old: &NormalizedPathBuf, new: NormalizedPathBuf)
pub fn sort(&self) -> Result<(), TopoSortError>
pub fn entries(&self) -> Set<NormalizedPathBuf>
pub fn initialize(&self)
pub fn clone_inner(&self) -> ModuleGraph
pub fn display(&self) -> String
Trait Implementations§
source§fn clone(&self) -> SharedModuleGraph
fn clone(&self) -> SharedModuleGraph
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§fn default() -> SharedModuleGraph
fn default() -> SharedModuleGraph
Returns the “default value” for a type. Read more
Auto Trait Implementations§
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