]> git.basschouten.com Git - openhab-addons.git/commitdiff
Bump spotless to 2.35 and Eclipse Java Formatter to 4.26 (#14645)
authorJ-N-K <github@klug.nrw>
Tue, 21 Mar 2023 20:03:05 +0000 (21:03 +0100)
committerGitHub <noreply@github.com>
Tue, 21 Mar 2023 20:03:05 +0000 (21:03 +0100)
Signed-off-by: Jan N. Klug <github@klug.nrw>
36 files changed:
bundles/org.openhab.binding.broadlinkthermostat/src/main/java/org/openhab/binding/broadlinkthermostat/internal/handler/FloureonThermostatHandler.java
bundles/org.openhab.binding.deconz/src/main/java/org/openhab/binding/deconz/internal/handler/SensorThermostatThingHandler.java
bundles/org.openhab.binding.deconz/src/main/java/org/openhab/binding/deconz/internal/handler/SensorThingHandler.java
bundles/org.openhab.binding.digitalstrom/src/main/java/org/openhab/binding/digitalstrom/internal/discovery/DiscoveryServiceManager.java
bundles/org.openhab.binding.digitalstrom/src/main/java/org/openhab/binding/digitalstrom/internal/providers/DsDeviceThingTypeProvider.java
bundles/org.openhab.binding.elroconnects/src/main/java/org/openhab/binding/elroconnects/internal/handler/ElroConnectsBridgeHandler.java
bundles/org.openhab.binding.freebox/src/main/java/org/openhab/binding/freebox/internal/console/FreeboxCommandExtension.java
bundles/org.openhab.binding.hue/src/main/java/org/openhab/binding/hue/internal/console/HueCommandExtension.java
bundles/org.openhab.binding.knx/src/main/java/org/openhab/binding/knx/internal/handler/DeviceThingHandler.java
bundles/org.openhab.binding.lametrictime/src/main/java/org/openhab/binding/lametrictime/internal/api/common/impl/typeadapters/imported/RuntimeTypeAdapterFactory.java
bundles/org.openhab.binding.lgwebos/src/main/java/org/openhab/binding/lgwebos/internal/console/LGWebOSCommandExtension.java
bundles/org.openhab.binding.linky/src/main/java/org/openhab/binding/linky/internal/console/LinkyCommandExtension.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/AlarmControlPanel.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/ComponentFactory.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/Cover.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/DefaultSchemaLight.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/DeviceTrigger.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/Fan.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/Lock.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/Number.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/Select.java
bundles/org.openhab.binding.mqtt.homeassistant/src/main/java/org/openhab/binding/mqtt/homeassistant/internal/component/Sensor.java
bundles/org.openhab.binding.onewire/src/main/java/org/openhab/binding/onewire/internal/handler/AdvancedMultisensorThingHandler.java
bundles/org.openhab.binding.pilight/src/main/java/org/openhab/binding/pilight/internal/PilightConnector.java
bundles/org.openhab.binding.powermax/src/main/java/org/openhab/binding/powermax/internal/console/PowermaxCommandExtension.java
bundles/org.openhab.binding.smartmeter/src/test/java/org/openhab/binding/smartmeter/TestMeterReading.java
bundles/org.openhab.binding.somfytahoma/src/main/java/org/openhab/binding/somfytahoma/internal/console/SomfyTahomaCommandExtension.java
bundles/org.openhab.binding.velux/src/main/java/org/openhab/binding/velux/internal/bridge/slip/SCrunProductCommand.java
bundles/org.openhab.io.homekit/src/main/java/org/openhab/io/homekit/internal/accessories/HomekitHeaterCoolerImpl.java
bundles/org.openhab.io.homekit/src/main/java/org/openhab/io/homekit/internal/accessories/HomekitTemperatureSensorImpl.java
bundles/org.openhab.io.homekit/src/main/java/org/openhab/io/homekit/internal/accessories/HomekitThermostatImpl.java
bundles/org.openhab.persistence.dynamodb/src/main/java/org/openhab/persistence/dynamodb/internal/DynamoDBBigDecimalItem.java
bundles/org.openhab.persistence.dynamodb/src/main/java/org/openhab/persistence/dynamodb/internal/DynamoDBStringItem.java
bundles/org.openhab.transform.bin2json/src/main/java/org/openhab/transform/bin2json/internal/Bin2Json.java
itests/org.openhab.binding.mielecloud.tests/src/main/java/org/openhab/binding/mielecloud/internal/handler/AbstractMieleThingHandlerTest.java
pom.xml

index bfad6c6944c38d542ab83edd0fa3cc6fa81825df..26e261ec545465370e07b6468c4b8ace578382ac 100644 (file)
@@ -216,7 +216,7 @@ public class FloureonThermostatHandler extends BroadlinkBaseHandler {
             try {
                 new SetTimeCommand(tob(zonedDateTime.getHour()), tob(zonedDateTime.getMinute()),
                         tob(zonedDateTime.getSecond()), tob(zonedDateTime.getDayOfWeek().getValue()))
-                                .execute(floureonDevice);
+                        .execute(floureonDevice);
             } catch (Exception e) {
                 logger.warn("Error while setting time of {} to {}: {}", thing.getUID(), command, e.getMessage());
             }
index a7780f47057e48c3344a41e0adce46e6953b136d..e0f4b455f876a30598d684df7796516e902545bc 100644 (file)
@@ -137,10 +137,10 @@ public class SensorThermostatThingHandler extends SensorBaseThingHandler {
         String mode = thermostatMode != null ? thermostatMode.name() : ThermostatMode.UNKNOWN.name();
         switch (channelUID.getId()) {
             case CHANNEL_THERMOSTAT_LOCKED -> updateSwitchChannel(channelUID, newConfig.locked);
-            case CHANNEL_HEATSETPOINT -> updateQuantityTypeChannel(channelUID, newConfig.heatsetpoint, CELSIUS,
-                    1.0 / 100);
-            case CHANNEL_TEMPERATURE_OFFSET -> updateQuantityTypeChannel(channelUID, newConfig.offset, CELSIUS,
-                    1.0 / 100);
+            case CHANNEL_HEATSETPOINT ->
+                updateQuantityTypeChannel(channelUID, newConfig.heatsetpoint, CELSIUS, 1.0 / 100);
+            case CHANNEL_TEMPERATURE_OFFSET ->
+                updateQuantityTypeChannel(channelUID, newConfig.offset, CELSIUS, 1.0 / 100);
             case CHANNEL_THERMOSTAT_MODE -> updateState(channelUID, new StringType(mode));
             case CHANNEL_EXTERNAL_WINDOW_OPEN -> {
                 Boolean open = newConfig.externalwindowopen;
index 9dc3eb4045c496dbfd7a7e6e35c4f074e77244f2..0d2322dcc6eb78972bf901d00ee872b3fb77f1f1 100644 (file)
@@ -157,8 +157,8 @@ public class SensorThingHandler extends SensorBaseThingHandler {
             case CHANNEL_VIBRATION -> updateSwitchChannel(channelUID, newState.vibration);
             case CHANNEL_CARBONMONOXIDE -> updateSwitchChannel(channelUID, newState.carbonmonoxide);
             case CHANNEL_AIRQUALITY -> updateStringChannel(channelUID, newState.airquality);
-            case CHANNEL_AIRQUALITYPPB -> updateQuantityTypeChannel(channelUID, newState.airqualityppb,
-                    PARTS_PER_BILLION);
+            case CHANNEL_AIRQUALITYPPB ->
+                updateQuantityTypeChannel(channelUID, newState.airqualityppb, PARTS_PER_BILLION);
             case CHANNEL_MOISTURE -> updateQuantityTypeChannel(channelUID, newState.moisture, PERCENT);
             case CHANNEL_BUTTON -> updateDecimalTypeChannel(channelUID, newState.buttonevent);
             case CHANNEL_BUTTONEVENT -> {
index 84f81eda20a8a44af54b2af0869feabb02d943e5..5893131873c88980350093e84042d5bea6f69671 100644 (file)
@@ -211,7 +211,7 @@ public class DiscoveryServiceManager
                 if (discoveryServices.get(DsDeviceThingTypeProvider.SupportedThingTypes.circuit.toString()) != null) {
                     ((DeviceDiscoveryService) discoveryServices
                             .get(DsDeviceThingTypeProvider.SupportedThingTypes.circuit.toString()))
-                                    .onDeviceAdded(device);
+                            .onDeviceAdded(device);
                 }
             }
         } catch (RuntimeException ex) {
@@ -240,7 +240,7 @@ public class DiscoveryServiceManager
         if (discoveryServices.get(DigitalSTROMBindingConstants.THING_TYPE_ZONE_TEMERATURE_CONTROL.toString()) != null) {
             ((ZoneTemperatureControlDiscoveryService) discoveryServices
                     .get(DigitalSTROMBindingConstants.THING_TYPE_ZONE_TEMERATURE_CONTROL.toString()))
-                            .configChanged(tempControlStatus);
+                    .configChanged(tempControlStatus);
         }
     }
 
index aef01b50e2218bb0708e1f53c8ad7b3f3a758a4d..cf11f1ece7519495c409baa1b74b9a29da668ed1 100644 (file)
@@ -154,7 +154,7 @@ public class DsDeviceThingTypeProvider extends BaseDsI18n implements ThingTypePr
                 thingTypeBuilder.withChannelDefinitions(Arrays.asList(new ChannelDefinitionBuilder(
                         DsChannelTypeProvider.SHADE,
                         new ChannelTypeUID(DigitalSTROMBindingConstants.BINDING_ID, DsChannelTypeProvider.SHADE))
-                                .build()));
+                        .build()));
             }
             if (SupportedThingTypes.circuit.equals(supportedThingType)) {
                 List<ChannelDefinition> channelDefinitions = new ArrayList<>(3);
@@ -162,7 +162,8 @@ public class DsDeviceThingTypeProvider extends BaseDsI18n implements ThingTypePr
                     channelDefinitions.add(new ChannelDefinitionBuilder(
                             DsChannelTypeProvider.getMeteringChannelID(meteringType, MeteringUnitsEnum.WH, false),
                             new ChannelTypeUID(DigitalSTROMBindingConstants.BINDING_ID, DsChannelTypeProvider
-                                    .getMeteringChannelID(meteringType, MeteringUnitsEnum.WH, false))).build());
+                                    .getMeteringChannelID(meteringType, MeteringUnitsEnum.WH, false)))
+                            .build());
                 }
                 thingTypeBuilder.withChannelDefinitions(channelDefinitions);
             }
