pub trait PowerManager: Send + Sync {
// Required method
fn watch_battery(self: Arc<Self>) -> BoxStream<'static, (bool, WakeLease)>;
}Required Methods§
Sourcefn watch_battery(self: Arc<Self>) -> BoxStream<'static, (bool, WakeLease)>
fn watch_battery(self: Arc<Self>) -> BoxStream<'static, (bool, WakeLease)>
Returns a stream of battery status changes (true if using battery).