pub struct LcomMetricSelection { /* private fields */ }Expand description
One selected LCOM formula ready for extraction and measurement.
Implementations§
Source§impl LcomMetricSelection
impl LcomMetricSelection
Sourcepub fn should_be_below(self, threshold: f64) -> MetricThresholdCondition<Self>
pub fn should_be_below(self, threshold: f64) -> MetricThresholdCondition<Self>
Requires every measured value to be strictly below threshold.
Sourcepub fn should_be_above(self, threshold: f64) -> MetricThresholdCondition<Self>
pub fn should_be_above(self, threshold: f64) -> MetricThresholdCondition<Self>
Requires every measured value to be strictly above threshold.
Sourcepub fn should_be(self, threshold: f64) -> MetricThresholdCondition<Self>
pub fn should_be(self, threshold: f64) -> MetricThresholdCondition<Self>
Requires every measured value to equal threshold exactly.
Sourcepub fn should_be_below_or_equal(
self,
threshold: f64,
) -> MetricThresholdCondition<Self>
pub fn should_be_below_or_equal( self, threshold: f64, ) -> MetricThresholdCondition<Self>
Requires every measured value to be below or equal to threshold.
Sourcepub fn should_be_above_or_equal(
self,
threshold: f64,
) -> MetricThresholdCondition<Self>
pub fn should_be_above_or_equal( self, threshold: f64, ) -> MetricThresholdCondition<Self>
Requires every measured value to be above or equal to threshold.
Sourcepub fn measure(&self) -> Result<Vec<MetricMeasurement>, ArchUnitError>
pub fn measure(&self) -> Result<Vec<MetricMeasurement>, ArchUnitError>
Extracts and measures eligible production-source structs.
Sourcepub fn measure_with(
&self,
check_options: &CheckOptions,
) -> Result<Vec<MetricMeasurement>, ArchUnitError>
pub fn measure_with( &self, check_options: &CheckOptions, ) -> Result<Vec<MetricMeasurement>, ArchUnitError>
Extracts and measures eligible structs with explicit source-target options.
Sourcepub const fn metric(&self) -> LcomMetric
pub const fn metric(&self) -> LcomMetric
Returns the selected LCOM formula.
Sourcepub fn should_satisfy<Predicate>(
self,
predicate: Predicate,
) -> MetricPredicateCondition<Self, Predicate>
pub fn should_satisfy<Predicate>( self, predicate: Predicate, ) -> MetricPredicateCondition<Self, Predicate>
Creates a reusable predicate over each value and complete type subject.
Trait Implementations§
Source§impl Clone for LcomMetricSelection
impl Clone for LcomMetricSelection
Source§fn clone(&self) -> LcomMetricSelection
fn clone(&self) -> LcomMetricSelection
Returns a copy 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 moreAuto Trait Implementations§
impl Freeze for LcomMetricSelection
impl RefUnwindSafe for LcomMetricSelection
impl Send for LcomMetricSelection
impl Sync for LcomMetricSelection
impl Unpin for LcomMetricSelection
impl UnwindSafe for LcomMetricSelection
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