index 04261495da3f21b3481d411507f2ac7bd617eae7..d387dbb4ea27d1f0cb2ccdabd296c74d4ebbb42d 100644 (file)
@@ -853,7 +853,7 @@ public class ElroConnectsBridgeHandler extends BaseBridgeHandler {
         logger.debug("Sync scenes");
         ElroConnectsMessage elroMessage = new ElroConnectsMessage(msgIdIncrement(), connectorId, ctrlKey,
                 ELRO_SYNC_SCENES, legacyFirmware).withSceneGroup(0).withSceneContent(SYNC_COMMAND)
-                        .withAnswerContent(SYNC_COMMAND);
+                .withAnswerContent(SYNC_COMMAND);
         sendElroMessage(elroMessage, true);
     }
 
index 48fd8c21df3900e68f87c8a49b0a934899a37297..1899d0521029ecd6798de5654b9a965570fb91c6 100644 (file)
@@ -106,8 +106,8 @@ public class FreeboxCommandExtension extends AbstractConsoleCommandExtension imp
         if (cursorArgumentIndex <= 0) {
             return new StringsCompleter(thingRegistry.getAll().stream()
                     .filter(t -> FreeboxBindingConstants.FREEBOX_BRIDGE_TYPE_SERVER.equals(t.getThingTypeUID()))
-                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true).complete(args,
-                            cursorArgumentIndex, cursorPosition, candidates);
+                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true)
+                    .complete(args, cursorArgumentIndex, cursorPosition, candidates);
         } else if (cursorArgumentIndex == 1) {
             Thing thing = getThing(args[0]);
             if (thing != null && FreeboxBindingConstants.FREEBOX_BRIDGE_TYPE_SERVER.equals(thing.getThingTypeUID())) {
index 424f57c52d40f68ff1440e12d8e2ee3ff692abde..befe496dabd092734e4e2af26e32ecc60c365731 100644 (file)
@@ -127,8 +127,8 @@ public class HueCommandExtension extends AbstractConsoleCommandExtension impleme
             return new StringsCompleter(thingRegistry.getAll().stream()
                     .filter(t -> HueBindingConstants.THING_TYPE_BRIDGE.equals(t.getThingTypeUID())
                             || HueBindingConstants.THING_TYPE_GROUP.equals(t.getThingTypeUID()))
-                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true).complete(args,
-                            cursorArgumentIndex, cursorPosition, candidates);
+                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true)
+                    .complete(args, cursorArgumentIndex, cursorPosition, candidates);
         } else if (cursorArgumentIndex == 1) {
             Thing thing = getThing(args[0]);
             if (thing != null && HueBindingConstants.THING_TYPE_BRIDGE.equals(thing.getThingTypeUID())) {
index 8fa423cdcee3b27d5e1000117488768ac6db8b9a..b7612cdd132b46e8080c27163072cfd5a88af223 100644 (file)
@@ -354,7 +354,7 @@ public class DeviceThingHandler extends BaseThingHandler implements GroupAddress
                     }
                     frequency = ((BigDecimal) Objects.requireNonNullElse(
                             channel.getConfiguration().get(KNXBindingConstants.REPEAT_FREQUENCY), BigDecimal.ZERO))
-                                    .intValue();
+                            .intValue();
                 } else {
                     // disable dimming by binding
                     frequency = 0;
index e91895378e1bbac146f0a50e7e8103d6cab17d80..c76c32a5a11acc3b54ac867ba6217ee580efa404 100644 (file)
@@ -139,9 +139,9 @@ import com.google.gson.stream.MalformedJsonException;
  *
  * <pre>
  *    {@code
- *   shapeAdapter.registerSubtype(Rectangle.class, "Rectangle");
- *   shapeAdapter.registerSubtype(Circle.class, "Circle");
- *   shapeAdapter.registerSubtype(Diamond.class, "Diamond");
+ * shapeAdapter.registerSubtype(Rectangle.class, "Rectangle");
+ * shapeAdapter.registerSubtype(Circle.class, "Circle");
+ * shapeAdapter.registerSubtype(Diamond.class, "Diamond");
  * }
  * </pre>
  *
index 90e91c38d5158016fe18a729ef1f05ead0c814fb..4f2b7c9088c620180c289c6b82f48820806385aa 100644 (file)
@@ -116,8 +116,8 @@ public class LGWebOSCommandExtension extends AbstractConsoleCommandExtension imp
         if (cursorArgumentIndex <= 0) {
             return new StringsCompleter(thingRegistry.getAll().stream()
                     .filter(t -> LGWebOSBindingConstants.THING_TYPE_WEBOSTV.equals(t.getThingTypeUID()))
-                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true).complete(args,
-                            cursorArgumentIndex, cursorPosition, candidates);
+                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true)
+                    .complete(args, cursorArgumentIndex, cursorPosition, candidates);
         } else if (cursorArgumentIndex == 1) {
             Thing thing = getThing(args[0]);
             if (thing != null && LGWebOSBindingConstants.THING_TYPE_WEBOSTV.equals(thing.getThingTypeUID())) {
index cf4f495e59efe55b8fda642d2c8f6cf2aaae2065..3da31b36a84f6d125da330419194fe151c65278c 100644 (file)
@@ -140,8 +140,8 @@ public class LinkyCommandExtension extends AbstractConsoleCommandExtension imple
         if (cursorArgumentIndex <= 0) {
             return new StringsCompleter(thingRegistry.getAll().stream()
                     .filter(t -> LinkyBindingConstants.THING_TYPE_LINKY.equals(t.getThingTypeUID()))
-                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true).complete(args,
-                            cursorArgumentIndex, cursorPosition, candidates);
+                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true)
+                    .complete(args, cursorArgumentIndex, cursorPosition, candidates);
         } else if (cursorArgumentIndex == 1) {
             Thing thing = getThing(args[0]);
             if (thing != null && LinkyBindingConstants.THING_TYPE_LINKY.equals(thing.getThingTypeUID())) {
index b80b505eb5e0a0e59b8f57f45c5f22974337f364..8d213e7075cd87e3479c7e6b0f65612977844ca2 100644 (file)
@@ -76,27 +76,24 @@ public class AlarmControlPanel extends AbstractComponent<AlarmControlPanel.Chann
                 channelConfiguration.stateTriggered };
         buildChannel(STATE_CHANNEL_ID, new TextValue(stateEnum), channelConfiguration.getName(),
                 componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())//
-                        .build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())//
+                .build();
 
         String commandTopic = channelConfiguration.commandTopic;
         if (commandTopic != null) {
             buildChannel(SWITCH_DISARM_CHANNEL_ID, new TextValue(new String[] { channelConfiguration.payloadDisarm }),
                     channelConfiguration.getName(), componentConfiguration.getUpdateListener())
-                            .commandTopic(commandTopic, channelConfiguration.isRetain(), channelConfiguration.getQos())
-                            .build();
+                    .commandTopic(commandTopic, channelConfiguration.isRetain(), channelConfiguration.getQos()).build();
 
             buildChannel(SWITCH_ARM_HOME_CHANNEL_ID,
                     new TextValue(new String[] { channelConfiguration.payloadArmHome }), channelConfiguration.getName(),
                     componentConfiguration.getUpdateListener())
-                            .commandTopic(commandTopic, channelConfiguration.isRetain(), channelConfiguration.getQos())
-                            .build();
+                    .commandTopic(commandTopic, channelConfiguration.isRetain(), channelConfiguration.getQos()).build();
 
             buildChannel(SWITCH_ARM_AWAY_CHANNEL_ID,
                     new TextValue(new String[] { channelConfiguration.payloadArmAway }), channelConfiguration.getName(),
                     componentConfiguration.getUpdateListener())
-                            .commandTopic(commandTopic, channelConfiguration.isRetain(), channelConfiguration.getQos())
-                            .build();
+                    .commandTopic(commandTopic, channelConfiguration.isRetain(), channelConfiguration.getQos()).build();
         }
     }
 }
