Skip to content

Commit 88a415f

Browse files
committedFeb 20, 2025·
Update to openHAB 3.2 release.
Signed-off-by: Łukasz Dywicki <luke@code-house.org>
1 parent e48cc48 commit 88a415f

File tree

24 files changed

+141
-51
lines changed

24 files changed

+141
-51
lines changed
 

‎bundles/org.connectorio.addons.binding.askoheat/src/main/java/org/connectorio/addons/binding/askoheat/internal/handler/AskoheatBridgeHandler.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,9 @@ public void run() {
108108
ValueBlock params = client.getValueBlock();
109109
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "status"), new DecimalType(params.getStatus()));
110110
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "load"), QuantityType.valueOf(params.getLoad(), Units.WATT));
111-
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "temperatureLimit"), QuantityType.valueOf(params.getTemperatureLimit(), tec.uom.se.unit.Units.CELSIUS));
112-
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "temperatureSensor0"), QuantityType.valueOf(params.getTemperatureSensor0(), tec.uom.se.unit.Units.CELSIUS));
113-
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "maximumTemperature"), QuantityType.valueOf(params.getMaximumTemperature(), tec.uom.se.unit.Units.CELSIUS));
111+
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "temperatureLimit"), QuantityType.valueOf(params.getTemperatureLimit(), tech.units.indriya.unit.Units.CELSIUS));
112+
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "temperatureSensor0"), QuantityType.valueOf(params.getTemperatureSensor0(), tech.units.indriya.unit.Units.CELSIUS));
113+
getCallback().stateUpdated(new ChannelUID(getThing().getUID(), "maximumTemperature"), QuantityType.valueOf(params.getMaximumTemperature(), tech.units.indriya.unit.Units.CELSIUS));
114114
}
115115
}, 1000L, getRefreshInterval(), TimeUnit.MILLISECONDS));
116116
tasks.add(scheduler.scheduleAtFixedRate(new Runnable() {

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/TAUnits.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
import javax.measure.quantity.Length;
2323
import org.openhab.core.library.unit.MetricPrefix;
2424
import org.openhab.core.library.unit.SIUnits;
25-
import tec.uom.se.AbstractConverter;
26-
import tec.uom.se.AbstractUnit;
27-
import tec.uom.se.format.SimpleUnitFormat;
28-
import tec.uom.se.unit.TransformedUnit;
25+
import tech.units.indriya.AbstractUnit;
26+
import tech.units.indriya.format.SimpleUnitFormat;
27+
import tech.units.indriya.function.AbstractConverter;
28+
import tech.units.indriya.unit.TransformedUnit;
2929

3030
public class TAUnits {
3131

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/internal/config/AnalogUnit.java

+8-8
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
import org.openhab.core.library.unit.MetricPrefix;
3131
import org.openhab.core.library.unit.SIUnits;
3232
import org.openhab.core.library.unit.Units;
33-
import tec.uom.se.AbstractUnit;
33+
import tech.units.indriya.AbstractUnit;
3434

3535
public enum AnalogUnit implements TAUnit {
3636

@@ -58,14 +58,14 @@ public enum AnalogUnit implements TAUnit {
5858
/* 22 analog */ LITRE_PER_MINUTE (22, Units.LITRE_PER_MINUTE, 1),
5959
/* 23 analog */ BAR (23, Units.BAR, 0.01),
6060
/* 24 analog */ POWER_FACTOR(24, AbstractUnit.ONE, 0.01),
61-
/* 25 analog */ KILO_METRE (25, MetricPrefix.KILO(tec.uom.se.unit.Units.METRE), 1),
62-
/* 26 analog */ METRE (26, tec.uom.se.unit.Units.METRE, 1),
63-
/* 27 analog */ MILLIMETER (27, MetricPrefix.MILLI(tec.uom.se.unit.Units.METRE), 1),
64-
/* 28 analog */ CUBIC_METRE (28, tec.uom.se.unit.Units.CUBIC_METRE, 1),
65-
/* 29 analog */ HERTZ_KM_HOUR (29, Units.HERTZ.divide(MetricPrefix.KILO(tec.uom.se.unit.Units.METRE).divide(Units.HOUR)), 1),
66-
/* 30 analog */ HERTZ_M_SECOND (30, Units.HERTZ.divide(tec.uom.se.unit.Units.METRE.divide(Units.SECOND)), 1),
61+
/* 25 analog */ KILO_METRE (25, MetricPrefix.KILO(SIUnits.METRE), 1),
62+
/* 26 analog */ METRE (26, SIUnits.METRE, 1),
63+
/* 27 analog */ MILLIMETER (27, MetricPrefix.MILLI(SIUnits.METRE), 1),
64+
/* 28 analog */ CUBIC_METRE (28, SIUnits.CUBIC_METRE, 1),
65+
/* 29 analog */ HERTZ_KM_HOUR (29, Units.HERTZ.divide(MetricPrefix.KILO(SIUnits.METRE).divide(Units.HOUR)), 1),
66+
/* 30 analog */ HERTZ_M_SECOND (30, Units.HERTZ.divide(SIUnits.METRE.divide(Units.SECOND)), 1),
6767
/* 31 analog */ KILOWATT_PER_IMPULSE (31, Units.KILOWATT_HOUR.divide(TAUnits.IMPULSE), 1),
68-
/* 32 analog */ CUBICMETRE_PER_IMPULSE (32, tec.uom.se.unit.Units.CUBIC_METRE.divide(TAUnits.IMPULSE), 1),
68+
/* 32 analog */ CUBICMETRE_PER_IMPULSE (32, SIUnits.CUBIC_METRE.divide(TAUnits.IMPULSE), 1),
6969
/* 33 analog */ MILLIMETRE_PER_IMPULSE(33, TAUnits.MILLIMETRE.divide(TAUnits.IMPULSE), 1),
7070
/* 34 analog */ LITER_PER_IMPULSE (34, Units.LITRE.divide(TAUnits.IMPULSE), 1),
7171
/* 35 analog */ LITER_PER_DAY (35, Units.LITRE.divide(Units.DAY), 1),

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/internal/config/ComplexUnit.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
import java.util.stream.Collectors;
2525

2626
import org.connectorio.addons.binding.canopen.ta.internal.type.TAUnit;
27-
import tec.uom.se.quantity.Quantities;
28-
import tec.uom.se.unit.Units;
27+
import org.openhab.core.library.unit.SIUnits;
28+
import tech.units.indriya.quantity.Quantities;
2929

3030
/**
3131
* Compound units whcih require additional parsing. Result of computation is list and not single value.
@@ -38,7 +38,7 @@ public enum ComplexUnit implements TAUnit {
3838

3939
double value = 0.1 * (raw & 0x1FF) * (negative ? -1 : 1);
4040
return Arrays.asList(
41-
Quantities.getQuantity(value, Units.CELSIUS),
41+
Quantities.getQuantity(value, SIUnits.CELSIUS),
4242
(raw & 0x600) >> 9
4343
);
4444
});

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/internal/handler/channel/AnalogChannelHandler.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
import org.openhab.core.thing.binding.ThingHandlerCallback;
3333
import org.openhab.core.types.Command;
3434
import org.openhab.core.types.State;
35-
import tec.uom.se.quantity.Quantities;
35+
import tech.units.indriya.quantity.Quantities;
3636

3737
public class AnalogChannelHandler extends BaseChannelHandler<AnalogValue, AnalogUnit, AnalogObjectConfig> {
3838

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/internal/handler/channel/RASChannelHandler.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
import org.openhab.core.types.State;
3737
import org.slf4j.Logger;
3838
import org.slf4j.LoggerFactory;
39-
import tec.uom.se.quantity.Quantities;
39+
import tech.units.indriya.quantity.Quantities;
4040

4141
public class RASChannelHandler extends BaseChannelHandler<RASValue, AnalogUnit, AnalogObjectConfig> {
4242

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/internal/type/TAValue.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
import org.connectorio.addons.binding.canopen.ta.internal.config.AnalogUnit;
2121
import org.connectorio.addons.binding.canopen.ta.internal.config.ComplexUnit;
2222
import org.connectorio.addons.binding.canopen.ta.internal.config.DigitalUnit;
23-
import tec.uom.se.quantity.Quantities;
23+
import tech.units.indriya.quantity.Quantities;
2424

2525
public class TAValue {
2626

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/tapi/val/BaseAnalogValue.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
import javax.measure.Quantity;
2222
import org.connectorio.addons.binding.canopen.ta.internal.config.AnalogUnit;
2323
import org.connectorio.addons.binding.canopen.ta.internal.type.TAUnit;
24-
import tec.uom.se.quantity.Quantities;
24+
import tech.units.indriya.quantity.Quantities;
2525

2626
public abstract class BaseAnalogValue<T extends Number> implements AnalogValue {
2727

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/tapi/val/RASValue.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
import org.apache.plc4x.java.spi.generation.WriteBuffer;
2525
import org.connectorio.addons.binding.canopen.ta.internal.config.AnalogUnit;
2626
import org.connectorio.addons.binding.canopen.ta.internal.type.TAUnit;
27-
import tec.uom.se.quantity.Quantities;
27+
import tech.units.indriya.quantity.Quantities;
2828

2929
public class RASValue extends ShortAnalogValue {
3030

‎bundles/org.connectorio.addons.binding.canopen.ta/src/main/java/org/connectorio/addons/binding/canopen/ta/tapi/val/ShortAnalogValue.java

-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
import javax.measure.Quantity;
2121
import org.connectorio.addons.binding.canopen.ta.internal.config.AnalogUnit;
2222
import org.connectorio.addons.binding.canopen.ta.internal.type.TAUnit;
23-
import tec.uom.se.quantity.Quantities;
2423

2524
public class ShortAnalogValue extends BaseAnalogValue<Short> {
2625

‎bundles/org.connectorio.addons.binding.canopen.ta/src/test/java/org/connectorio/addons/binding/canopen/ta/tapi/val/AnalogValueTest.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525
import org.connectorio.addons.binding.canopen.ta.internal.config.AnalogUnit;
2626
import org.junit.jupiter.api.Test;
2727
import org.openhab.core.library.unit.Units;
28-
import tec.uom.se.ComparableQuantity;
29-
import tec.uom.se.quantity.Quantities;
28+
import tech.units.indriya.ComparableQuantity;
29+
import tech.units.indriya.quantity.Quantities;
3030

3131
class AnalogValueTest {
3232

‎bundles/org.connectorio.addons.binding.canopen.ta/src/test/java/org/connectorio/addons/binding/canopen/ta/tapi/val/RASValueTest.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
import org.connectorio.addons.binding.canopen.ta.internal.config.AnalogUnit;
2828
import org.junit.jupiter.params.ParameterizedTest;
2929
import org.junit.jupiter.params.provider.MethodSource;
30-
import tec.uom.se.quantity.Quantities;
31-
import tec.uom.se.unit.Units;
30+
import org.openhab.core.library.unit.SIUnits;
31+
import tech.units.indriya.quantity.Quantities;
3232

3333
class RASValueTest {
3434

@@ -37,7 +37,7 @@ class RASValueTest {
3737
void verifyRasValue(Argument argument) {
3838
RASValue rasValue = new RASValue(argument.raw, AnalogUnit.TEMPERATURE_REGULATOR);
3939

40-
Quantity<Temperature> quantity = Quantities.getQuantity(argument.temperature, Units.CELSIUS);
40+
Quantity<Temperature> quantity = Quantities.getQuantity(argument.temperature, SIUnits.CELSIUS);
4141
assertThat(rasValue.getValue().getValue().doubleValue())
4242
.isCloseTo(quantity.getValue().doubleValue(), Percentage.withPercentage(1));
4343
assertThat(rasValue.getMode()).isEqualTo(argument.mode);

‎bundles/org.connectorio.addons.binding.canopen/src/main/java/org/connectorio/addons/binding/canopen/internal/statistics/BandwidthStatisticCollector.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
import org.openhab.core.library.dimension.DataAmount;
2525
import org.openhab.core.library.dimension.DataTransferRate;
2626
import org.openhab.core.library.unit.Units;
27-
import tec.uom.se.quantity.Quantities;
27+
import tech.units.indriya.quantity.Quantities;
2828

2929
/**
3030
* Bit ratio calculation.

‎bundles/org.connectorio.addons.binding.canopen/src/main/java/org/connectorio/addons/binding/canopen/internal/statistics/RatioStatisticCollector.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
import java.util.function.Supplier;
2222
import javax.measure.Quantity;
2323
import javax.measure.quantity.Dimensionless;
24-
import tec.uom.se.AbstractUnit;
25-
import tec.uom.se.quantity.Quantities;
24+
import tech.units.indriya.AbstractUnit;
25+
import tech.units.indriya.quantity.Quantities;
2626

2727
/**
2828
* Ratio calculation.

‎bundles/org.connectorio.addons.binding.canopen/src/main/java/org/connectorio/addons/binding/canopen/internal/statistics/SysfsReader.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
import javax.measure.Unit;
2626
import org.slf4j.Logger;
2727
import org.slf4j.LoggerFactory;
28-
import tec.uom.se.quantity.Quantities;
28+
import tech.units.indriya.quantity.Quantities;
2929

3030
public class SysfsReader<Q extends Quantity<Q>> {
3131

‎bundles/org.connectorio.addons.binding.canopen/src/test/java/org/connectorio/addons/binding/canopen/internal/statistics/BandwidthStatisticCollectorTest.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
import org.openhab.core.library.dimension.DataAmount;
3131
import org.openhab.core.library.dimension.DataTransferRate;
3232
import org.openhab.core.library.unit.Units;
33-
import tec.uom.se.quantity.Quantities;
33+
import tech.units.indriya.quantity.Quantities;
3434

3535
@ExtendWith(MockitoExtension.class)
3636
class BandwidthStatisticCollectorTest {
@@ -52,8 +52,8 @@ protected Quantity<DataAmount> readStatistic() {
5252
statistic.set(Quantities.getQuantity(0, Units.BYTE));
5353
assertThat(collector.getStatistic())
5454
.extracting(Quantity::getValue)
55-
.extracting(Number::intValue)
56-
.isEqualTo(0);
55+
.extracting(Number::doubleValue)
56+
.isEqualTo(0.0);
5757

5858
// one second and one byte later we expect 8 bit/s ratio.
5959
when(clock.get()).thenReturn(2000L);

‎bundles/org.connectorio.addons.binding.canopen/src/test/java/org/connectorio/addons/binding/canopen/internal/statistics/RatioStatisticCollectorTest.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@
2828
import org.junit.jupiter.api.extension.ExtendWith;
2929
import org.mockito.Mock;
3030
import org.mockito.junit.jupiter.MockitoExtension;
31-
import tec.uom.se.AbstractUnit;
32-
import tec.uom.se.quantity.Quantities;
31+
import tech.units.indriya.AbstractUnit;
32+
import tech.units.indriya.quantity.Quantities;
3333

3434
@ExtendWith(MockitoExtension.class)
3535
class RatioStatisticCollectorTest {

‎bundles/org.connectorio.addons.binding.relayweblog/src/main/java/org/connectorio/addons/binding/relayweblog/internal/handler/AbstractMeterThingHandler.java

+4-3
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@
5353
import org.openhab.core.library.types.DecimalType;
5454
import org.openhab.core.library.types.QuantityType;
5555
import org.openhab.core.library.unit.MetricPrefix;
56+
import org.openhab.core.library.unit.SIUnits;
5657
import org.openhab.core.library.unit.Units;
5758
import org.openhab.core.thing.Channel;
5859
import org.openhab.core.thing.ChannelUID;
@@ -78,11 +79,11 @@ abstract class AbstractMeterThingHandler<B extends WeblogBridgeHandler, C extend
7879
.toFormatter();
7980

8081
private final static Map<String, MappingEntry> MAPPING = Map.of(
81-
"kW", new MappingEntry(Power.class, MetricPrefix.KILO(tec.uom.se.unit.Units.WATT)),
82+
"kW", new MappingEntry(Power.class, MetricPrefix.KILO(Units.WATT)),
8283
"kWh", new MappingEntry(Energy.class, Units.KILOWATT_HOUR),
83-
"m^3", new MappingEntry(Volume.class, tec.uom.se.unit.Units.CUBIC_METRE),
84+
"m^3", new MappingEntry(Volume.class, SIUnits.CUBIC_METRE),
8485
"m^3/h", new MappingEntry(VolumetricFlowRate.class, Units.CUBICMETRE_PER_HOUR),
85-
"C", new MappingEntry(Temperature.class, tec.uom.se.unit.Units.CELSIUS),
86+
"C", new MappingEntry(Temperature.class, SIUnits.CELSIUS),
8687
"h", new MappingEntry(Time.class, Units.HOUR),
8788
"s", new MappingEntry(Time.class, Units.SECOND)
8889
);

‎bundles/org.connectorio.addons.io.transport.serial.purejavacomm/src/main/java/org/connectorio/addons/io/transport/serial/purejavacomm/internal/PureJavaCommSerialPort.java

+90
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,26 @@ public void setSerialPortParams(int baudrate, int dataBits, int stopBits, int pa
4949
}
5050
}
5151

52+
@Override
53+
public int getBaudRate() {
54+
return port.getBaudRate();
55+
}
56+
57+
@Override
58+
public int getDataBits() {
59+
return port.getDataBits();
60+
}
61+
62+
@Override
63+
public int getStopBits() {
64+
return port.getStopBits();
65+
}
66+
67+
@Override
68+
public int getParity() {
69+
return port.getParity();
70+
}
71+
5272
@Override
5373
public InputStream getInputStream() throws IOException {
5474
return port.getInputStream();
@@ -114,6 +134,31 @@ public void notifyOnParityError(boolean enable) {
114134
port.notifyOnParityError(enable);
115135
}
116136

137+
@Override
138+
public void notifyOnOutputEmpty(boolean enable) {
139+
port.notifyOnOutputEmpty(enable);
140+
}
141+
142+
@Override
143+
public void notifyOnCTS(boolean enable) {
144+
port.notifyOnCTS(enable);
145+
}
146+
147+
@Override
148+
public void notifyOnDSR(boolean enable) {
149+
port.notifyOnDSR(enable);
150+
}
151+
152+
@Override
153+
public void notifyOnRingIndicator(boolean enable) {
154+
port.notifyOnRingIndicator(enable);
155+
}
156+
157+
@Override
158+
public void notifyOnCarrierDetect(boolean enable) {
159+
port.notifyOnCarrierDetect(enable);
160+
}
161+
117162
@Override
118163
public void enableReceiveTimeout(int timeout) throws UnsupportedCommOperationException, IllegalArgumentException {
119164
try {
@@ -137,6 +182,11 @@ public void setFlowControlMode(int flowcontrolRtsctsOut) throws UnsupportedCommO
137182
}
138183
}
139184

185+
@Override
186+
public int getFlowControlMode() {
187+
return port.getFlowControlMode();
188+
}
189+
140190
@Override
141191
public void enableReceiveThreshold(int i) throws UnsupportedCommOperationException {
142192
try {
@@ -151,4 +201,44 @@ public void setRTS(boolean rts) {
151201
port.setRTS(rts);
152202
}
153203

204+
@Override
205+
public boolean isRTS() {
206+
return port.isRTS();
207+
}
208+
209+
@Override
210+
public void setDTR(boolean enable) {
211+
port.setDTR(enable);
212+
}
213+
214+
@Override
215+
public boolean isDTR() {
216+
return port.isDTR();
217+
}
218+
219+
@Override
220+
public boolean isCTS() {
221+
return port.isCTS();
222+
}
223+
224+
@Override
225+
public boolean isDSR() {
226+
return port.isDSR();
227+
}
228+
229+
@Override
230+
public boolean isCD() {
231+
return port.isCD();
232+
}
233+
234+
@Override
235+
public boolean isRI() {
236+
return port.isRI();
237+
}
238+
239+
@Override
240+
public void sendBreak(int duration) {
241+
port.sendBreak(duration);
242+
}
243+
154244
}

‎bundles/org.connectorio.addons.io.transport.serial.purejavacomm/src/main/java/org/connectorio/addons/io/transport/serial/purejavacomm/internal/PureJavaCommSerialPortIdentifier.java

+1-3
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,7 @@ public SerialPort open(String owner, int timeout) throws PortInUseException {
4343
try {
4444
return new PureJavaCommSerialPort((purejavacomm.SerialPort) identifier.open(owner, timeout));
4545
} catch (purejavacomm.PortInUseException e) {
46-
PortInUseException exception = new PortInUseException();
47-
exception.initCause(e);
48-
throw exception;
46+
throw new PortInUseException(e);
4947
}
5048
}
5149

‎bundles/org.connectorio.addons.profile.boundary/src/test/java/org/connectorio/addons/profile/boundary/internal/LimitBottomQuantityProfileTest.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import static org.mockito.Mockito.when;
2121

2222
import java.util.HashMap;
23+
import javax.measure.MetricPrefix;
2324
import javax.measure.Unit;
2425
import org.junit.jupiter.api.Test;
2526
import org.junit.jupiter.api.extension.ExtendWith;
@@ -31,8 +32,9 @@
3132
import org.openhab.core.library.types.QuantityType;
3233
import org.openhab.core.thing.profiles.ProfileCallback;
3334
import org.openhab.core.thing.profiles.ProfileContext;
34-
import tec.uom.se.unit.MetricPrefix;
35-
import tec.uom.se.unit.Units;
35+
import tech.units.indriya.unit.Units;
36+
import javax.measure.MetricPrefix;
37+
import javax.measure.Unit;
3638

3739
@ExtendWith(MockitoExtension.class)
3840
public class LimitBottomQuantityProfileTest {

‎bundles/org.connectorio.addons.profile.boundary/src/test/java/org/connectorio/addons/profile/boundary/internal/LimitRangeQuantityProfileTest.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@
3131
import org.openhab.core.library.types.QuantityType;
3232
import org.openhab.core.thing.profiles.ProfileCallback;
3333
import org.openhab.core.thing.profiles.ProfileContext;
34-
import tec.uom.se.unit.MetricPrefix;
35-
import tec.uom.se.unit.Units;
34+
import javax.measure.MetricPrefix;
35+
import tech.units.indriya.unit.Units;
3636

3737
@ExtendWith(MockitoExtension.class)
3838
public class LimitRangeQuantityProfileTest {

‎bundles/org.connectorio.addons.profile.boundary/src/test/java/org/connectorio/addons/profile/boundary/internal/LimitTopQuantityProfileTest.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
import org.openhab.core.library.types.QuantityType;
3131
import org.openhab.core.thing.profiles.ProfileCallback;
3232
import org.openhab.core.thing.profiles.ProfileContext;
33-
import tec.uom.se.unit.Units;
33+
import tech.units.indriya.unit.Units;
3434

3535
@ExtendWith(MockitoExtension.class)
3636
public class LimitTopQuantityProfileTest {

‎bundles/org.connectorio.addons.profile.counter/src/main/java/org/connectorio/addons/profile/counter/internal/EnergyCounterProfile.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727
import org.connectorio.addons.profile.counter.internal.state.DummyStateRetriever;
2828
import org.openhab.core.library.types.DecimalType;
2929
import org.openhab.core.library.types.QuantityType;
30+
import org.openhab.core.library.unit.MetricPrefix;
3031
import org.openhab.core.library.unit.Units;
3132
import org.openhab.core.thing.profiles.ProfileCallback;
3233
import org.openhab.core.thing.profiles.ProfileContext;
3334
import org.openhab.core.thing.profiles.ProfileTypeUID;
3435
import org.openhab.core.types.Type;
35-
import tec.uom.se.unit.MetricPrefix;
36-
import tec.uom.se.unit.ProductUnit;
36+
import tech.units.indriya.unit.ProductUnit;
3737

3838
/**
3939
* Little utility profile which, based on power reading will calculate energy consumption.

0 commit comments

Comments
 (0)
Please sign in to comment.