Unpack() public method

Unpacks the given units, i.e. returns the representation of the unit in elementary units.
public Unpack ( ) : String
return String
Ejemplo n.º 1
0
        public static UnitValue DivUU(Value a, Value b)
        {
            var left  = (UnitValue)a;
            var right = (UnitValue)b;
            var unit  = new CombinedUnit(left.Unit).Divide(right.Unit).Simplify();

            return(new UnitValue(unit.Factor * left / right, unit.Unpack()));
        }
Ejemplo n.º 2
0
        static UnitValue MulUU(Value a, Value b)
        {
            var left  = (UnitValue)a;
            var right = (UnitValue)b;
            var unit  = new CombinedUnit(left.Unit).Multiply(right.Unit).Simplify();

            return(new UnitValue(unit.Factor * left * right, unit.Unpack()));
        }
Ejemplo n.º 3
0
 static UnitValue MulUU(Value a, Value b)
 {
     var left = (UnitValue)a;
     var right = (UnitValue)b;
     var unit = new CombinedUnit(left.Unit).Multiply(right.Unit).Simplify();
     return new UnitValue(unit.Factor * left * right, unit.Unpack());
 }
Ejemplo n.º 4
0
 static UnitValue DivUU(Value a, Value b)
 {
     var left = (UnitValue)a;
     var right = (UnitValue)b;
     var unit = new CombinedUnit(left.Unit).Divide(right.Unit).Simplify();
     return new UnitValue(unit.Factor * left / right, unit.Unpack());
 }