index 0e2c16e5735a68c112e1c724e8a7bef22603ae0f..9855eec9c49ce0e771e107f1caed15f1ddc59652 100644 (file)
@@ -51,7 +51,7 @@ public class ComponentFactory {
             Gson gson, TransformationServiceProvider transformationServiceProvider) throws ConfigurationException {
         ComponentConfiguration componentConfiguration = new ComponentConfiguration(thingUID, haID,
                 channelConfigurationJSON, gson, updateListener, tracker, scheduler)
-                        .transformationProvider(transformationServiceProvider);
+                .transformationProvider(transformationServiceProvider);
         switch (haID.component) {
             case "alarm_control_panel":
                 return new AlarmControlPanel(componentConfiguration);
index ca41d4730f8f6ec85de969d80dfdf6b386106cc7..ecfa3a48c69193c3fcd43510d32e7353781185cc 100644 (file)
@@ -58,9 +58,9 @@ public class Cover extends AbstractComponent<Cover.ChannelConfiguration> {
 
         buildChannel(SWITCH_CHANNEL_ID, value, channelConfiguration.getName(),
                 componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
-                        .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
-                                channelConfiguration.getQos())
-                        .build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
+                .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
+                        channelConfiguration.getQos())
+                .build();
     }
 }
index 1eb49ba3fa1215c9ac9fdf12a09d177110193cc4..55d0b310e6c978044c99b0753602943c4df37bbf 100644 (file)
@@ -71,11 +71,10 @@ public class DefaultSchemaLight extends Light {
         if (channelConfiguration.brightnessStateTopic != null || channelConfiguration.brightnessCommandTopic != null) {
             localBrightnessChannel = brightnessChannel = buildChannel(BRIGHTNESS_CHANNEL_ID, brightnessValue,
                     "Brightness", this)
-                            .stateTopic(channelConfiguration.brightnessStateTopic,
-                                    channelConfiguration.brightnessValueTemplate)
-                            .commandTopic(channelConfiguration.brightnessCommandTopic, channelConfiguration.isRetain(),
-                                    channelConfiguration.getQos())
-                            .withFormat("%.0f").commandFilter(this::handleBrightnessCommand).build(false);
+                    .stateTopic(channelConfiguration.brightnessStateTopic, channelConfiguration.brightnessValueTemplate)
+                    .commandTopic(channelConfiguration.brightnessCommandTopic, channelConfiguration.isRetain(),
+                            channelConfiguration.getQos())
+                    .withFormat("%.0f").commandFilter(this::handleBrightnessCommand).build(false);
         }
 
         if (channelConfiguration.whiteCommandTopic != null) {
@@ -111,10 +110,10 @@ public class DefaultSchemaLight extends Light {
             hasColorChannel = true;
             hiddenChannels.add(rgbChannel = buildChannel(RGB_CHANNEL_ID, new ColorValue(ColorMode.RGB, null, null, 100),
                     "RGB state", this)
-                            .stateTopic(channelConfiguration.rgbStateTopic, channelConfiguration.rgbValueTemplate)
-                            .commandTopic(channelConfiguration.rgbCommandTopic, channelConfiguration.isRetain(),
-                                    channelConfiguration.getQos())
-                            .build(false));
+                    .stateTopic(channelConfiguration.rgbStateTopic, channelConfiguration.rgbValueTemplate)
+                    .commandTopic(channelConfiguration.rgbCommandTopic, channelConfiguration.isRetain(),
+                            channelConfiguration.getQos())
+                    .build(false));
         }
 
         if (channelConfiguration.rgbwStateTopic != null || channelConfiguration.rgbwCommandTopic != null) {
@@ -140,9 +139,9 @@ public class DefaultSchemaLight extends Light {
             hiddenChannels.add(
                     xyChannel = buildChannel(XY_CHANNEL_ID, new ColorValue(ColorMode.XYY, null, null, 100), "XY State",
                             this).stateTopic(channelConfiguration.xyStateTopic, channelConfiguration.xyValueTemplate)
-                                    .commandTopic(channelConfiguration.xyCommandTopic, channelConfiguration.isRetain(),
-                                            channelConfiguration.getQos())
-                                    .build(false));
+                            .commandTopic(channelConfiguration.xyCommandTopic, channelConfiguration.isRetain(),
+                                    channelConfiguration.getQos())
+                            .build(false));
         }
 
         if (channelConfiguration.hsStateTopic != null || channelConfiguration.hsCommandTopic != null) {
index 4381911987829272ee402528b25ee028242fb1b9..a0da3587175dcbe6950932cf09b24bbf5f53799a 100644 (file)
@@ -67,7 +67,6 @@ public class DeviceTrigger extends AbstractComponent<DeviceTrigger.ChannelConfig
 
         buildChannel(channelConfiguration.type, value, channelConfiguration.getName(),
                 componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.topic, channelConfiguration.getValueTemplate()).trigger(true)
-                        .build();
+                .stateTopic(channelConfiguration.topic, channelConfiguration.getValueTemplate()).trigger(true).build();
     }
 }
