pub struct Config {
pub device: Option<String>,
pub format: Option<String>,
pub no_color: bool,
pub fahrenheit: bool,
pub inhg: bool,
pub bq: bool,
pub timeout: Option<u64>,
pub aliases: HashMap<String, String>,
pub last_device: Option<String>,
pub last_device_name: Option<String>,
pub behavior: BehaviorConfig,
pub gui: GuiConfig,
}Expand description
Configuration file structure
Fields§
§device: Option<String>Default device address
format: Option<String>Default output format
no_color: boolDisable colored output
fahrenheit: boolUse Fahrenheit for temperature
inhg: boolUse inHg for pressure (instead of hPa)
bq: boolUse Bq/m³ for radon (instead of pCi/L)
timeout: Option<u64>Connection timeout in seconds
aliases: HashMap<String, String>Device aliases (friendly name -> device address)
last_device: Option<String>Last successfully connected device (auto-updated)
last_device_name: Option<String>Name of the last connected device (for display)
behavior: BehaviorConfigBehavior settings for unified data architecture
gui: GuiConfigGUI-specific settings
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Config
impl<'de> Deserialize<'de> for Config
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnwindSafe for Config
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more