Exemplo n.º 1
0
 public ScaleBuilder(UnitConfiguration config, UnitMeta rootUnit)
 {
     this.config   = config;
     precedingUnit = rootUnit;
     if (rootUnit.PhysicalUnit.IsDimensionless())
     {
         throw new InvalidOperationException("The unit you start with should be associated with a physical unit to start a scale.");
     }
 }
Exemplo n.º 2
0
 internal UnitConfiguration()
 {
     UnitSystem        = this;
     _defaultPrecision = 10;
 }
Exemplo n.º 3
0
 internal UnitMeta(Unit unit, UnitConfiguration config)
 {
     this.unit   = unit;
     this.config = config;
     config.UnitGraph.AddUnit(unit);
 }