index 6410706328891dc3d08efb590cf7f166244c3505..49be4ee9238c6603f9a24b9501e2a84a41f7530a 100644 (file)
@@ -56,9 +56,9 @@ public class Fan extends AbstractComponent<Fan.ChannelConfiguration> {
         OnOffValue value = new OnOffValue(channelConfiguration.payloadOn, channelConfiguration.payloadOff);
         buildChannel(SWITCH_CHANNEL_ID, value, channelConfiguration.getName(),
                 componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
-                        .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
-                                channelConfiguration.getQos(), channelConfiguration.commandTemplate)
-                        .build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
+                .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
+                        channelConfiguration.getQos(), channelConfiguration.commandTemplate)
+                .build();
     }
 }
index 8128df50827b26325028bab7587451533240f035..b50974a412aa57390136c5c82fad1f0fb2eec46d 100644 (file)
@@ -60,9 +60,9 @@ public class Lock extends AbstractComponent<Lock.ChannelConfiguration> {
         buildChannel(SWITCH_CHANNEL_ID,
                 new OnOffValue(channelConfiguration.payloadLock, channelConfiguration.payloadUnlock),
                 channelConfiguration.getName(), componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
-                        .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
-                                channelConfiguration.getQos())
-                        .build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
+                .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
+                        channelConfiguration.getQos())
+                .build();
     }
 }
