Skip to content

mp_units::quantity::numerical_value_in

Synopses

Declared in <mp-units/framework/quantity.h>

template<UnitOf<quantity_spec> U>
  requires detail::ImplicitScaling<unit, U{}, rep>
[[nodiscard]] constexpr RepresentationOf<quantity_spec> auto numerical_value_in(
  U) const noexcept;

» more...

template<RepresentationOf<quantity_spec> ToRep, UnitOf<quantity_spec> U>
  requires detail::RepConstructibleFrom<ToRep, rep> &&
           detail::ImplicitUnitChange<unit, rep, U{}, ToRep>
[[nodiscard]] constexpr RepresentationOf<quantity_spec> auto numerical_value_in(U) const;

» more...

template<UnitOf<quantity_spec> U,
         /* implementation-defined */ Policy>
  requires detail::UnitChangeCastable<unit, U{}, rep> &&
           detail::ValidRoundingPolicyFor<Policy, rep, rep>
[[nodiscard]] constexpr RepresentationOf<quantity_spec> auto numerical_value_in(
  U, Policy policy) const noexcept;

» more...

template<RepresentationOf<quantity_spec> ToRep, UnitOf<quantity_spec> U,
         /* implementation-defined */ Policy>
  requires std::constructible_from<ToRep, rep> &&
           detail::UnitChangeCastable<unit, U{}, ToRep> &&
           detail::ValidRoundingPolicyFor<Policy, rep, ToRep>
[[nodiscard]] constexpr RepresentationOf<quantity_spec> auto numerical_value_in(
  U, Policy policy) const;

» more...

Return Value

Note

The return value should not be discarded.