UnitConversionService
trait · ferroui-protranslate-core · v0.5.0
trait UnitConversionService
Members
get_category
fn get_category(self: &Self, unit: MeasurementUnit) -> MeasurementUnitCategory
convert
fn convert(self: &Self, value: f64, from: MeasurementUnit, to: MeasurementUnit) -> Result<f64, TranslationError>
convert_to_profile
fn convert_to_profile(self: &Self, value: f64, from: MeasurementUnit, profile: &MeasurementSystemProfile) -> Result<MeasurementValue, TranslationError>
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.