Skip to content

Commit

Permalink
Enable and apply Spotless (openhab#8401)
Browse files Browse the repository at this point in the history
Signed-off-by: Wouter Born <github@maindrain.net>
  • Loading branch information
wborn authored and CSchlipp committed Sep 12, 2020
1 parent 1e774eb commit 0c0a43d
Show file tree
Hide file tree
Showing 477 changed files with 2,886 additions and 2,332 deletions.
4 changes: 3 additions & 1 deletion bom/openhab-addons/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bom/openhab-core-index/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
13 changes: 9 additions & 4 deletions bom/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down Expand Up @@ -37,11 +39,14 @@
</goals>
<configuration>
<target>
<copy file="${basedirRoot}/../../bundles/pom.xml" overwrite="true" tofile="${basedirRoot}/../../bom/openhab-addons/pom.xml"/>
<copy file="${basedirRoot}/../../bundles/pom.xml" overwrite="true"
tofile="${basedirRoot}/../../bom/openhab-addons/pom.xml"/>
<!-- rewrite footer -->
<replaceregexp file="${basedirRoot}/../../bom/openhab-addons/pom.xml" match="/modules[\s\S]*dependencies&gt;" replace="/dependencies&gt;"/>
<replaceregexp file="${basedirRoot}/../../bom/openhab-addons/pom.xml"
match="/modules[\s\S]*dependencies&gt;" replace="/dependencies&gt;"/>
<!-- rewrite header -->
<replaceregexp file="${basedirRoot}/../../bom/openhab-addons/pom.xml" match="\S*parent[\s\S]*modules&gt;\S*" replace="header"/>
<replaceregexp file="${basedirRoot}/../../bom/openhab-addons/pom.xml"
match="\S*parent[\s\S]*modules&gt;\S*" replace="header"/>
<replace file="{basedirRoot}/../../bom/openhab-addons/pom.xml">
<replacetoken>header</replacetoken>
<replacevalue><![CDATA[<parent>
Expand Down
4 changes: 3 additions & 1 deletion bom/runtime-index/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bom/test-index/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.adorne/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.airquality/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
Expand Up @@ -45,5 +45,4 @@ public ResponseStatus getStatus() {
public AirQualityJsonData getData() {
return data;
}

}
Expand Up @@ -65,7 +65,7 @@
<label>Air Quality Index</label>
<description></description>
<category>Air Quality Index</category>
<state readOnly="true" pattern="%d" min="0" max="500" />
<state readOnly="true" pattern="%d" min="0" max="500"/>
</channel-type>

<channel-type id="aqiDescription">
Expand Down Expand Up @@ -203,7 +203,7 @@
</options>
</state>
</channel-type>

<channel-type id="aqiColor" advanced="true">
<item-type>Color</item-type>
<label>AQI Color</label>
Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.airvisualnode/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.alarmdecoder/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
Expand Up @@ -26,5 +26,4 @@
public interface IBridgeActions {

public void reboot();

}
Expand Up @@ -143,16 +143,16 @@
<!-- Virtual Zone Thing Type -->
<thing-type id="vzone">
<supported-bridge-type-refs>
<bridge-type-ref id="ipbridge" />
<bridge-type-ref id="serialbridge" />
<bridge-type-ref id="ipbridge"/>
<bridge-type-ref id="serialbridge"/>
</supported-bridge-type-refs>

<label>Virtual Zone</label>
<description>Alarm Decoder virtual zone</description>

<channels>
<channel id="command" typeId="contact-command-channel" />
<channel id="state" typeId="switch-channel" />
<channel id="command" typeId="contact-command-channel"/>
<channel id="state" typeId="switch-channel"/>
</channels>

<config-description>
Expand Down Expand Up @@ -326,7 +326,7 @@
<item-type>Switch</item-type>
<label>Switch State</label>
<category>Switch</category>
<state readOnly="false" />
<state readOnly="false"/>
</channel-type>

<!-- Number Channel Type -->
Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.allplay/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.amazondashbutton/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-v4_0_0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.amazonechocontrol/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
Expand Up @@ -1611,7 +1611,7 @@ private void queuedExecuteSequenceNode(Device device, boolean single) {

Map<String, String> headers = new HashMap<>();
headers.put("Routines-Version", "1.1.218665");

String text = executionNodeObject.text;
if (text != null && !text.isEmpty()) {
text = text.replaceAll("<.+?>", " ").replaceAll("\\s+", " ").trim();
Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.ambientweather/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.astro/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
Expand Up @@ -159,5 +159,4 @@ private static IAstroActions invokeMethodOf(@Nullable ThingActions actions) {
}
throw new IllegalArgumentException("Actions is not an instance of AstroActions");
}

}
Expand Up @@ -53,5 +53,4 @@ public void parseGeoLocation() {
}
return null;
}

}
Expand Up @@ -367,5 +367,4 @@ public void publishDailyInfo() {
public Collection<Class<? extends ThingHandlerService>> getServices() {
return Collections.singletonList(AstroActions.class);
}

}
Expand Up @@ -107,5 +107,4 @@ private Moon getMoonAt(ZonedDateTime date) {
longitude != null ? longitude : 0, localMoon);
return localMoon.getPosition();
}

}
Expand Up @@ -119,5 +119,4 @@ private Sun getSunAt(ZonedDateTime date) {
longitude != null ? longitude : 0, altitude != null ? altitude : 0, localSun);
return localSun.getPosition();
}

}
Expand Up @@ -59,5 +59,4 @@ public QuantityType<Length> getDistance() {
public void setDistance(double kilometer) {
this.distance = kilometer;
}

}
Expand Up @@ -164,5 +164,4 @@ public QuantityType<Dimensionless> getAgePercent() {
public void setAgePercent(double agePercent) {
this.agePercent = agePercent;
}

}
Expand Up @@ -84,5 +84,4 @@ public double getShadeLength() {
public void setShadeLength(double shadeLength) {
this.shadeLength = shadeLength;
}

}
Expand Up @@ -291,5 +291,4 @@ public void setPhase(SunPhase phase) {
public Map<SunPhaseName, Range> getAllRanges() {
return ranges;
}

}
Expand Up @@ -17,8 +17,8 @@
<label>Moonset</label>
<description>The moonset event range</description>
</channel-group>
<channel-group id="phase" typeId="moonPhase" />
<channel-group id="eclipse" typeId="moonEclipse" />
<channel-group id="phase" typeId="moonPhase"/>
<channel-group id="eclipse" typeId="moonEclipse"/>
<channel-group id="distance" typeId="distance">
<description>The distance to the moon</description>
</channel-group>
Expand All @@ -33,12 +33,12 @@
<channel-group id="position" typeId="position">
<description>The position of the moon</description>
</channel-group>
<channel-group id="zodiac" typeId="moonZodiac" />
<channel-group id="zodiac" typeId="moonZodiac"/>
</channel-groups>

