denki 0.2.0

CLI for controlling TP-Link smart home devices — denki (電気) means electricity in Japanese
Documentation
1
2
3
4
5
6
7
8
9
10
11
use async_trait::async_trait;
use tokio::sync::RwLockReadGuard;

use super::ApiClientExt;

/// Implemented by all device handlers.
#[async_trait]
pub trait HandlerExt: Send + Sync {
    /// Returns the client used by this handler.
    async fn get_client(&self) -> RwLockReadGuard<'_, dyn ApiClientExt>;
}