Skip to main content

SettingsStore

Trait SettingsStore 

Source
pub trait SettingsStore: Send + Sync {
    // Required methods
    fn repos(&self) -> Vec<RepoEntry>;
    fn set_repos(&self, by: &str, repos: &[RepoEntry]) -> Result<()>;
    fn legacy_config(&self) -> Option<String>;
    fn drop_legacy_config(&self) -> Result<()>;
    fn log_skip(&self) -> Option<String>;
    fn set_log_skip(&self, by: &str, skip: &str) -> Result<()>;
}
Expand description

The server’s own settings: the repositories it indexes.

Required Methods§

Source

fn repos(&self) -> Vec<RepoEntry>

Source

fn set_repos(&self, by: &str, repos: &[RepoEntry]) -> Result<()>

Source

fn legacy_config(&self) -> Option<String>

The config.toml an older server kept, until it has been moved over.

Source

fn drop_legacy_config(&self) -> Result<()>

Source

fn log_skip(&self) -> Option<String>

The kinds of log lines an admin switched off, comma-separated; None until one did.

Source

fn set_log_skip(&self, by: &str, skip: &str) -> Result<()>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§