8 #ifndef _UNITCONVERSION_H_
9 #define _UNITCONVERSION_H_
69 UNIT_METRES_PER_SECOND,
70 UNIT_KILOMETRES_PER_HOUR,
72 UNIT_METRES_PER_SECOND_SQUARED,
74 UNIT_MILLIGRAVITATION,
77 UNIT_RADIANS_PER_SECOND,
78 UNIT_DEGREES_PER_SECOND,
80 UNIT_DEGREE_FAHRENHEIT,
82 UNIT_USER_OFFSET = 1000
101 const cString& strUnitDestination =
"SI");
117 tUInt eUnitDestination = UNIT_SI);
unsigned int tUInt
type definition for unsigned integer value (platform and compiler dependent type).
double tFloat64
type definition for Float64 (64bit double values) (platform and compiler independent type).
A common result class usable as return value throughout.
Class for unit conversions.
tUInt GetUnitIdentifier(const cString &strUnit)
This method returns the handle of the unit corresponding to the input string.
tResult AddNewUnitString(tUInt eUnitIdentifier, const cString &strUnitString)
This method adds a new identifier string for a unit.
tUInt AddNewDerivedUnit(tUInt eUnitBase, tFloat64 fNumerator, tFloat64 fDenominator=1.0, tFloat64 fOffset=0.0)
This method adds a derived unit to the UnitConverter.
tResult Convert(tFloat64 *pf64Value, tUInt eUnitSource, tUInt eUnitDestination=UNIT_SI)
Unit Conversion.
tResult Convert(tFloat64 *pf64Value, const cString &strUnitSource, const cString &strUnitDestination="SI")
Unit Conversion.
tUInt AddNewBaseUnit()
This method adds a base unit to the UnitConverter and returns the created identifier handle.
#define A_UTILS_D(__pclassname_)
Helper macro for d-pattern definitions.
ADTF A_UTIL Namespace - Within adtf this is used as adtf::util or adtf_util.