#[non_exhaustive]pub struct PerformanceThreshold {
pub threshold: f64,
pub type: Option<Type>,
/* private fields */
}Expand description
A PerformanceThreshold is used when each window is good when that window
has a sufficiently high performance.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.threshold: f64If window performance >= threshold, the window is counted as good.
type: Option<Type>The means, either a request-based SLI or a basic SLI, by which to compute performance over a window.
Implementations§
Source§impl PerformanceThreshold
impl PerformanceThreshold
pub fn new() -> Self
Sourcepub fn set_threshold<T: Into<f64>>(self, v: T) -> Self
pub fn set_threshold<T: Into<f64>>(self, v: T) -> Self
Sets the value of threshold.
Sourcepub fn set_type<T: Into<Option<Type>>>(self, v: T) -> Self
pub fn set_type<T: Into<Option<Type>>>(self, v: T) -> Self
Sets the value of r#type.
Note that all the setters affecting r#type are mutually
exclusive.
Sourcepub fn performance(&self) -> Option<&Box<RequestBasedSli>>
pub fn performance(&self) -> Option<&Box<RequestBasedSli>>
The value of [r#type][crate::model::windows_based_sli::PerformanceThreshold::r#type]
if it holds a Performance, None if the field is not set or
holds a different branch.
Sourcepub fn set_performance<T: Into<Box<RequestBasedSli>>>(self, v: T) -> Self
pub fn set_performance<T: Into<Box<RequestBasedSli>>>(self, v: T) -> Self
Sets the value of [r#type][crate::model::windows_based_sli::PerformanceThreshold::r#type]
to hold a Performance.
Note that all the setters affecting r#type are
mutually exclusive.
Sourcepub fn basic_sli_performance(&self) -> Option<&Box<BasicSli>>
pub fn basic_sli_performance(&self) -> Option<&Box<BasicSli>>
The value of [r#type][crate::model::windows_based_sli::PerformanceThreshold::r#type]
if it holds a BasicSliPerformance, None if the field is not set or
holds a different branch.
Sourcepub fn set_basic_sli_performance<T: Into<Box<BasicSli>>>(self, v: T) -> Self
pub fn set_basic_sli_performance<T: Into<Box<BasicSli>>>(self, v: T) -> Self
Sets the value of [r#type][crate::model::windows_based_sli::PerformanceThreshold::r#type]
to hold a BasicSliPerformance.
Note that all the setters affecting r#type are
mutually exclusive.
Trait Implementations§
Source§impl Clone for PerformanceThreshold
impl Clone for PerformanceThreshold
Source§fn clone(&self) -> PerformanceThreshold
fn clone(&self) -> PerformanceThreshold
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more