pub struct CliSource { /* private fields */ }Expand description
Source backed by (key, value) pairs — parser-agnostic CLI bridge.
Any CLI parser (clap, pico-args, raw argv) produces (String, ConfigValue) pairs;
wrap them here to plug into ConfigLoader.
Trait Implementations§
Source§impl FromIterator<(String, ConfigValue)> for CliSource
impl FromIterator<(String, ConfigValue)> for CliSource
Source§fn from_iter<I: IntoIterator<Item = (String, ConfigValue)>>(iter: I) -> Self
fn from_iter<I: IntoIterator<Item = (String, ConfigValue)>>(iter: I) -> Self
Creates a value from an iterator. Read more
Source§impl Source for CliSource
impl Source for CliSource
Source§fn collect(&self) -> Result<ConfigValue, SourceError>
fn collect(&self) -> Result<ConfigValue, SourceError>
Collect config values from this source. Read more
Source§fn with_app_name(self, _name: &str) -> Selfwhere
Self: Sized,
fn with_app_name(self, _name: &str) -> Selfwhere
Self: Sized,
Inject the application name derived from
crate::config::ConfigSchema::APP_NAME. Read moreAuto Trait Implementations§
impl Freeze for CliSource
impl RefUnwindSafe for CliSource
impl Send for CliSource
impl Sync for CliSource
impl Unpin for CliSource
impl UnsafeUnpin for CliSource
impl UnwindSafe for CliSource
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more