pub struct PrefixConfig {
pub mappings: HashMap<String, Vec<String>>,
pub candidate_prefixes: Vec<Vec<String>>,
pub learn_on_successful_fallback: bool,
}Expand description
Mirrors the ~/.config/rx/prefixes.toml schema.
Fields§
§mappings: HashMap<String, Vec<String>>Definite mappings: command (or “cmd sub”) → prefix argv.
candidate_prefixes: Vec<Vec<String>>Candidate prefixes to try when no mapping exists.
learn_on_successful_fallback: boolWhether to persist a successful candidate as a confirmed mapping.
Trait Implementations§
Source§impl Clone for PrefixConfig
impl Clone for PrefixConfig
Source§fn clone(&self) -> PrefixConfig
fn clone(&self) -> PrefixConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PrefixConfig
impl Debug for PrefixConfig
Source§impl Default for PrefixConfig
impl Default for PrefixConfig
Source§fn default() -> PrefixConfig
fn default() -> PrefixConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PrefixConfig
impl<'de> Deserialize<'de> for PrefixConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for PrefixConfig
impl RefUnwindSafe for PrefixConfig
impl Send for PrefixConfig
impl Sync for PrefixConfig
impl Unpin for PrefixConfig
impl UnsafeUnpin for PrefixConfig
impl UnwindSafe for PrefixConfig
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