Trait cosmic::cosmic_config::CosmicConfigEntry

source ·
pub trait CosmicConfigEntry: Sized {
    const VERSION: u64;

    // Required methods
    fn write_entry(&self, config: &Config) -> Result<(), Error>;
    fn get_entry(config: &Config) -> Result<Self, (Vec<Error>, Self)>;
    fn update_keys<T>(
        &mut self,
        config: &Config,
        changed_keys: &[T],
    ) -> (Vec<Error>, Vec<&'static str>)
       where T: AsRef<str>;
}

Required Associated Constants§

Required Methods§

source

fn write_entry(&self, config: &Config) -> Result<(), Error>

source

fn get_entry(config: &Config) -> Result<Self, (Vec<Error>, Self)>

source

fn update_keys<T>( &mut self, config: &Config, changed_keys: &[T], ) -> (Vec<Error>, Vec<&'static str>)
where T: AsRef<str>,

Returns the keys that were updated

Object Safety§

This trait is not object safe.

Implementors§