pub struct NPVMetric(ProfitabilityIndex);Expand description
Net Present Value (NPV) metric
Tuple Fields§
§0: ProfitabilityIndexImplementations§
Source§impl NPVMetric
impl NPVMetric
Sourcepub fn new(profitability_index: ProfitabilityIndex) -> Self
pub fn new(profitability_index: ProfitabilityIndex) -> Self
Creates a new NPVMetric with the given profitability index.
Sourcefn is_zero_fixed_cost(&self) -> bool
fn is_zero_fixed_cost(&self) -> bool
Returns true if this metric represents a zero fixed cost case.
Trait Implementations§
Source§impl ComparableMetric for NPVMetric
impl ComparableMetric for NPVMetric
Source§fn compare(&self, other: &dyn ComparableMetric) -> Ordering
fn compare(&self, other: &dyn ComparableMetric) -> Ordering
Higher profitability index values indicate more profitable investments. When annual fixed cost is zero, the profitability index is infinite and total surplus is used for comparison instead.
impl MetricTrait for NPVMetric
NPVMetric implements the MetricTrait supertrait.
Auto Trait Implementations§
impl Freeze for NPVMetric
impl RefUnwindSafe for NPVMetric
impl Send for NPVMetric
impl Sync for NPVMetric
impl Unpin for NPVMetric
impl UnwindSafe for NPVMetric
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> 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