pub struct SleepConfig {
pub cycle_duration_hours: f64,
pub cycles_per_night: usize,
pub wake_threshold: f64,
pub pressure_decay_rate: f64,
pub pressure_build_rate: f64,
pub rem_rebound_factor: f64,
}Expand description
Configuration for sleep system
Fields§
§cycle_duration_hours: f64Target sleep duration per cycle (hours)
cycles_per_night: usizeNumber of sleep cycles per night
wake_threshold: f64Wake threshold (accumulated pressure needed to wake)
pressure_decay_rate: f64Sleep pressure decay during sleep
pressure_build_rate: f64Sleep pressure build during wake
rem_rebound_factor: f64REM proportion increases through night
Trait Implementations§
Source§impl Clone for SleepConfig
impl Clone for SleepConfig
Source§fn clone(&self) -> SleepConfig
fn clone(&self) -> SleepConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SleepConfig
impl Debug for SleepConfig
Source§impl Default for SleepConfig
impl Default for SleepConfig
Source§impl<'de> Deserialize<'de> for SleepConfig
impl<'de> Deserialize<'de> for SleepConfig
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 SleepConfig
impl RefUnwindSafe for SleepConfig
impl Send for SleepConfig
impl Sync for SleepConfig
impl Unpin for SleepConfig
impl UnwindSafe for SleepConfig
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