fractal::secret::linux

Function parse_attribute

Source
fn parse_attribute<F, V, E>(
    attributes: &HashMap<String, String>,
    key: &'static str,
    parse: F,
) -> Result<V, LinuxSecretFieldError>
where F: FnOnce(&str) -> Result<V, E>, E: Display,
Expand description

Parse the attribute with the given key, using the given parsing function in the given map.