pub struct ContextTree { /* private fields */ }
Implementations§
Source§impl ContextTree
impl ContextTree
Sourcepub fn new() -> ContextTree
pub fn new() -> ContextTree
This function creates a new context tree root.
Sourcepub fn enter(self: &Rc<Self>) -> ContextTree
pub fn enter(self: &Rc<Self>) -> ContextTree
This function enters a new branch of a given context tree.
pub fn insert<T>(&self, value: Rc<T>)where
T: 'static,
pub fn insert_raw(&self, value: Rc<dyn Any>)
pub fn get_flat<T>(&self) -> Option<Rc<T>>where
T: 'static,
pub fn get<T>(&self) -> Option<Rc<T>>where
T: 'static,
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for ContextTree
impl !RefUnwindSafe for ContextTree
impl !Send for ContextTree
impl !Sync for ContextTree
impl Unpin for ContextTree
impl !UnwindSafe for ContextTree
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