<representation-property>geolocation</representation-property>

<config-description-ref uri="thing-type:astro:moonconfig" />
<config-description-ref uri="thing-type:astro:moonconfig"/>
</thing-type>

</thing:thing-descriptions>
Expand Up @@ -64,16 +64,16 @@
<channel-group id="position" typeId="position">
<description>The position of the sun</description>
</channel-group>
<channel-group id="radiation" typeId="radiation" />
<channel-group id="zodiac" typeId="sunZodiac" />
<channel-group id="season" typeId="season" />
<channel-group id="eclipse" typeId="sunEclipse" />
<channel-group id="phase" typeId="sunPhase" />
<channel-group id="radiation" typeId="radiation"/>
<channel-group id="zodiac" typeId="sunZodiac"/>
<channel-group id="season" typeId="season"/>
<channel-group id="eclipse" typeId="sunEclipse"/>
<channel-group id="phase" typeId="sunPhase"/>
</channel-groups>

<representation-property>geolocation</representation-property>

<config-description-ref uri="thing-type:astro:sunconfig" />
<config-description-ref uri="thing-type:astro:sunconfig"/>
</thing-type>

</thing:thing-descriptions>
Expand Up @@ -318,6 +318,5 @@ public void testAstroAndMeteoSeasons() {
assertEquals(1, meteoSun.getSeason().getSpring().get(Calendar.DAY_OF_MONTH));
assertFalse(meteoSun.getSeason().getSpring().get(Calendar.DAY_OF_MONTH) == equiSun.getSeason().getSpring()
.get(Calendar.DAY_OF_MONTH));

}
}
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.atlona/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.autelis/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 3 additions & 1 deletion bundles/org.openhab.binding.avmfritz/pom.xml
@@ -1,4 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

Expand Down

0 comments on commit 0c0a43d

Please sign in to comment.