pub trait CheckMutexAccessDurationTrait {
// Required methods
fn get_warn_lock(&self, key_opt: &Option<&AquariumSignal>) -> bool;
fn set_warn_lock(&mut self, key: &Option<&AquariumSignal>, value: bool);
fn get_max_mutex_access_duration(&self) -> Duration;
fn get_location(&self) -> &str;
// Provided method
fn check_mutex_access_duration(
&mut self,
key_opt: Option<&AquariumSignal>,
instant_after_locking_mutex: Instant,
instant_before_locking_mutex: Instant,
) { ... }
}Required Methods§
Sourcefn get_warn_lock(&self, key_opt: &Option<&AquariumSignal>) -> bool
fn get_warn_lock(&self, key_opt: &Option<&AquariumSignal>) -> bool
Reads the warn-lock. This flag is used to prevent log-flooding
Sourcefn set_warn_lock(&mut self, key: &Option<&AquariumSignal>, value: bool)
fn set_warn_lock(&mut self, key: &Option<&AquariumSignal>, value: bool)
Sets the warn-lock. This flag is used to prevent log-flooding
Sourcefn get_max_mutex_access_duration(&self) -> Duration
fn get_max_mutex_access_duration(&self) -> Duration
Provides the maximum permissible access duration
Sourcefn get_location(&self) -> &str
fn get_location(&self) -> &str
Inform the originator for logging purposes