Beispiel #1
0
 public double GetValue(Unit unit)
 {
     ConfirmUnitMatch(Unit, unit);
     return(unit.FromSI(Unit.ToSI(Number)));
 }
Beispiel #2
0
 public void SetUnit(Unit unit)
 {
     ConfirmUnitMatch(Unit, unit);
     Unit = unit.Clone();
 }
Beispiel #3
0
 public void SetValue(double value, Unit unit)
 {
     Unit     = unit.Clone();
     _siValue = Unit.ToSI(value);
 }
Beispiel #4
0
 public UnitNumber(double value, Unit unit)
 {
     SetValue(value, unit);
 }