index a012796c7fad7306e08ceffeb6d9767c48754a30..947f46cc41a536a51c1f0b9d31edef950049b2d0 100644 (file)
@@ -84,9 +84,9 @@ public class Number extends AbstractComponent<Number.ChannelConfiguration> {
 
         buildChannel(NUMBER_CHANNEL_ID, value, channelConfiguration.getName(),
                 componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
-                        .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
-                                channelConfiguration.getQos(), channelConfiguration.commandTemplate)
-                        .build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
+                .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
+                        channelConfiguration.getQos(), channelConfiguration.commandTemplate)
+                .build();
     }
 }
index 174278977a8421bc969e65798d53752339eaf19b..9ead86ef8af4bb2c6fbfaea2b481ee435d831fe4 100644 (file)
@@ -68,9 +68,9 @@ public class Select extends AbstractComponent<Select.ChannelConfiguration> {
 
         buildChannel(SELECT_CHANNEL_ID, value, channelConfiguration.getName(),
                 componentConfiguration.getUpdateListener())
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
-                        .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
-                                channelConfiguration.getQos(), channelConfiguration.commandTemplate)
-                        .build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())
+                .commandTopic(channelConfiguration.commandTopic, channelConfiguration.isRetain(),
+                        channelConfiguration.getQos(), channelConfiguration.commandTemplate)
+                .build();
     }
 }
index b7a1d1ef3727d09de281f27fd41d733e5cc39818..f9f8706b5b108044ff6cac56548f7f0c88ad28c9 100644 (file)
@@ -90,8 +90,8 @@ public class Sensor extends AbstractComponent<Sensor.ChannelConfiguration> {
 
         buildChannel(SENSOR_CHANNEL_ID, value, channelConfiguration.getName(),
                 getListener(componentConfiguration, value))
-                        .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())//
-                        .trigger(trigger).build();
+                .stateTopic(channelConfiguration.stateTopic, channelConfiguration.getValueTemplate())//
+                .trigger(trigger).build();
     }
 
     private ChannelStateUpdateListener getListener(ComponentFactory.ComponentConfiguration componentConfiguration,
index f6b571a74c2b9f6bb3d249fcaa7e9afabdba54eb..cd0c05229a5d321e39d1dad259a2e53ae3daea75 100644 (file)
@@ -227,8 +227,8 @@ public class AdvancedMultisensorThingHandler extends OwBaseThingHandler {
                 properties.put(PROPERTY_DS2438,
                         ds2438configuration.getAssociatedSensorIds(OwSensorType.MS_TV).get(0).getFullPath());
             }
-            default -> throw new OwException(
-                    "sensorType " + sensorType.toString() + " not supported by this thing handler");
+            default ->
+                throw new OwException("sensorType " + sensorType.toString() + " not supported by this thing handler");
         }
 
         updateProperties(properties);
