Retrieves the Unit of Measure that is identified with a given name.
The name that identifies the Unit of Measure being requested.
The requested Unit Of measure
Register a non-standard unit-of-measure, with given conversion factors and offsets, to be able to map to the standard unit-of-measure for that specific quantity kind.
var yardUOM = UnitOfMeasureRegistry.registerConversionUnit("Yard", "yd", "Length", 0.9144, 0);
The symbol of the UnitOfMeasure
The name of the QuantityKind of this UnitOfMeasure. A QuantityKind with this name MUST exist in the QuantityKindRegistry.
The conversion multiplier (Number) of the UnitOfMeasure
The conversion offset of the UnitOfMeasure
the registered UnitOfMeasure
Register a new unit of measure that acts as a standard for a quantity kind. All non-standard unit of measures of the same quantity kind will map to this standard unit of measure.
var squareMeterUOM = UnitOfMeasureRegistry.registerStandardUnit("SquareMeter", "m2", "Area");
var acreUOM = UnitOfMeasureRegistry.registerConversionUnit("Acre", "ac", "Area", 4046.68, 0);
The symbol of the UnitOfMeasure
The name of the QuantityKind of this UnitOfMeasure. A QuantityKind with this name MUST exist in the QuantityKindRegistry.
the registered UnitOfMeasure
A registry that maintains the known UnitOfMeasure.
Two possible Units of Measure exist
You can specify new UnitOfMeasure using the respective register methods (registerStandardUnit and registerConversionUnit).