Struct follow_heating::io::devices::dummy::DummyActiveDevices
source · pub struct DummyActiveDevices {
active_devices: Mutex<Vec<Device>>,
rx: Mutex<Receiver<ActiveDevicesMessage>>,
}
Fields§
§active_devices: Mutex<Vec<Device>>
§rx: Mutex<Receiver<ActiveDevicesMessage>>
Implementations§
source§impl DummyActiveDevices
impl DummyActiveDevices
pub fn update_state(&mut self)
Trait Implementations§
source§impl ActiveDevices for DummyActiveDevices
impl ActiveDevices for DummyActiveDevices
source§fn get_active_devices(
&mut self,
_time: &DateTime<Utc>
) -> Result<Vec<Device>, BrainFailure>
fn get_active_devices( &mut self, _time: &DateTime<Utc> ) -> Result<Vec<Device>, BrainFailure>
Get all devices currently considered active.
source§fn get_active_devices_within(
&mut self,
time: &DateTime<Utc>,
_minutes: usize
) -> Result<Vec<Device>, BrainFailure>
fn get_active_devices_within( &mut self, time: &DateTime<Utc>, _minutes: usize ) -> Result<Vec<Device>, BrainFailure>
Get all devices that were active within the last x minutes.
source§impl DummyIO for DummyActiveDevices
impl DummyIO for DummyActiveDevices
type MessageType = ActiveDevicesMessage
type Config = ()
fn new(receiver: Receiver<Self::MessageType>, _config: &Self::Config) -> Self
fn create(config: &Self::Config) -> (Self, Sender<Self::MessageType>)where
Self: Sized,
Auto Trait Implementations§
impl RefUnwindSafe for DummyActiveDevices
impl Send for DummyActiveDevices
impl Sync for DummyActiveDevices
impl Unpin for DummyActiveDevices
impl UnwindSafe for DummyActiveDevices
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