Function omnisensor::dbus_helpers::props::prop_get_default_from
source · [−]pub fn prop_get_default_from<'a, I, T>(
map: &'a PropMap,
key: &str,
default: T
) -> Result<T, Box<dyn Error>>where
T: TryFrom<&'a I, Error = Box<dyn Error>>,
I: 'static,
Expand description
Like prop_get_optional_from()
, but eliminates the inner Option
by
returning a provided default if the key is absent.