pub trait ApplyFlatEnv {
// Required method
fn apply_flat_env(&mut self, prefix: &str);
// Provided method
fn env_var_docs(prefix: &str) -> Vec<EnvVarDoc>
where Self: Sized { ... }
}Expand description
Trait for flat environment variable override application.
Implemented by the #[derive(FlatEnvOverrides)] macro, or manually.
Each implementation reads {prefix}_{FIELD_NAME} env vars and applies
them to the struct fields, overriding values from YAML/figment.
Required Methods§
Sourcefn apply_flat_env(&mut self, prefix: &str)
fn apply_flat_env(&mut self, prefix: &str)
Apply flat environment variable overrides to this config struct.
The prefix is prepended to each field’s suffix to form the full
env var name. For nested structs marked with #[env_section], the
field name is appended to the prefix before recursing.