pub struct EntryMut<'t> {
table: &'t mut Table,
id: Handle,
}Expand description
A mutable, object-like entry in a Table.
Entry wraps a Table and a Handle, and provides an ergonomic interface
for querying information about the state of the node at that Handle.
Its immutable counterpart, Entry, provides a similar interface for querying
the state of the Table, which may be shared among multiple Entries.
Fields§
§table: &'t mut Table§id: HandleImplementations§
Source§impl<'t> EntryMut<'t>
impl<'t> EntryMut<'t>
Sourcepub fn new(table: &'t mut Table, id: Handle) -> Self
pub fn new(table: &'t mut Table, id: Handle) -> Self
Constructs a new EntryMut from a &mut Table and a Handle.
Sourcepub fn lazy_imports(&self) -> Option<&SymMap<Path>>
pub fn lazy_imports(&self) -> Option<&SymMap<Path>>
Gets the lazy-imports list for this node
Sourcepub fn glob_imports(&self) -> Option<&[Path]>
pub fn glob_imports(&self) -> Option<&[Path]>
Gets the glob-imports list for this node
Sourcepub fn evaluate<Out>(
&mut self,
ty: &impl TypeExpression<Out>,
) -> Result<Out, Error>
pub fn evaluate<Out>( &mut self, ty: &impl TypeExpression<Out>, ) -> Result<Out, Error>
Evaluates a TypeExpression in this entry’s context
Sourcepub fn categorize(&mut self) -> Result<(), Error>
pub fn categorize(&mut self) -> Result<(), Error>
Calls categorize on this node in the table
Sourcepub fn with_id(&mut self, parent: Handle) -> EntryMut<'_>
pub fn with_id(&mut self, parent: Handle) -> EntryMut<'_>
Constructs a new Handle with the provided parent Handle
Sourcepub fn add_child(&mut self, name: Sym, child: Handle) -> Option<Handle>
pub fn add_child(&mut self, name: Sym, child: Handle) -> Option<Handle>
Adds an existing node as a child with the given name.
If that name is already taken, its previous Handle is returned.
Sourcepub fn add_import(&mut self, name: Sym, path: Path)
pub fn add_import(&mut self, name: Sym, path: Path)
Adds a lazy-import edge from name to path
Sourcepub fn add_glob(&mut self, path: Path)
pub fn add_glob(&mut self, path: Path)
Adds a glob-import edge to path.
Glob imports act as secondary (tertiary, etc.) parent edges, which are always transparent. They are checked in reverse order, giving later glob imports precedence over earlier ones.
Sourcepub fn set_impl_target(&mut self, target: Handle) -> Option<Handle>
pub fn set_impl_target(&mut self, target: Handle) -> Option<Handle>
Sets the impl target to target
Sourcepub fn mark_unchecked(&mut self)
pub fn mark_unchecked(&mut self)
Marks this EntryMut as unchecked.
Sourcepub fn mark_impl_item(&mut self)
pub fn mark_impl_item(&mut self)
Marks this EntryMut as an impl item