index baf247b546d072103c62f6215258e4232c9e669d..b02deee8b69ac47da09effe0df9a1aeeed84e61c 100644 (file)
@@ -69,7 +69,7 @@ public class PilightConnector implements Runnable, Closeable {
 
     private final ObjectMapper outputMapper = new ObjectMapper(
             new MappingJsonFactory().configure(JsonParser.Feature.AUTO_CLOSE_SOURCE, false))
-                    .setDefaultPropertyInclusion(JsonInclude.Include.NON_NULL);
+            .setDefaultPropertyInclusion(JsonInclude.Include.NON_NULL);
 
     private @Nullable Socket socket;
     private @Nullable PrintStream printStream;
index 92f413f9af54d925158d769e2d5fce58bbdd651a..0cd9543676f44b833ddd3841a35ba0d2866a90d2 100644 (file)
@@ -126,8 +126,8 @@ public class PowermaxCommandExtension extends AbstractConsoleCommandExtension im
             return new StringsCompleter(thingRegistry.getAll().stream()
                     .filter(t -> PowermaxBindingConstants.BRIDGE_TYPE_SERIAL.equals(t.getThingTypeUID())
                             || PowermaxBindingConstants.BRIDGE_TYPE_IP.equals(t.getThingTypeUID()))
-                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true).complete(args,
-                            cursorArgumentIndex, cursorPosition, candidates);
+                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true)
+                    .complete(args, cursorArgumentIndex, cursorPosition, candidates);
         } else if (cursorArgumentIndex == 1) {
             Thing thing = getThing(args[0]);
             if (thing != null && (PowermaxBindingConstants.BRIDGE_TYPE_SERIAL.equals(thing.getThingTypeUID())
index c80acdc8f8c4c2400ce59edc12ed00cdc0eed895..1cd06d4ef4f093d4f8c9f080ffd8349e3999690d 100644 (file)
@@ -77,7 +77,7 @@ public class TestMeterReading {
         try {
             verify(changeListener, after(
                     period.toMillis() + 2 * period.toMillis() * ConnectorBase.NUMBER_OF_RETRIES + period.toMillis() / 2)
-                            .times(1)).errorOccurred(any());
+                    .times(1)).errorOccurred(any());
             verify(connector, times(ConnectorBase.NUMBER_OF_RETRIES)).retryHook(ArgumentMatchers.anyInt());
         } finally {
             disposable.dispose();
index b9ed380f8835d34ef2823307b0246d2bcbf5c24f..33f26a65d670c49e340e9319aa5d9fce04d2e5ae 100644 (file)
@@ -103,8 +103,8 @@ public class SomfyTahomaCommandExtension extends AbstractConsoleCommandExtension
         if (cursorArgumentIndex <= 0) {
             return new StringsCompleter(thingRegistry.getAll().stream()
                     .filter(t -> SomfyTahomaBindingConstants.THING_TYPE_BRIDGE.equals(t.getThingTypeUID()))
-                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true).complete(args,
-                            cursorArgumentIndex, cursorPosition, candidates);
+                    .map(t -> t.getUID().getAsString()).collect(Collectors.toList()), true)
+                    .complete(args, cursorArgumentIndex, cursorPosition, candidates);
         } else if (cursorArgumentIndex == 1) {
             Thing thing = getThing(args[0]);
             if (thing != null && SomfyTahomaBindingConstants.THING_TYPE_BRIDGE.equals(thing.getThingTypeUID())) {
index 31ab49f028f42508cc8f5403709e102826563471..ef63483a16f310a59cd2c344e2e2a81e35269dca 100644 (file)
@@ -355,7 +355,7 @@ public class SCrunProductCommand extends RunProductCommand implements SlipBridge
             // create notification product that clones the new command positions
             product = new VeluxProduct(VeluxProductName.UNKNOWN, new ProductBridgeIndex(reqIndexArray01),
                     ProductState.EXECUTING.value, setMainParameter, setMainParameter, reqFunctionalParameters, COMMAND)
-                            .overrideDataSource(DataSource.BINDING);
+                    .overrideDataSource(DataSource.BINDING);
 
             return true;
         }
index 44aa202dfb2d50c1e084886096a33659fc8cdd2e..629e816f56720bd281ec4d363c31b37d1fc0741c 100644 (file)
@@ -110,7 +110,7 @@ public class HomekitHeaterCoolerImpl extends AbstractHomekitAccessoryImpl implem
                 : getAccessoryConfiguration(HomekitCharacteristicType.CURRENT_TEMPERATURE, HomekitTaggedItem.MIN_VALUE,
                         BigDecimal.valueOf(HomekitCharacteristicFactory
                                 .convertFromCelsius(CurrentTemperatureCharacteristic.DEFAULT_MIN_VALUE)))
-                                        .doubleValue());
+                        .doubleValue());
     }
 
     @Override
index 2012ca6a0248bd9743fbdff2e97937d0003269d8..f6c1dd5c71cf73d8832706a633f879bc896549d3 100644 (file)
@@ -61,7 +61,7 @@ class HomekitTemperatureSensorImpl extends AbstractHomekitAccessoryImpl implemen
                 getAccessoryConfiguration(HomekitCharacteristicType.CURRENT_TEMPERATURE, HomekitTaggedItem.MIN_VALUE,
                         BigDecimal.valueOf(HomekitCharacteristicFactory
                                 .convertFromCelsius(CurrentTemperatureCharacteristic.DEFAULT_MIN_VALUE)))
-                                        .doubleValue());
+                        .doubleValue());
     }
 
     @Override
@@ -70,7 +70,7 @@ class HomekitTemperatureSensorImpl extends AbstractHomekitAccessoryImpl implemen
                 getAccessoryConfiguration(HomekitCharacteristicType.CURRENT_TEMPERATURE, HomekitTaggedItem.MAX_VALUE,
                         BigDecimal.valueOf(HomekitCharacteristicFactory
                                 .convertFromCelsius(CurrentTemperatureCharacteristic.DEFAULT_MAX_VALUE)))
