Base::UnitsSchemaMKS Class Reference

The UnitSchema class. More...

#include <UnitsSchemaMKS.h>

Inheritance diagram for Base::UnitsSchemaMKS:
Base::UnitsSchema

List of all members.

Public Member Functions

void setSchemaUnits (void)
 if called set all the units of the units schema
QString toStrWithUserPrefs (QuantityType t, double Value)
 return one string with the formated value/unit pair.
void toStrWithUserPrefs (QuantityType t, double Value, QString &outValue, QString &outUnit)
 return the value and the unit as string

Detailed Description

The UnitSchema class.

Definition at line 38 of file UnitsSchemaMKS.h.


Member Function Documentation

void UnitsSchemaMKS::setSchemaUnits ( void   )  [virtual]

if called set all the units of the units schema

Implements Base::UnitsSchema.

Definition at line 37 of file UnitsSchemaMKS.cpp.

References Base::Acceleration, Base::Angle, Base::Area, Base::Length, Base::Mass, Base::UnitsApi::setPrefOf(), Base::Temperature, Base::TimeSpan, Base::Velocity, and Base::Volume.

QString UnitsSchemaMKS::toStrWithUserPrefs ( QuantityType  t,
double  Value 
) [virtual]

return one string with the formated value/unit pair.

The designer of the unit schema can decide how he wants the value presented. Only rule is its still parseble by the units parser.

Implements Base::UnitsSchema.

Definition at line 59 of file UnitsSchemaMKS.cpp.

References Base::UnitsApi::getPrefFactorOf(), and Base::UnitsApi::getPrefUnitOf().

void UnitsSchemaMKS::toStrWithUserPrefs ( QuantityType  t,
double  Value,
QString &  outValue,
QString &  outUnit 
) [virtual]

return the value and the unit as string

Implements Base::UnitsSchema.

Definition at line 51 of file UnitsSchemaMKS.cpp.

References Base::UnitsApi::getPrefFactorOf(), and Base::UnitsApi::getPrefUnitOf().


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

Generated on Wed Nov 23 19:01:48 2011 for FreeCAD by  doxygen 1.6.1