#include <IfcUnitConverter.h>
A class that implements conversion of different units to the SI units.
Definition at line 43 of file IfcUnitConverter.h.
◆ appendUnit() [1/2]
| void OdIfcUnitConverter::appendUnit |
( |
const OdAnsiString & | unitType, |
|
|
const OdDAIObjectId & | unitId ) |
|
override |
Appends a new convertible unit.
- Parameters
-
| unitType | [in] A string that contains the type of the convertible unit. |
| unitId | [in] An identifier of the corresponding IfcConversionBasedUnit object. |
◆ appendUnit() [2/2]
| void OdIfcUnitConverter::appendUnit |
( |
const OdDAIObjectId & | unitId | ) |
|
|
override |
Appends a new convertible unit.
- Parameters
-
| unitId | [in] An identifier of the corresponding IfcConversionBasedUnit object. |
◆ clearUnits()
| void OdIfcUnitConverter::clearUnits |
( |
| ) |
|
|
override |
Removes all convertible units.
◆ convertToSIUnit()
| double OdIfcUnitConverter::convertToSIUnit |
( |
const OdAnsiString & | unitType, |
|
|
double | val ) const |
|
override |
Performs an attempt to convert a specified unit to the SI unit.
- Parameters
-
| unitType | [in] A string that contains the type of the unit to be converted. |
| val | [in] A unit value. |
- Returns
- A double value that contains the converted value of the specified unit type.
◆ getConversionUnitName()
| bool OdIfcUnitConverter::getConversionUnitName |
( |
const OdAnsiString & | unitType, |
|
|
OdAnsiString & | unitName, |
|
|
OdAnsiString & | unitPrefix ) |
|
override |
Gets name and prefix of convertion type.
- Parameters
-
| unitType | [in] A string that contains the type of the unit to be returned. |
| unitName | [out] A unit name. |
| unitPrefix | [out] A unit prefix name. If no prefix then the value is empty. |
- Returns
- True if the attributes are retrieved successfully, false otherwise.
◆ OdIfcFile
The documentation for this class was generated from the following file: