pub struct TreeObserver { /* private fields */ }
Expand description
An observer that can subscribe to tree update events.
Implementations§
Source§impl TreeObserver
impl TreeObserver
pub fn new() -> Self
pub fn subscribe( self: &Arc<Self>, callback: impl Fn(&TreeUpdateEvent) + Send + Sync + 'static, ) -> Subscription
pub fn notify(&self, event: &TreeUpdateEvent)
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for TreeObserver
impl !RefUnwindSafe for TreeObserver
impl Send for TreeObserver
impl Sync for TreeObserver
impl Unpin for TreeObserver
impl !UnwindSafe for TreeObserver
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