pub struct DiffViewModel { /* private fields */ }
Expand description
Tracks differences in the viewmodel attached to a controller and its subtree
Implementations§
Source§impl DiffViewModel
impl DiffViewModel
Sourcepub fn new(controller: Arc<dyn Controller>) -> DiffViewModel
pub fn new(controller: Arc<dyn Controller>) -> DiffViewModel
Creates a new viewmodel tracker for a particular controller
Sourcepub fn watch(&self) -> WatchViewModel
pub fn watch(&self) -> WatchViewModel
Reads the current state of the controller and creates a watcher for any changes that might occur to it.
Sourcepub fn rotate_watch(
&self,
last_watch: WatchViewModel,
) -> (Vec<ViewModelUpdate>, WatchViewModel)
pub fn rotate_watch( &self, last_watch: WatchViewModel, ) -> (Vec<ViewModelUpdate>, WatchViewModel)
Reads the updates from a WatchViewModel and create a new one that will see future updates
Auto Trait Implementations§
impl Freeze for DiffViewModel
impl !RefUnwindSafe for DiffViewModel
impl Send for DiffViewModel
impl Sync for DiffViewModel
impl Unpin for DiffViewModel
impl !UnwindSafe for DiffViewModel
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