Skip to main content

DynConfig

Trait DynConfig 

Source
pub trait DynConfig {
    // Required methods
    fn validate(&self) -> CoreResult<()>;
    fn architecture(&self) -> &'static str;
    fn as_any(&self) -> &dyn Any;
}
Expand description

A dyn-compatible version of Config trait for runtime usage

Required Methods§

Source

fn validate(&self) -> CoreResult<()>

Validates the configuration for correctness

Source

fn architecture(&self) -> &'static str

Returns the architecture name for this configuration

Source

fn as_any(&self) -> &dyn Any

Returns the configuration as Any for downcasting

Implementors§

Source§

impl<T: Config + 'static> DynConfig for T

Blanket implementation for any type that implements Config