Struct dbus::tree::Property
[−]
[src]
pub struct Property<M> { // some fields omitted }
A D-Bus Property.
Methods
impl<M: MethodType> Property<M>
[src]
fn get_value(&self) -> MessageItem
Gets the value of the Property.
fn get_signal(&self) -> Option<Message>
Gets the signal (if any) associated with the Property.
fn set_value(&self, m: MessageItem) -> Result<Vec<Message>, ()>
Returns error if "emits" is "Const", and the property is in a tree. Returns messages to be sent over a connection, this could be the PropertiesChanged signal.
fn emits_changed(self, e: EmitsChangedSignal) -> Self
Builder method that allows setting the Property's signal behavior when changed.
fn access(self, e: Access) -> Self
Builder method that allows setting the Property as readable, writable, or both.
fn remote_get(&self, _: &Message) -> Result<MessageItem, MethodErr>
Helper method to check accessibility before getting a value.
fn verify_remote_set(&self, m: &Message) -> Result<MessageItem, MethodErr>
Helper method to verify and extract a MessageItem from a Set message
fn annotate<N: Into<String>, V: Into<String>>(self, name: N, value: V) -> Self
Add an annotation to this Property.
fn deprecated(self) -> Self
Add an annotation that this entity is deprecated.
impl Property<MethodSync>
[src]
fn on_set<H>(self, m: H) -> Self where H: Fn(&Message, &ObjectPath<MethodSync>, &Tree<MethodSync>) -> MethodResult + Send + Sync + 'static
Sets a callback to be called when a "Set" call is coming in from the remote side. Might change to something more ergonomic. For multi-thread use.
impl<'a> Property<MethodFn<'a>>
[src]
fn on_set<H: 'a>(self, m: H) -> Self where H: Fn(&Message, &ObjectPath<MethodFn<'a>>, &Tree<MethodFn<'a>>) -> MethodResult
Sets a callback to be called when a "Set" call is coming in from the remote side. Might change to something more ergonomic. For single-thread use.
impl<'a> Property<MethodFnMut<'a>>
[src]
fn on_set<H: 'a>(self, m: H) -> Self where H: FnMut(&Message, &ObjectPath<MethodFnMut<'a>>, &Tree<MethodFnMut<'a>>) -> MethodResult
Sets a callback to be called when a "Set" call is coming in from the remote side. Might change to something more ergonomic. For single-thread use.