Module config

Source
Expand description

Configuration store helpers.

Structs§

ConfigFile
Wrapper for file-based ConfigLayer, providing convenient methods for modification.
ConfigFileSaveError
Error that can occur when saving config variables to file.
ConfigLayer
Set of configuration variables with source information.
ConfigMigrateError
Error that can occur when migrating config variables.
ConfigMigrationRule
Rule to migrate deprecated config variables.
ConfigNamePathBuf
Dotted config name path.
ConfigResolutionContext
Parameters to enable scoped config tables conditionally.
StackedConfig
Stack of configuration layers which can be merged as needed.

Enums§

ConfigGetError
Error that can occur when looking up config variable.
ConfigLoadError
Error that can occur when parsing or loading config variables.
ConfigMigrateLayerError
Inner error of ConfigMigrateError.
ConfigSource
Source of configuration variables in order of precedence.
ConfigUpdateError
Error that can occur when updating config variable.

Traits§

ConfigGetResultExt
Extension methods for Result<T, ConfigGetError>.
ToConfigNamePath
Value that can be converted to a dotted config name path.

Functions§

migrate
Applies migration rules to config. Returns descriptions of the applied migrations.
resolve
Evaluates condition for each layer and scope, flattens scoped tables. Returns new config that only contains enabled layers and tables.

Type Aliases§

ConfigItem
Config value or table node.
ConfigTable
Non-inline table of config key and value pairs.
ConfigTableLike
Non-inline or inline table of config key and value pairs.
ConfigValue
Generic config value.