pub trait ConfigDefaultsProvider: Send + Sync {
// Required methods
fn workspace_paths_for(
&self,
workspace_root: &Path,
) -> Box<dyn WorkspacePaths>;
fn home_config_paths(&self, config_file_name: &str) -> Vec<PathBuf>;
fn syntax_theme(&self) -> String;
fn syntax_languages(&self) -> Vec<String>;
// Provided method
fn config_file_name(&self) -> &str { ... }
}Expand description
Provides access to filesystem and syntax defaults used by the configuration loader.
Required Methods§
Sourcefn workspace_paths_for(&self, workspace_root: &Path) -> Box<dyn WorkspacePaths>
fn workspace_paths_for(&self, workspace_root: &Path) -> Box<dyn WorkspacePaths>
Creates a WorkspacePaths implementation for the provided workspace
root.
Sourcefn home_config_paths(&self, config_file_name: &str) -> Vec<PathBuf>
fn home_config_paths(&self, config_file_name: &str) -> Vec<PathBuf>
Returns the fallback configuration locations searched outside the workspace.
Sourcefn syntax_theme(&self) -> String
fn syntax_theme(&self) -> String
Returns the default syntax highlighting theme identifier.
Sourcefn syntax_languages(&self) -> Vec<String>
fn syntax_languages(&self) -> Vec<String>
Returns the default list of syntax highlighting languages.
Provided Methods§
Sourcefn config_file_name(&self) -> &str
fn config_file_name(&self) -> &str
Returns the primary configuration file name expected in a workspace.