-                                        .doubleValue());
+                        .doubleValue());
     }
 
     @Override
index ca945a8ecd4d65a188d666b0be3b7dd7190321e6..8f196e8c9de3dde4c05cc36c42185ff8d4ac5550 100644 (file)
@@ -120,7 +120,7 @@ class HomekitThermostatImpl extends AbstractHomekitAccessoryImpl implements Ther
                 getAccessoryConfiguration(HomekitCharacteristicType.CURRENT_TEMPERATURE, HomekitTaggedItem.MIN_VALUE,
                         BigDecimal.valueOf(HomekitCharacteristicFactory
                                 .convertFromCelsius(CurrentTemperatureCharacteristic.DEFAULT_MIN_VALUE)))
-                                        .doubleValue());
+                        .doubleValue());
     }
 
     @Override
@@ -129,7 +129,7 @@ class HomekitThermostatImpl extends AbstractHomekitAccessoryImpl implements Ther
                 getAccessoryConfiguration(HomekitCharacteristicType.CURRENT_TEMPERATURE, HomekitTaggedItem.MAX_VALUE,
                         BigDecimal.valueOf(HomekitCharacteristicFactory
                                 .convertFromCelsius(CurrentTemperatureCharacteristic.DEFAULT_MAX_VALUE)))
-                                        .doubleValue());
+                        .doubleValue());
     }
 
     @Override
@@ -189,7 +189,7 @@ class HomekitThermostatImpl extends AbstractHomekitAccessoryImpl implements Ther
                                 HomekitTaggedItem.MIN_VALUE,
                                 BigDecimal.valueOf(HomekitCharacteristicFactory
                                         .convertFromCelsius(TargetTemperatureCharacteristic.DEFAULT_MIN_VALUE)))
-                                                .doubleValue());
+                                .doubleValue());
     }
 
     @Override
@@ -200,7 +200,7 @@ class HomekitThermostatImpl extends AbstractHomekitAccessoryImpl implements Ther
                                 HomekitTaggedItem.MAX_VALUE,
                                 BigDecimal.valueOf(HomekitCharacteristicFactory
                                         .convertFromCelsius(TargetTemperatureCharacteristic.DEFAULT_MAX_VALUE)))
-                                                .doubleValue());
+                                .doubleValue());
     }
 
     @Override
