[−][src]Struct dbus_crossroads::PropContext
PropContext is a struct that provides helpful information inside a get/set property handler.
Like Context, but for get/set property handlers.
Implementations
impl PropContext
[src]
pub fn path(&self) -> &Path<'static>
[src]
The current object path.
pub fn interface(&self) -> &Interface<'static>
[src]
The current interface name.
pub fn name(&self) -> &str
[src]
The current property name.
pub fn message(&self) -> Option<&Message>
[src]
The message, if any, that caused this method to be called.
pub fn reply<A: Arg + RefArg + Send + Append + 'static>(
&mut self,
reply: Result<A, MethodErr>
) -> PhantomData<A>
[src]
&mut self,
reply: Result<A, MethodErr>
) -> PhantomData<A>
Set a reply to message (use in async context only)
Returns PhantomData just to aid the type system
pub fn reply_noemit(&mut self, reply: Result<(), MethodErr>)
[src]
Set a reply to a "set property" message (use in async context only)
This can be used when the property does not send a "EmitsChanged" signal.
pub fn check<R, F: FnOnce(Option<&mut Context>) -> Result<R, MethodErr>>(
&mut self,
f: F
) -> Result<R, ()>
[src]
&mut self,
f: F
) -> Result<R, ()>
Convenience method that sets an error reply if the closure returns an error.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for PropContext
impl Send for PropContext
impl !Sync for PropContext
impl Unpin for PropContext
impl !UnwindSafe for PropContext
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,