pub struct SmartPlug { /* private fields */ }
Implementations§
Source§impl SmartPlug
impl SmartPlug
pub fn new(ip: &'static str) -> SmartPlug
pub fn on(&self) -> Result<PlugInfo, Error>
pub fn off(&self) -> Result<PlugInfo, Error>
pub fn sysinfo(&self) -> Result<PlugInfo, Error>
pub fn meterinfo(&self) -> Result<PlugInfo, Error>
pub fn dailystats(&self, month: i32, year: i32) -> Result<PlugInfo, Error>
Auto Trait Implementations§
impl Freeze for SmartPlug
impl RefUnwindSafe for SmartPlug
impl Send for SmartPlug
impl Sync for SmartPlug
impl Unpin for SmartPlug
impl UnwindSafe for SmartPlug
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