Struct i3status_rs::blocks::service_status::UnitProxy
source · pub struct UnitProxy<'p>(/* private fields */);
Implementations§
source§impl<'p> UnitProxy<'p>
impl<'p> UnitProxy<'p>
sourcepub async fn new<P>(conn: &Connection, path: P) -> Result<UnitProxy<'p>>
pub async fn new<P>(conn: &Connection, path: P) -> Result<UnitProxy<'p>>
Creates a new proxy with the given path, and the default destination.
sourcepub fn builder(conn: &Connection) -> Builder<'p, Self>
pub fn builder(conn: &Connection) -> Builder<'p, Self>
Returns a customizable builder for this proxy.
sourcepub fn into_inner(self) -> Proxy<'p>
pub fn into_inner(self) -> Proxy<'p>
Consumes self
, returning the underlying zbus::Proxy
.
sourcepub fn inner_mut(&mut self) -> &mut Proxy<'p>
pub fn inner_mut(&mut self) -> &mut Proxy<'p>
The mutable reference to the underlying zbus::Proxy
.
pub async fn active_state(&self) -> Result<String>
sourcepub fn cached_active_state(
&self
) -> Result<Option<<Result<String> as ResultAdapter>::Ok>, <Result<String> as ResultAdapter>::Err>
pub fn cached_active_state( &self ) -> Result<Option<<Result<String> as ResultAdapter>::Ok>, <Result<String> as ResultAdapter>::Err>
Get the cached value of the ActiveState
property, or None
if the property is not cached.
sourcepub async fn receive_active_state_changed(
&self
) -> PropertyStream<'p, <Result<String> as ResultAdapter>::Ok>
pub async fn receive_active_state_changed( &self ) -> PropertyStream<'p, <Result<String> as ResultAdapter>::Ok>
Create a stream for the ActiveState
property changes. This is a convenient wrapper around [zbus::Proxy::receive_property_changed
].
Trait Implementations§
Auto Trait Implementations§
impl<'p> Freeze for UnitProxy<'p>
impl<'p> !RefUnwindSafe for UnitProxy<'p>
impl<'p> Send for UnitProxy<'p>
impl<'p> Sync for UnitProxy<'p>
impl<'p> Unpin for UnitProxy<'p>
impl<'p> !UnwindSafe for UnitProxy<'p>
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
§impl<T> DynamicType for Twhere
T: Type + ?Sized,
impl<T> DynamicType for Twhere
T: Type + ?Sized,
§fn dynamic_signature(&self) -> Signature<'_>
fn dynamic_signature(&self) -> Signature<'_>
Get the signature for the implementing type. Read more