ICU4X
International Components for Unicode
Loading...
Searching...
No Matches
ICU4XUnitsConverter Class Reference

#include <ICU4XUnitsConverter.hpp>

Public Member Functions

double convert_f64 (double value) const
 
ICU4XUnitsConverter clone () const
 
 ICU4XUnitsConverter (capi::ICU4XUnitsConverter *i)
 
 ICU4XUnitsConverter ()=default
 
 ICU4XUnitsConverter (ICU4XUnitsConverter &&) noexcept=default
 
ICU4XUnitsConverteroperator= (ICU4XUnitsConverter &&other) noexcept=default
 

Detailed Description

An ICU4X Units Converter object, capable of converting between two [ICU4XMeasureUnit]s.

You can create an instance of this object using [ICU4XUnitsConverterFactory] by calling the converter method.

See the Rust documentation for UnitsConverter for more information.

Constructor & Destructor Documentation

◆ ICU4XUnitsConverter() [1/3]

ICU4XUnitsConverter::ICU4XUnitsConverter ( capi::ICU4XUnitsConverter * i)
inlineexplicit

◆ ICU4XUnitsConverter() [2/3]

ICU4XUnitsConverter::ICU4XUnitsConverter ( )
default

◆ ICU4XUnitsConverter() [3/3]

ICU4XUnitsConverter::ICU4XUnitsConverter ( ICU4XUnitsConverter && )
defaultnoexcept

Member Function Documentation

◆ clone()

ICU4XUnitsConverter ICU4XUnitsConverter::clone ( ) const
inline

Clones the current [ICU4XUnitsConverter] object.

See the Rust documentation for clone for more information.

◆ convert_f64()

double ICU4XUnitsConverter::convert_f64 ( double value) const
inline

Converts the input value in float from the input unit to the output unit (that have been used to create this converter). NOTE: The conversion using floating-point operations is not as accurate as the conversion using ratios.

See the Rust documentation for convert for more information.

◆ operator=()

ICU4XUnitsConverter & ICU4XUnitsConverter::operator= ( ICU4XUnitsConverter && other)
defaultnoexcept

The documentation for this class was generated from the following file: