Package com.ibm.fhir.search.location.uom
Class UOMManager
- java.lang.Object
-
- com.ibm.fhir.search.location.uom.UOMManager
-
public final class UOMManager extends Object
LocationUnit maps the unit of measure to a specific length (one meter).
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static DoubleconvertUnitsToKiloMeters(String unit, double value)Method to convert unit into kilometersstatic DoubleconvertUnitsToMeters(String unit, double value)Method to convert unit into metersstatic DoublegetUnitToMetersFactor(String unit)based on the unit abbreviation, returns the factor
-
-
-
Method Detail
-
getUnitToMetersFactor
public static final Double getUnitToMetersFactor(String unit)
based on the unit abbreviation, returns the factor- Parameters:
unit- the string representing the unit-of-measure abbreviation.- Returns:
- the factor if the factor exists, else null.
-
convertUnitsToMeters
public static Double convertUnitsToMeters(String unit, double value)
Method to convert unit into meters- Parameters:
unit-miles- distance in miles- Returns:
- distance in kilometers
-
-