index 54c77a0f262e217b6a2374574aac2d16dff56eed..1adddbe4729d5fe6056e72e2d40366c21761a11f 100644 (file)
@@ -33,19 +33,19 @@ public class DynamoDBBigDecimalItem extends AbstractDynamoDBItem<BigDecimal> {
 
     public static StaticTableSchema<DynamoDBBigDecimalItem> TABLE_SCHEMA_LEGACY = getBaseSchemaBuilder(
             DynamoDBBigDecimalItem.class, true).newItemSupplier(DynamoDBBigDecimalItem::new)
-                    .addAttribute(NULLABLE_BIGDECIMAL, a -> a.name(ATTRIBUTE_NAME_ITEMSTATE_LEGACY)
-                            .getter(DynamoDBBigDecimalItem::getState).setter(DynamoDBBigDecimalItem::setState))
-                    .build();
+            .addAttribute(NULLABLE_BIGDECIMAL, a -> a.name(ATTRIBUTE_NAME_ITEMSTATE_LEGACY)
+                    .getter(DynamoDBBigDecimalItem::getState).setter(DynamoDBBigDecimalItem::setState))
+            .build();
 
     public static StaticTableSchema<DynamoDBBigDecimalItem> TABLE_SCHEMA_NEW = getBaseSchemaBuilder(
             DynamoDBBigDecimalItem.class, false)
-                    .newItemSupplier(DynamoDBBigDecimalItem::new)
-                    .addAttribute(NULLABLE_BIGDECIMAL,
-                            a -> a.name(ATTRIBUTE_NAME_ITEMSTATE_NUMBER).getter(DynamoDBBigDecimalItem::getState)
-                                    .setter(DynamoDBBigDecimalItem::setState))
-                    .addAttribute(NULLABLE_LONG, a -> a.name(ATTRIBUTE_NAME_EXPIRY)
-                            .getter(AbstractDynamoDBItem::getExpiryDate).setter(AbstractDynamoDBItem::setExpiry))
-                    .build();
+            .newItemSupplier(DynamoDBBigDecimalItem::new)
+            .addAttribute(NULLABLE_BIGDECIMAL,
+                    a -> a.name(ATTRIBUTE_NAME_ITEMSTATE_NUMBER).getter(DynamoDBBigDecimalItem::getState)
+                            .setter(DynamoDBBigDecimalItem::setState))
+            .addAttribute(NULLABLE_LONG, a -> a.name(ATTRIBUTE_NAME_EXPIRY).getter(AbstractDynamoDBItem::getExpiryDate)
+                    .setter(AbstractDynamoDBItem::setExpiry))
+            .build();
 
     /**
      * We get the following error if the BigDecimal has too many digits
index 90ae5d1f637629d1e7bd317fef5b142014781b79..e905d45fa61f14ad6d9f93374e62eb72da21c6ad 100644 (file)
@@ -30,22 +30,20 @@ public class DynamoDBStringItem extends AbstractDynamoDBItem<String> {
     private static Class<@Nullable String> NULLABLE_STRING = (Class<@Nullable String>) String.class;
 
     public static final StaticTableSchema<DynamoDBStringItem> TABLE_SCHEMA_LEGACY = getBaseSchemaBuilder(
-            DynamoDBStringItem.class, true)
-                    .newItemSupplier(
-                            DynamoDBStringItem::new)
-                    .addAttribute(NULLABLE_STRING, a -> a.name(DynamoDBItem.ATTRIBUTE_NAME_ITEMSTATE_LEGACY)
-                            .getter(DynamoDBStringItem::getState).setter(DynamoDBStringItem::setState))
-                    .build();
+            DynamoDBStringItem.class, true).newItemSupplier(DynamoDBStringItem::new)
+            .addAttribute(NULLABLE_STRING, a -> a.name(DynamoDBItem.ATTRIBUTE_NAME_ITEMSTATE_LEGACY)
+                    .getter(DynamoDBStringItem::getState).setter(DynamoDBStringItem::setState))
+            .build();
 
     public static final StaticTableSchema<DynamoDBStringItem> TABLE_SCHEMA_NEW = getBaseSchemaBuilder(
             DynamoDBStringItem.class, false)
-                    .newItemSupplier(DynamoDBStringItem::new)
-                    .addAttribute(NULLABLE_STRING,
-                            a -> a.name(DynamoDBItem.ATTRIBUTE_NAME_ITEMSTATE_STRING)
-                                    .getter(DynamoDBStringItem::getState).setter(DynamoDBStringItem::setState))
-                    .addAttribute(NULLABLE_LONG, a -> a.name(ATTRIBUTE_NAME_EXPIRY)
-                            .getter(AbstractDynamoDBItem::getExpiryDate).setter(AbstractDynamoDBItem::setExpiry))
-                    .build();
+            .newItemSupplier(DynamoDBStringItem::new)
+            .addAttribute(NULLABLE_STRING,
+                    a -> a.name(DynamoDBItem.ATTRIBUTE_NAME_ITEMSTATE_STRING).getter(DynamoDBStringItem::getState)
+                            .setter(DynamoDBStringItem::setState))
+            .addAttribute(NULLABLE_LONG, a -> a.name(ATTRIBUTE_NAME_EXPIRY).getter(AbstractDynamoDBItem::getExpiryDate)
+                    .setter(AbstractDynamoDBItem::setExpiry))
+            .build();
 
     public DynamoDBStringItem() {
         this("", null, ZonedDateTime.now(), null);
index 1f064e6a2de765ea35f1b7a382bca0b6f47815aa..a884f8367dd46c345109e03916f06723c9038ed3 100644 (file)
@@ -63,7 +63,7 @@ import com.igormaznitsa.jbbp.model.JBBPFieldUShort;
  * <pre>
  * {@code
  * JsonObject json = new Bin2Json("byte a; byte b; ubyte c;").convert("03FAFF");
- * json.toString() = {"a":3,"b":-6,"c":255}
+ * json.toString() = {"a":3,"b":-6,"c":255}}
  * </pre>
  *
  * @author Pauli Anttila - Initial contribution
index 4939c156ea7220f0827f13975f3db8e215d344a7..7ed43b57253ca4343fb04fbe48d82f368bd59a07 100644 (file)
@@ -170,7 +170,7 @@ public abstract class AbstractMieleThingHandlerTest extends JavaOSGiTest {
         OAuthFactory oAuthFactory = mock(OAuthFactory.class);
         when(oAuthFactory
                 .getOAuthClientService(MieleCloudBindingIntegrationTestConstants.BRIDGE_THING_UID.getAsString()))
-                        .thenReturn(oAuthClientService);
+                .thenReturn(oAuthClientService);
 
         OpenHabOAuthTokenRefresher tokenRefresher = getService(OAuthTokenRefresher.class,
                 OpenHabOAuthTokenRefresher.class);
diff --git a/pom.xml b/pom.xml
index f8c92ff4a48451623c56ba3013076253906e721a..a775701d7f9317680a452da9ecba2524ddd2a7fa 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -77,8 +77,9 @@
     <netty.version>4.1.72.Final</netty.version>
     <okhttp.version>3.14.9</okhttp.version>
     <sat.version>0.13.0</sat.version>
-    <spotless.version>2.28.0</spotless.version>
-    <spotless.eclipse.version>4.21.0</spotless.eclipse.version>
+    <spotless.version>2.35.0</spotless.version>
+    <spotless.eclipse.version>4.26</spotless.eclipse.version>
+    <spotless.eclipse.wtp.version>4.21.0</spotless.eclipse.wtp.version>
 
     <bnd.importpackage/>
     <bnd.exportpackage/>
@@ -521,7 +522,7 @@ Import-Package: \\
                   <files>
                     <file>openhab_wst_xml_files.prefs</file>
                   </files>
-                  <version>${spotless.eclipse.version}</version>
+                  <version>${spotless.eclipse.wtp.version}</version>
                 </eclipseWtp>
                 <trimTrailingWhitespace/>
                 <endWithNewline/>
@@ -536,7 +537,7 @@ Import-Package: \\
                   <files>
                     <file>openhab_wst_feature_file.prefs</file>
                   </files>
-                  <version>${spotless.eclipse.version}</version>
+                  <version>${spotless.eclipse.wtp.version}</version>
                 </eclipseWtp>
                 <trimTrailingWhitespace/>
                 <endWithNewline/>
@@ -551,7 +552,7 @@ Import-Package: \\
                   <files>
                     <file>openhab_wst_pom_file.prefs</file>
                   </files>
-                  <version>${spotless.eclipse.version}</version>
+                  <version>${spotless.eclipse.wtp.version}</version>
                 </eclipseWtp>
                 <trimTrailingWhitespace/>
                 <endWithNewline/>