pub struct ModelMonitor { /* private fields */ }Expand description
Model monitor for watching for changes to model files
Implementations§
Source§impl ModelMonitor
impl ModelMonitor
Sourcepub fn start(&mut self) -> Result<()>
pub fn start(&mut self) -> Result<()>
Start monitoring for model file changes
§Returns
Result<()>- Ok if monitoring started successfully, an error otherwise
Sourcepub fn stop(&mut self) -> Result<()>
pub fn stop(&mut self) -> Result<()>
Stop monitoring for model file changes
§Returns
Result<()>- Ok if monitoring stopped successfully, an error otherwise
Sourcepub fn get_model(&self, device_name: &str) -> Option<DeviceModel>
pub fn get_model(&self, device_name: &str) -> Option<DeviceModel>
Sourcepub fn get_all_models(&self) -> HashMap<String, DeviceModel>
pub fn get_all_models(&self) -> HashMap<String, DeviceModel>
Auto Trait Implementations§
impl Freeze for ModelMonitor
impl !RefUnwindSafe for ModelMonitor
impl Send for ModelMonitor
impl Sync for ModelMonitor
impl Unpin for ModelMonitor
impl UnsafeUnpin for ModelMonitor
impl !UnwindSafe for ModelMonitor
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