2 * Copyright (c) 2010-2023 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.bluetooth.generic.internal;
15 import java.math.BigInteger;
16 import java.util.UUID;
18 import javax.measure.Quantity;
19 import javax.measure.Unit;
20 import javax.measure.quantity.Angle;
21 import javax.measure.quantity.Area;
22 import javax.measure.quantity.Dimensionless;
23 import javax.measure.quantity.ElectricCharge;
24 import javax.measure.quantity.Frequency;
25 import javax.measure.quantity.Length;
26 import javax.measure.quantity.Mass;
27 import javax.measure.quantity.Speed;
29 import org.eclipse.jdt.annotation.NonNullByDefault;
30 import org.eclipse.jdt.annotation.Nullable;
31 import org.openhab.binding.bluetooth.BluetoothBindingConstants;
32 import org.openhab.core.library.dimension.ArealDensity;
33 import org.openhab.core.library.dimension.VolumetricFlowRate;
34 import org.openhab.core.library.unit.ImperialUnits;
35 import org.openhab.core.library.unit.MetricPrefix;
36 import org.openhab.core.library.unit.SIUnits;
37 import org.openhab.core.library.unit.Units;
39 import tech.units.indriya.format.SimpleUnitFormat;
40 import tech.units.indriya.function.MultiplyConverter;
41 import tech.units.indriya.unit.ProductUnit;
42 import tech.units.indriya.unit.TransformedUnit;
45 * The {@link BluetoothUnit} maps bluetooth units to openHAB units.
47 * @author Connor Petty - Initial contribution
50 public enum BluetoothUnit {
52 UNITLESS(0x2700, "org.bluetooth.unit.unitless", Units.ONE),
53 METRE(0x2701, "org.bluetooth.unit.length.metre", SIUnits.METRE),
54 KILOGRAM(0x2702, "org.bluetooth.unit.mass.kilogram", SIUnits.KILOGRAM),
55 SECOND(0x2703, "org.bluetooth.unit.time.second", Units.SECOND),
56 AMPERE(0x2704, "org.bluetooth.unit.electric_current.ampere", Units.AMPERE),
57 KELVIN(0x2705, "org.bluetooth.unit.thermodynamic_temperature.kelvin", Units.KELVIN),
58 MOLE(0x2706, "org.bluetooth.unit.amount_of_substance.mole", Units.MOLE),
59 CANDELA(0x2707, "org.bluetooth.unit.luminous_intensity.candela", Units.CANDELA),
60 SQUARE_METRES(0x2710, "org.bluetooth.unit.area.square_metres", SIUnits.SQUARE_METRE),
61 CUBIC_METRES(0x2711, "org.bluetooth.unit.volume.cubic_metres", SIUnits.CUBIC_METRE),
62 METRE_PER_SECOND(0x2712, "org.bluetooth.unit.velocity.metres_per_second", Units.METRE_PER_SECOND),
63 METRE_PER_SQUARE_SECOND(0X2713, "org.bluetooth.unit.acceleration.metres_per_second_squared",
64 Units.METRE_PER_SQUARE_SECOND),
65 WAVENUMBER(0x2714, "org.bluetooth.unit.wavenumber.reciprocal_metre", Units.ONE),
66 KILOGRAM_PER_CUBIC_METRE(0x2715, "org.bluetooth.unit.density.kilogram_per_cubic_metre",
67 Units.KILOGRAM_PER_CUBICMETRE),
68 KILOGRAM_PER_SQUARE_METRE(0x2716, "org.bluetooth.unit.surface_density.kilogram_per_square_metre",
69 BUnits.KILOGRAM_PER_SQUARE_METER),
70 CUBIC_METRE_PER_KILOGRAM(0x2717, "org.bluetooth.unit.specific_volume.cubic_metre_per_kilogram", Units.ONE),
71 AMPERE_PER_SQUARE_METRE(0x2718, "org.bluetooth.unit.current_density.ampere_per_square_metre", Units.ONE),
72 AMPERE_PER_METRE(0x2719, "org.bluetooth.unit.magnetic_field_strength.ampere_per_metre", Units.ONE),
73 MOLE_PER_CUBIC_METRE(0x271A, "org.bluetooth.unit.amount_concentration.mole_per_cubic_metre", Units.ONE),
74 CONCENTRATION_KILOGRAM_PER_CUBIC_METRE(0x271B, "org.bluetooth.unit.mass_concentration.kilogram_per_cubic_metre",
75 Units.KILOGRAM_PER_CUBICMETRE),
76 CANDELA_PER_SQUARE_METRE(0x271C, "org.bluetooth.unit.luminance.candela_per_square_metre", Units.ONE),
77 REFRACTIVE_INDEX(0x271D, "org.bluetooth.unit.refractive_index", Units.ONE),
78 RELATIVE_PERMEABILITY(0x271E, "org.bluetooth.unit.relative_permeability", Units.ONE),
79 RADIAN(0x2720, "org.bluetooth.unit.plane_angle.radian", Units.RADIAN),
80 STERADIAN(0x2721, "org.bluetooth.unit.solid_angle.steradian", Units.STERADIAN),
81 HERTZ(0x2722, "org.bluetooth.unit.frequency.hertz", Units.HERTZ),
82 NEWTON(0x2723, "org.bluetooth.unit.force.newton", Units.NEWTON),
83 PASCAL(0x2724, "org.bluetooth.unit.pressure.pascal", SIUnits.PASCAL),
84 JOULE(0x2725, "org.bluetooth.unit.energy.joule", Units.JOULE),
85 WATT(0x2726, "org.bluetooth.unit.power.watt", Units.WATT),
86 COULOMB(0x2727, "org.bluetooth.unit.electric_charge.coulomb", Units.COULOMB),
87 VOLT(0x2728, "org.bluetooth.unit.electric_potential_difference.volt", Units.VOLT),
88 FARAD(0x2729, "org.bluetooth.unit.capacitance.farad", Units.FARAD),
89 OHM(0x272A, "org.bluetooth.unit.electric_resistance.ohm", Units.OHM),
90 SIEMENS(0x272B, "org.bluetooth.unit.electric_conductance.siemens", Units.SIEMENS),
91 WEBER(0x272C, "org.bluetooth.unit.magnetic_flux.weber", Units.WEBER),
92 TESLA(0x272D, "org.bluetooth.unit.magnetic_flux_density.tesla", Units.TESLA),
93 HENRY(0x272E, "org.bluetooth.unit.inductance.henry", Units.HENRY),
94 DEGREE_CELSIUS(0x272F, "org.bluetooth.unit.thermodynamic_temperature.degree_celsius", SIUnits.CELSIUS),
95 LUMEN(0x2730, "org.bluetooth.unit.luminous_flux.lumen", Units.LUMEN),
96 LUX(0x2731, "org.bluetooth.unit.illuminance.lux", Units.LUX),
97 BECQUEREL(0x2732, "org.bluetooth.unit.activity_referred_to_a_radionuclide.becquerel", Units.BECQUEREL),
98 GRAY(0x2733, "org.bluetooth.unit.absorbed_dose.gray", Units.GRAY),
99 SIEVERT(0x2734, "org.bluetooth.unit.dose_equivalent.sievert", Units.SIEVERT),
100 KATAL(0x2735, "org.bluetooth.unit.catalytic_activity.katal", Units.KATAL),
101 PASCAL_SECOND(0x2740, "org.bluetooth.unit.dynamic_viscosity.pascal_second", Units.ONE),
102 NEWTON_METRE(0x2741, "org.bluetooth.unit.moment_of_force.newton_metre", Units.ONE),
103 NEWTON_PER_METRE(0x2742, "org.bluetooth.unit.surface_tension.newton_per_metre", Units.ONE),
104 RADIAN_PER_SECOND(0x2743, "org.bluetooth.unit.angular_velocity.radian_per_second", Units.ONE),
105 RADIAN_PER_SECOND_SQUARED(0x2744, "org.bluetooth.unit.angular_acceleration.radian_per_second_squared", Units.ONE),
106 FLUX_WATT_PER_SQUARE_METRE(0x2745, "org.bluetooth.unit.heat_flux_density.watt_per_square_metre", Units.ONE),
107 JOULE_PER_KELVIN(0x2746, "org.bluetooth.unit.heat_capacity.joule_per_kelvin", Units.ONE),
108 JOULE_PER_KILOGRAM_KELVIN(0x2747, "org.bluetooth.unit.specific_heat_capacity.joule_per_kilogram_kelvin", Units.ONE),
109 JOULE_PER_KILOGRAM(0x2748, "org.bluetooth.unit.specific_energy.joule_per_kilogram", Units.ONE),
110 WATT_PER_METRE_KELVIN(0x2749, "org.bluetooth.unit.thermal_conductivity.watt_per_metre_kelvin", Units.ONE),
111 JOULE_PER_CUBIC_METRE(0x274A, "org.bluetooth.unit.energy_density.joule_per_cubic_metre", Units.ONE),
112 VOLT_PER_METRE(0x274B, "org.bluetooth.unit.electric_field_strength.volt_per_metre", Units.ONE),
113 CHARGE_DENSITY_COULOMB_PER_CUBIC_METRE(0x274C, "org.bluetooth.unit.electric_charge_density.coulomb_per_cubic_metre",
115 CHARGE_DENSITY_COULOMB_PER_SQUARE_METRE(0x274D,
116 "org.bluetooth.unit.surface_charge_density.coulomb_per_square_metre", Units.ONE),
117 FLUX_DENSITY_COULOMB_PER_SQUARE_METRE(0x274E, "org.bluetooth.unit.electric_flux_density.coulomb_per_square_metre",
119 FARAD_PER_METRE(0x274F, "org.bluetooth.unit.permittivity.farad_per_metre", Units.ONE),
120 HENRY_PER_METRE(0x2750, "org.bluetooth.unit.permeability.henry_per_metre", Units.ONE),
121 JOULE_PER_MOLE(0x2751, "org.bluetooth.unit.molar_energy.joule_per_mole", Units.ONE),
122 JOULE_PER_MOLE_KELVIN(0x2752, "org.bluetooth.unit.molar_entropy.joule_per_mole_kelvin", Units.ONE),
123 COULOMB_PER_KILOGRAM(0x2753, "org.bluetooth.unit.exposure.coulomb_per_kilogram", Units.ONE),
124 GRAY_PER_SECOND(0x2754, "org.bluetooth.unit.absorbed_dose_rate.gray_per_second", BUnits.GRAY_PER_SECOND),
125 WATT_PER_STERADIAN(0x2755, "org.bluetooth.unit.radiant_intensity.watt_per_steradian", BUnits.WATT_PER_STERADIAN),
126 WATT_PER_STERADIAN_PER_SQUARE_METRE(0x2756, "org.bluetooth.unit.radiance.watt_per_square_metre_steradian",
127 BUnits.WATT_PER_STERADIAN_PER_SQUARE_METRE),
128 KATAL_PER_CUBIC_METRE(0x2757, "org.bluetooth.unit.catalytic_activity_concentration.katal_per_cubic_metre",
130 MINUTE(0x2760, "org.bluetooth.unit.time.minute", Units.MINUTE),
131 HOUR(0x2761, "org.bluetooth.unit.time.hour", Units.HOUR),
132 DAY(0x2762, "org.bluetooth.unit.time.day", Units.DAY),
133 ANGLE_DEGREE(0x2763, "org.bluetooth.unit.plane_angle.degree", Units.DEGREE_ANGLE),
134 ANGLE_MINUTE(0x2764, "org.bluetooth.unit.plane_angle.minute", BUnits.MINUTE_ANGLE),
135 ANGLE_SECOND(0x2765, "org.bluetooth.unit.plane_angle.second", BUnits.SECOND_ANGLE),
136 HECTARE(0x2766, "org.bluetooth.unit.area.hectare", BUnits.HECTARE),
137 LITRE(0x2767, "org.bluetooth.unit.volume.litre", Units.LITRE),
138 TONNE(0x2768, "org.bluetooth.unit.mass.tonne", MetricPrefix.KILO(SIUnits.KILOGRAM)),
139 BAR(0x2780, "org.bluetooth.unit.pressure.bar", Units.BAR),
140 MILLIMETRE_OF_MERCURY(0x2781, "org.bluetooth.unit.pressure.millimetre_of_mercury", Units.MILLIMETRE_OF_MERCURY),
141 ÅNGSTRÖM(0x2782, "org.bluetooth.unit.length.ångström", Units.ONE),
142 NAUTICAL_MILE(0x2783, "org.bluetooth.unit.length.nautical_mile", BUnits.NAUTICAL_MILE),
143 BARN(0x2784, "org.bluetooth.unit.area.barn", BUnits.BARN),
144 KNOT(0x2785, "org.bluetooth.unit.velocity.knot", Units.KNOT),
145 NEPER(0x2786, "org.bluetooth.unit.logarithmic_radio_quantity.neper", Units.ONE),
146 BEL(0x2787, "org.bluetooth.unit.logarithmic_radio_quantity.bel", Units.ONE),
147 YARD(0x27A0, "org.bluetooth.unit.length.yard", ImperialUnits.YARD),
148 PARSEC(0x27A1, "org.bluetooth.unit.length.parsec", Units.ONE),
149 INCH(0x27A2, "org.bluetooth.unit.length.inch", ImperialUnits.INCH),
150 FOOT(0x27A3, "org.bluetooth.unit.length.foot", ImperialUnits.FOOT),
151 MILE(0x27A4, "org.bluetooth.unit.length.mile", ImperialUnits.MILE),
152 POUND_FORCE_PER_SQUARE_INCH(0x27A5, "org.bluetooth.unit.pressure.pound_force_per_square_inch", Units.ONE),
153 KILOMETRE_PER_HOUR(0x27A6, "org.bluetooth.unit.velocity.kilometre_per_hour", SIUnits.KILOMETRE_PER_HOUR),
154 MILES_PER_HOUR(0x27A7, "org.bluetooth.unit.velocity.mile_per_hour", ImperialUnits.MILES_PER_HOUR),
155 REVOLUTION_PER_MINUTE(0x27A8, "org.bluetooth.unit.angular_velocity.revolution_per_minute",
156 BUnits.REVOLUTION_PER_MINUTE),
157 GRAM_CALORIE(0x27A9, "org.bluetooth.unit.energy.gram_calorie", Units.ONE),
158 KILOGRAM_CALORIE(0x27AA, "org.bluetooth.unit.energy.kilogram_calorie", Units.ONE),
159 KILOWATT_HOUR(0x27AB, "org.bluetooth.unit.energy.kilowatt_hour", Units.KILOWATT_HOUR),
160 DEGREE_FAHRENHEIT(0x27AC, "org.bluetooth.unit.thermodynamic_temperature.degree_fahrenheit",
161 ImperialUnits.FAHRENHEIT),
162 PERCENTAGE(0x27AD, "org.bluetooth.unit.percentage", Units.PERCENT),
163 PER_MILLE(0x27AE, "org.bluetooth.unit.per_mille", Units.ONE),
164 BEATS_PER_MINUTE(0x27AF, "org.bluetooth.unit.period.beats_per_minute", BUnits.BEATS_PER_MINUTE),
165 AMPERE_HOURS(0x27B0, "org.bluetooth.unit.electric_charge.ampere_hours", BUnits.AMPERE_HOUR),
166 MILLIGRAM_PER_DECILITRE(0x27B1, "org.bluetooth.unit.mass_density.milligram_per_decilitre", Units.ONE),
167 MILLIMOLE_PER_LITRE(0x27B2, "org.bluetooth.unit.mass_density.millimole_per_litre", Units.ONE),
168 YEAR(0x27B3, "org.bluetooth.unit.time.year", Units.YEAR),
169 MONTH(0x27B4, "org.bluetooth.unit.time.month", Units.ONE),
170 COUNT_PER_CUBIC_METRE(0x27B5, "org.bluetooth.unit.concentration.count_per_cubic_metre", Units.ONE),
171 WATT_PER_SQUARE_METRE(0x27B6, "org.bluetooth.unit.irradiance.watt_per_square_metre", Units.IRRADIANCE),
172 MILLILITER_PER_KILOGRAM_PER_MINUTE(0x27B7, "org.bluetooth.unit.transfer_rate.milliliter_per_kilogram_per_minute",
174 POUND(0x27B8, "org.bluetooth.unit.mass.pound", BUnits.POUND),
175 METABOLIC_EQUIVALENT(0x27B9, "org.bluetooth.unit.metabolic_equivalent", Units.ONE),
176 STEP_PER_MINUTE(0x27BA, "org.bluetooth.unit.step_per_minute", BUnits.STEP_PER_MINUTE),
177 STROKE_PER_MINUTE(0x27BC, "org.bluetooth.unit.stroke_per_minute", BUnits.STROKE_PER_MINUTE),
178 KILOMETER_PER_MINUTE(0x27BD, "org.bluetooth.unit.velocity.kilometer_per_minute", BUnits.KILOMETRE_PER_MINUTE),
179 LUMEN_PER_WATT(0x27BE, "org.bluetooth.unit.luminous_efficacy.lumen_per_watt", BUnits.LUMEN_PER_WATT),
180 LUMEN_HOUR(0x27BF, "org.bluetooth.unit.luminous_energy.lumen_hour", BUnits.LUMEN_HOUR),
181 LUX_HOUR(0x27C0, "org.bluetooth.unit.luminous_exposure.lux_hour", BUnits.LUX_HOUR),
182 GRAM_PER_SECOND(0x27C1, "org.bluetooth.unit.mass_flow.gram_per_second", BUnits.GRAM_PER_SECOND),
183 LITRE_PER_SECOND(0x27C2, "org.bluetooth.unit.volume_flow.litre_per_second", BUnits.LITRE_PER_SECOND),
184 DECIBEL_SPL(0x27C3, "org.bluetooth.unit.sound_pressure.decibel_spl", Units.ONE),
185 PARTS_PER_MILLION(0x27C4, "org.bluetooth.unit.concentration.parts_per_million", Units.PARTS_PER_MILLION),
186 PARTS_PER_BILLION(0x27C5, "org.bluetooth.unit.concentration.parts_per_billion", Units.PARTS_PER_BILLION);
192 private Unit<?> unit;
194 private BluetoothUnit(long key, String type, Unit<?> unit) {
195 this.uuid = new UUID((key << 32) | 0x1000, BluetoothBindingConstants.BLUETOOTH_BASE_UUID);
200 public static @Nullable BluetoothUnit findByType(String type) {
201 for (BluetoothUnit unit : BluetoothUnit.values()) {
202 if (unit.type.equals(type)) {
209 public UUID getUUID() {
213 public String getType() {
217 public Unit<?> getUnit() {
222 * This class contains the set of units that are not yet defined in Units.
223 * Once these units are added to the core then this class will be removed.
229 public static class BUnits {
230 public static final Unit<ArealDensity> KILOGRAM_PER_SQUARE_METER = addUnit(
231 new ProductUnit<ArealDensity>(SIUnits.KILOGRAM.divide(SIUnits.SQUARE_METRE)));
233 public static final Unit<RadiationDoseAbsorptionRate> GRAY_PER_SECOND = addUnit(
234 new ProductUnit<RadiationDoseAbsorptionRate>(Units.GRAY.divide(Units.SECOND)));
236 public static final Unit<Mass> POUND = addUnit(
237 new TransformedUnit<Mass>(SIUnits.KILOGRAM, MultiplyConverter.of(0.45359237)));
239 public static final Unit<Angle> MINUTE_ANGLE = addUnit(new TransformedUnit<Angle>(Units.RADIAN,
240 MultiplyConverter.ofPiExponent(1).concatenate(MultiplyConverter.ofRational(1, 180 * 60))));
242 public static final Unit<Angle> SECOND_ANGLE = addUnit(new TransformedUnit<Angle>(Units.RADIAN,
243 MultiplyConverter.ofPiExponent(1).concatenate(MultiplyConverter.ofRational(1, 180 * 60 * 60))));
245 public static final Unit<Area> HECTARE = addUnit(SIUnits.SQUARE_METRE.multiply(10000.0));
246 public static final Unit<Area> BARN = addUnit(SIUnits.SQUARE_METRE.multiply(10E-28));
248 public static final Unit<Length> NAUTICAL_MILE = addUnit(SIUnits.METRE.multiply(1852.0));
250 public static final Unit<RadiantIntensity> WATT_PER_STERADIAN = addUnit(
251 new ProductUnit<RadiantIntensity>(Units.WATT.divide(Units.STERADIAN)));
253 public static final Unit<Radiance> WATT_PER_STERADIAN_PER_SQUARE_METRE = addUnit(
254 new ProductUnit<Radiance>(WATT_PER_STERADIAN.divide(SIUnits.SQUARE_METRE)));
256 public static final Unit<Frequency> CYCLES_PER_MINUTE = addUnit(new TransformedUnit<Frequency>(Units.HERTZ,
257 MultiplyConverter.ofRational(BigInteger.valueOf(60), BigInteger.ONE)));
259 public static final Unit<Angle> REVOLUTION = addUnit(new TransformedUnit<Angle>(Units.RADIAN,
260 MultiplyConverter.ofPiExponent(1).concatenate(MultiplyConverter.ofRational(2, 1))));
261 public static final Unit<AngularVelocity> REVOLUTION_PER_MINUTE = addUnit(
262 new ProductUnit<AngularVelocity>(REVOLUTION.divide(Units.MINUTE)));
264 public static final Unit<Dimensionless> STEPS = addUnit(Units.ONE.alternate("steps"));
265 public static final Unit<Dimensionless> BEATS = addUnit(Units.ONE.alternate("beats"));
266 public static final Unit<Dimensionless> STROKE = addUnit(Units.ONE.alternate("stroke"));
268 public static final Unit<Frequency> STEP_PER_MINUTE = addUnit(
269 new ProductUnit<Frequency>(STEPS.divide(Units.MINUTE)));
271 public static final Unit<Frequency> BEATS_PER_MINUTE = addUnit(
272 new ProductUnit<Frequency>(BEATS.divide(Units.MINUTE)));
274 public static final Unit<Frequency> STROKE_PER_MINUTE = addUnit(
275 new ProductUnit<Frequency>(STROKE.divide(Units.MINUTE)));
277 public static final Unit<MassFlowRate> GRAM_PER_SECOND = addUnit(
278 new ProductUnit<MassFlowRate>(SIUnits.GRAM.divide(Units.SECOND)));
280 public static final Unit<LuminousEfficacy> LUMEN_PER_WATT = addUnit(
281 new ProductUnit<LuminousEfficacy>(Units.LUMEN.divide(Units.WATT)));
283 public static final Unit<LuminousEnergy> LUMEN_SECOND = addUnit(
284 new ProductUnit<LuminousEnergy>(Units.LUMEN.multiply(Units.SECOND)));
286 public static final Unit<LuminousEnergy> LUMEN_HOUR = addUnit(
287 new ProductUnit<LuminousEnergy>(Units.LUMEN.multiply(Units.HOUR)));
289 public static final Unit<ElectricCharge> AMPERE_HOUR = addUnit(
290 new ProductUnit<ElectricCharge>(Units.AMPERE.multiply(Units.HOUR)));
292 public static final Unit<LuminousExposure> LUX_HOUR = addUnit(
293 new ProductUnit<LuminousExposure>(Units.LUX.multiply(Units.HOUR)));
295 public static final Unit<Speed> KILOMETRE_PER_MINUTE = addUnit(SIUnits.KILOMETRE_PER_HOUR.multiply(60.0));
297 public static final Unit<VolumetricFlowRate> LITRE_PER_SECOND = addUnit(
298 new ProductUnit<VolumetricFlowRate>(Units.LITRE.divide(Units.SECOND)));
301 SimpleUnitFormat.getInstance().label(GRAY_PER_SECOND, "Gy/s");
302 SimpleUnitFormat.getInstance().label(MINUTE_ANGLE, "'");
303 SimpleUnitFormat.getInstance().label(SECOND_ANGLE, "\"");
304 SimpleUnitFormat.getInstance().label(HECTARE, "ha");
305 SimpleUnitFormat.getInstance().label(NAUTICAL_MILE, "NM");
306 SimpleUnitFormat.getInstance().label(KILOGRAM_PER_SQUARE_METER, "kg/m²");
307 SimpleUnitFormat.getInstance().label(POUND, "lb");
308 SimpleUnitFormat.getInstance().label(CYCLES_PER_MINUTE, "cpm");
309 SimpleUnitFormat.getInstance().label(GRAM_PER_SECOND, "g/s");
310 SimpleUnitFormat.getInstance().label(LUMEN_SECOND, "lm·s");
311 SimpleUnitFormat.getInstance().label(LUMEN_HOUR, "lm·h");
312 SimpleUnitFormat.getInstance().label(LUMEN_PER_WATT, "lm/W");
313 SimpleUnitFormat.getInstance().label(LUX_HOUR, "lx·h");
314 SimpleUnitFormat.getInstance().label(KILOMETRE_PER_MINUTE, "km/min");
315 SimpleUnitFormat.getInstance().label(LITRE_PER_SECOND, "l/s");
316 SimpleUnitFormat.getInstance().label(BEATS_PER_MINUTE, "bpm");
317 SimpleUnitFormat.getInstance().label(STEP_PER_MINUTE, "steps/min");
318 SimpleUnitFormat.getInstance().label(STROKE_PER_MINUTE, "spm");
319 SimpleUnitFormat.getInstance().label(REVOLUTION_PER_MINUTE, "rpm");
322 private static <U extends Unit<?>> U addUnit(U unit) {
326 public interface AngularVelocity extends Quantity<AngularVelocity> {
329 public interface LuminousEnergy extends Quantity<LuminousEnergy> {
332 public interface LuminousEfficacy extends Quantity<LuminousEfficacy> {
335 public interface LuminousExposure extends Quantity<LuminousExposure> {
338 public interface RadiantIntensity extends Quantity<RadiantIntensity> {
341 public interface Radiance extends Quantity<Radiance> {
344 public interface RadiationExposure extends Quantity<RadiationExposure> {
347 public interface RadiationDoseAbsorptionRate extends Quantity<RadiationDoseAbsorptionRate> {
350 public interface MassFlowRate extends Quantity<MassFlowRate> {