diff --git a/README.md b/README.md index 4cd471444e3..06b306d29ac 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,6 @@ [![Jenkins Build Status](https://ci.openhab.org/job/openHAB-Core/badge/icon)](https://ci.openhab.org/job/openHAB-Core/) [![EPL-2.0](https://img.shields.io/badge/license-EPL%202-green.svg)](https://opensource.org/licenses/EPL-2.0) [![Crowdin](https://badges.crowdin.net/openhab-core/localized.svg)](https://crowdin.com/project/openhab-core) -[![Bountysource](https://www.bountysource.com/badge/tracker?tracker_id=28054058)](https://www.bountysource.com/teams/openhab/issues?tracker_ids=28054058) This project contains core bundles of the openHAB runtime. diff --git a/bundles/org.openhab.core.addon.marketplace/src/main/java/org/openhab/core/addon/marketplace/AbstractRemoteAddonService.java b/bundles/org.openhab.core.addon.marketplace/src/main/java/org/openhab/core/addon/marketplace/AbstractRemoteAddonService.java index 4aa5f4dc7be..3ce55c4f6cd 100644 --- a/bundles/org.openhab.core.addon.marketplace/src/main/java/org/openhab/core/addon/marketplace/AbstractRemoteAddonService.java +++ b/bundles/org.openhab.core.addon.marketplace/src/main/java/org/openhab/core/addon/marketplace/AbstractRemoteAddonService.java @@ -136,7 +136,7 @@ public void refreshSource() { } /** - * Add a {@link MarketplaceAddonHandler) to this service + * Add a {@link MarketplaceAddonHandler} to this service * * This needs to be implemented by the addon-services because the handlers are references to OSGi services and * the @Reference annotation is not inherited. @@ -147,7 +147,7 @@ public void refreshSource() { protected abstract void addAddonHandler(MarketplaceAddonHandler handler); /** - * Remove a {@link MarketplaceAddonHandler) from this service + * Remove a {@link MarketplaceAddonHandler} from this service * * This needs to be implemented by the addon-services because the handlers are references to OSGi services and * unbind methods can't be inherited. diff --git a/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEvent.java b/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEvent.java index e5b49aba0f9..40d084f8438 100644 --- a/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEvent.java +++ b/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEvent.java @@ -17,7 +17,8 @@ import org.openhab.core.events.AbstractEvent; /** - * This is an {@link Event} that is sent on add-on operations, such as installing and uninstalling. + * This is an {@link org.openhab.core.events.Event} that is sent on add-on operations, such as installing and + * uninstalling. * * @author Kai Kreuzer - Initial contribution */ diff --git a/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEventFactory.java b/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEventFactory.java index 9465d7fa17c..ff5ee032abf 100644 --- a/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEventFactory.java +++ b/bundles/org.openhab.core.addon/src/main/java/org/openhab/core/addon/AddonEventFactory.java @@ -25,7 +25,7 @@ * This is an {@link EventFactory} for creating add-on events. The following event types are supported by this * factory: * - * {@link AddonEventFactory#TYPE} + * {@link AddonEvent#TYPE} * * @author Kai Kreuzer - Initial contribution */ diff --git a/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioFormat.java b/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioFormat.java index 0eeb7ab2e2b..21f94ef9f14 100644 --- a/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioFormat.java +++ b/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioFormat.java @@ -44,7 +44,7 @@ public class AudioFormat { null, null); /** - * {@link AudioCodec} encoded data without any container header or footer, + * {@code AudioCodec} encoded data without any container header or footer, * e.g. MP3 is a non-container format */ public static final String CONTAINER_NONE = "NONE"; diff --git a/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioHTTPServer.java b/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioHTTPServer.java index d74b88ef989..57e1f55c105 100644 --- a/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioHTTPServer.java +++ b/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/AudioHTTPServer.java @@ -37,7 +37,7 @@ public interface AudioHTTPServer { * * @param stream the stream to serve on HTTP * @return the relative URL to access the stream starting with a '/' - * @deprecated Use {@link AudioHTTPServer#serve(AudioStream, int, boolean, CompletableFuture)} + * @deprecated Use {@link AudioHTTPServer#serve(AudioStream, int, boolean)} */ @Deprecated String serve(AudioStream stream); @@ -54,7 +54,7 @@ public interface AudioHTTPServer { * @param stream the stream to serve on HTTP * @param seconds number of seconds for which the stream is available through HTTP * @return the relative URL to access the stream starting with a '/' - * @deprecated Use {@link AudioHTTPServer#serve(AudioStream, int, boolean, CompletableFuture)} + * @deprecated Use {@link AudioHTTPServer#serve(AudioStream, int, boolean)} */ @Deprecated String serve(AudioStream stream, int seconds); diff --git a/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/utils/AudioWaveUtils.java b/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/utils/AudioWaveUtils.java index 815564cd428..f6d0df3db59 100644 --- a/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/utils/AudioWaveUtils.java +++ b/bundles/org.openhab.core.audio/src/main/java/org/openhab/core/audio/utils/AudioWaveUtils.java @@ -42,7 +42,7 @@ public class AudioWaveUtils { /** * - * @param InputStream an inputStream of a wav file to analyze. The InputStream must have a fmt header + * @param inputStream an InputStream of a wav file to analyze. The InputStream must have a fmt header * and support the mark/reset method * @return The audio format, or the default audio format if an error occured * @throws IOException If i/o exception occurs, or if the InputStream doesn't support the mark/reset @@ -84,7 +84,7 @@ public static AudioFormat parseWavFormat(InputStream inputStream) throws IOExcep * as if it is a pure PCM stream, it could try to play it and will * do a "click" noise at the beginning. * - * @param audio A wav container in an InputStream + * @param data A wav container in an InputStream * @throws IOException */ public static void removeFMT(InputStream data) throws IOException { diff --git a/bundles/org.openhab.core.audio/src/test/java/org/openhab/core/audio/internal/AudioManagerTest.java b/bundles/org.openhab.core.audio/src/test/java/org/openhab/core/audio/internal/AudioManagerTest.java index e4f505f3199..860d817e270 100644 --- a/bundles/org.openhab.core.audio/src/test/java/org/openhab/core/audio/internal/AudioManagerTest.java +++ b/bundles/org.openhab.core.audio/src/test/java/org/openhab/core/audio/internal/AudioManagerTest.java @@ -273,7 +273,7 @@ private PercentType getSinkMockVolume(PercentType initialVolume) throws IOExcept /** * - * @param param - either default source or default sink + * @param param either default source or default sink */ private void assertAddedParameterOption(String param, Locale locale) { String id = ""; diff --git a/bundles/org.openhab.core.automation.module.script.rulesupport/src/main/java/org/openhab/core/automation/module/script/rulesupport/loader/AbstractScriptFileWatcher.java b/bundles/org.openhab.core.automation.module.script.rulesupport/src/main/java/org/openhab/core/automation/module/script/rulesupport/loader/AbstractScriptFileWatcher.java index 5c4faa40c90..1177fd5c280 100644 --- a/bundles/org.openhab.core.automation.module.script.rulesupport/src/main/java/org/openhab/core/automation/module/script/rulesupport/loader/AbstractScriptFileWatcher.java +++ b/bundles/org.openhab.core.automation.module.script.rulesupport/src/main/java/org/openhab/core/automation/module/script/rulesupport/loader/AbstractScriptFileWatcher.java @@ -62,7 +62,7 @@ * * @author Simon Merschjohann - Initial contribution * @author Kai Kreuzer - improved logging and removed thread pool - * @author Jonathan Gilbert - added dependency tracking & per-script start levels; made reusable + * @author Jonathan Gilbert - added dependency tracking and per-script start levels; made reusable * @author Jan N. Klug - Refactored dependency tracking to script engine factories */ @NonNullByDefault diff --git a/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptBusEvent.java b/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptBusEvent.java index 61bf878e5c3..01d5ba319ea 100644 --- a/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptBusEvent.java +++ b/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptBusEvent.java @@ -28,7 +28,7 @@ * Items should not be updated directly (setting the state property), but updates should * be sent to the bus, so that all interested bundles are notified. * - * Note: This class is a copy from the {@link org.openhab.core.model.script.actions.BusEvent} class + * Note: This class is a copy from the {@code org.openhab.core.model.script.actions.BusEvent} class * * @author Kai Kreuzer - Initial contribution * @author Jan N. Klug - Refactored to interface diff --git a/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptThingActions.java b/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptThingActions.java index d2c10361c61..69555e1e7d2 100644 --- a/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptThingActions.java +++ b/bundles/org.openhab.core.automation.module.script/src/main/java/org/openhab/core/automation/module/script/defaultscope/ScriptThingActions.java @@ -19,7 +19,7 @@ /** * The methods of this class are made available as functions in the scripts. * - * Note: This class is a copy from the {@link org.openhab.core.model.script.internal.engine.action.ThingActionService} + * Note: This class is a copy from the {@code org.openhab.core.model.script.internal.engine.action.ThingActionService} * class * * @author Kai Kreuzer - Initial contribution diff --git a/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/ModuleHandlerCallback.java b/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/ModuleHandlerCallback.java index 97cc7ea963b..7acd1f0ef1b 100644 --- a/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/ModuleHandlerCallback.java +++ b/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/ModuleHandlerCallback.java @@ -33,12 +33,12 @@ public interface ModuleHandlerCallback { * This method gets enabled {@link RuleStatus} for a {@link Rule}. * The enabled rule statuses are {@link RuleStatus#UNINITIALIZED}, {@link RuleStatus#IDLE} and * {@link RuleStatus#RUNNING}. - * The disabled rule status is {@link RuleStatus#DISABLED}. + * The disabled rule status is {@link RuleStatusDetail#DISABLED}. * * @param ruleUID UID of the {@link Rule} * @return {@code true} when the {@link RuleStatus} is one of the {@link RuleStatus#UNINITIALIZED}, * {@link RuleStatus#IDLE} and {@link RuleStatus#RUNNING}, {@code false} when it is - * {@link RuleStatus#DISABLED} and {@code null} when it is not available. + * {@link RuleStatusDetail#DISABLED} and {@code null} when it is not available. */ @Nullable Boolean isEnabled(String ruleUID); @@ -47,7 +47,7 @@ public interface ModuleHandlerCallback { * This method is used for changing enabled state of the {@link Rule}. * The enabled rule statuses are {@link RuleStatus#UNINITIALIZED}, {@link RuleStatus#IDLE} and * {@link RuleStatus#RUNNING}. - * The disabled rule status is {@link RuleStatus#DISABLED}. + * The disabled rule status is {@link RuleStatusDetail#DISABLED}. * * @param uid the unique identifier of the {@link Rule}. * @param isEnabled a new enabled / disabled state of the {@link Rule}. @@ -59,7 +59,7 @@ public interface ModuleHandlerCallback { * * @param ruleUID UID of the {@link Rule} * @return {@link RuleStatusInfo} object containing status of the looking {@link Rule} or null when a rule with - * specified UID does not exists. + * specified UID does not exist. */ @Nullable RuleStatusInfo getStatusInfo(String ruleUID); @@ -69,7 +69,7 @@ public interface ModuleHandlerCallback { * * @param ruleUID UID of the {@link Rule} * @return {@link RuleStatus} object containing status of the looking {@link Rule} or null when a rule with - * specified UID does not exists. + * specified UID does not exist. */ @Nullable RuleStatus getStatus(String ruleUID); @@ -79,7 +79,7 @@ public interface ModuleHandlerCallback { * This should always be possible unless an action has a mandatory input that is linked to a trigger. * In that case the action is skipped and the rule engine continues execution of rest actions. * - * @param ruleUID id of the rule whose actions have to be executed. + * @param uid id of the rule whose actions have to be executed. */ void runNow(String uid); @@ -87,7 +87,7 @@ public interface ModuleHandlerCallback { * Same as {@link #runNow(String)} with the additional option to enable/disable evaluation of * conditions defined in the target rule. The context can be set here, too, but also might be {@code null}. * - * @param ruleUID id of the rule whose actions have to be executed. + * @param uid id of the rule whose actions have to be executed. * @param considerConditions if {@code true} the conditions of the rule will be checked. * @param context the context that is passed to the conditions and the actions of the rule. */ diff --git a/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/Rule.java b/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/Rule.java index f2b8de3b78e..31bb633c398 100644 --- a/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/Rule.java +++ b/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/Rule.java @@ -27,8 +27,8 @@ *
* The {@link RuleRegistry} manages the status of the Rules: *
* Whether the {@link ModuleType}s can be used by anyone, depends from their {@link Visibility} value, but they can be
* modified only by their creator.
diff --git a/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/type/ModuleTypeRegistry.java b/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/type/ModuleTypeRegistry.java
index f1b69f8c359..ba59cedbab8 100644
--- a/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/type/ModuleTypeRegistry.java
+++ b/bundles/org.openhab.core.automation/src/main/java/org/openhab/core/automation/type/ModuleTypeRegistry.java
@@ -77,7 +77,7 @@ public interface ModuleTypeRegistry extends Registry
* A {@link ConfigDescriptionParameter} instance must also contain the groupName. It should be permissible to use the
- * groupId in the {@link ConfigDesctiptionParameter} without supplying a corresponding
+ * groupId in the {@link ConfigDescriptionParameter} without supplying a corresponding
* {@link ConfigDescriptionParameterGroup} - in this way the UI can group the parameters together, but doesn't have the
* group information.
*
diff --git a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/ConfigOptionProvider.java b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/ConfigOptionProvider.java
index 3c10579a194..778e16fcebb 100644
--- a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/ConfigOptionProvider.java
+++ b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/ConfigOptionProvider.java
@@ -30,7 +30,7 @@
public interface ConfigOptionProvider {
/**
- * Provides a collection of {@link ParameterOptions}s.
+ * Provides a collection of {@link ParameterOption}s.
*
* @param uri the uri of the config description
* @param param the parameter name for which the requested options shall be returned
diff --git a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/Configuration.java b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/Configuration.java
index 50d15021043..07a4ddd7daf 100644
--- a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/Configuration.java
+++ b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/Configuration.java
@@ -26,7 +26,7 @@
import org.eclipse.jdt.annotation.Nullable;
/**
- * This class is a wrapper for configuration settings of {@link Thing}s.
+ * This class is a wrapper for configuration settings of {@code org.openhab.core.thing.Thing}s.
*
* @author Dennis Nobel - Initial contribution
* @author Kai Kreuzer - added constructors and normalization
diff --git a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/status/ConfigStatusInfo.java b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/status/ConfigStatusInfo.java
index 3b850cef6cf..e040e359f7f 100644
--- a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/status/ConfigStatusInfo.java
+++ b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/status/ConfigStatusInfo.java
@@ -42,7 +42,7 @@ public ConfigStatusInfo() {
}
/**
- * Creates a new {@link ConfigStatusInfo} with the given {@link ConfigStatusMessages}.
+ * Creates a new {@link ConfigStatusInfo} with the given {@link ConfigStatusMessage}s.
*
* @param configStatusMessages the configuration status messages to be added
*/
diff --git a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/xml/util/ConverterValueMap.java b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/xml/util/ConverterValueMap.java
index d67175c8bad..39dc4f9a02a 100644
--- a/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/xml/util/ConverterValueMap.java
+++ b/bundles/org.openhab.core.config.core/src/main/java/org/openhab/core/config/core/xml/util/ConverterValueMap.java
@@ -54,7 +54,7 @@ public ConverterValueMap(HierarchicalStreamReader reader, UnmarshallingContext c
* Creates a new instance of this class with the specified parameters.
*
* @param reader the reader to be used to read-in all children (must not be null)
- * @param numberOfValues the number of children to be read-in (< 0 = until end of section)
+ * @param numberOfValues the number of children to be read-in ({@code< 0} = until end of section)
* @param context
* @throws ConversionException if not all children could be read-in
*/
@@ -78,7 +78,7 @@ public Map
* After this method returns, no further notifications about {@link DiscoveryResult}s are allowed to be sent to any
diff --git a/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/inbox/Inbox.java b/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/inbox/Inbox.java
index ebcee6a9840..048e9e0be01 100644
--- a/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/inbox/Inbox.java
+++ b/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/inbox/Inbox.java
@@ -95,7 +95,7 @@ public interface Inbox {
* case the result object should be regarded as known by the system so that
* further processing should be skipped.
*
- * If the specified flag is {@code null}, {@link DiscoveryResultFlag.NEW} is set by default.
+ * If the specified flag is {@code null}, {@link DiscoveryResultFlag#NEW} is set by default.
*
* @param flag the flag of the given thingUID result to be set (could be null)
*/
diff --git a/bundles/org.openhab.core.ephemeris/src/main/java/org/openhab/core/ephemeris/EphemerisManager.java b/bundles/org.openhab.core.ephemeris/src/main/java/org/openhab/core/ephemeris/EphemerisManager.java
index 4ffb3417b09..1b7c92880d2 100644
--- a/bundles/org.openhab.core.ephemeris/src/main/java/org/openhab/core/ephemeris/EphemerisManager.java
+++ b/bundles/org.openhab.core.ephemeris/src/main/java/org/openhab/core/ephemeris/EphemerisManager.java
@@ -57,7 +57,7 @@ public interface EphemerisManager {
* Tests given day status against given userfile
*
* @param date observed day
- * @param url bundle resource file containing holiday definitions
+ * @param resource bundle resource file containing holiday definitions
* @return whether the day is bank holiday or not
*/
boolean isBankHoliday(ZonedDateTime date, URL resource);
@@ -66,7 +66,7 @@ public interface EphemerisManager {
* Tests given day status against given userfile
*
* @param date observed day
- * @param source absolute or relative path to the file on local file system
+ * @param filename absolute or relative path to the file on local file system
* @return whether the day is bank holiday or not
* @throws FileNotFoundException
*/
@@ -85,7 +85,7 @@ public interface EphemerisManager {
* Get given day name from given userfile
*
* @param date observed day
- * @param url bundle resource file containing holiday definitions
+ * @param resource bundle resource file containing holiday definitions
* @return name of the day or null if no corresponding entry
*/
@Nullable
@@ -95,7 +95,7 @@ public interface EphemerisManager {
* Get given day name from given userfile
*
* @param date observed day
- * @param source absolute or relative path to the file on local file system
+ * @param filename absolute or relative path to the file on local file system
* @return name of the day or null if no corresponding entry
* @throws FileNotFoundException
*/
@@ -115,7 +115,7 @@ public interface EphemerisManager {
* Gets the first next to come holiday in a 1 year time window
*
* @param startDate first day of the time window
- * @param url bundle resource file containing holiday definitions
+ * @param resource bundle resource file containing holiday definitions
* @return next coming holiday
*/
@Nullable
@@ -125,7 +125,7 @@ public interface EphemerisManager {
* Gets the first next to come holiday in a 1 year time window
*
* @param startDate first day of the time window
- * @param source absolute or relative path to the file on local file system
+ * @param filename absolute or relative path to the file on local file system
* @return next coming holiday
* @throws FileNotFoundException
*/
@@ -135,7 +135,7 @@ public interface EphemerisManager {
/**
* Gets the localized holiday description
*
- * @param holidayName code of searched holiday
+ * @param holiday code of searched holiday
* @return localized holiday description
*/
@Nullable
@@ -155,7 +155,7 @@ public interface EphemerisManager {
*
* @param from first day of the time window
* @param searchedHoliday name of the searched holiday
- * @param url bundle resource file containing holiday definitions
+ * @param resource bundle resource file containing holiday definitions
* @return difference in days, -1 if not found
*/
long getDaysUntil(ZonedDateTime from, String searchedHoliday, URL resource);
@@ -165,7 +165,7 @@ public interface EphemerisManager {
*
* @param from first day of the time window
* @param searchedHoliday name of the searched holiday
- * @param source absolute or relative path to the file on local file system
+ * @param filename absolute or relative path to the file on local file system
* @return difference in days, -1 if not found
* @throws FileNotFoundException
*/
diff --git a/bundles/org.openhab.core.id/src/main/java/org/openhab/core/id/InstanceUUID.java b/bundles/org.openhab.core.id/src/main/java/org/openhab/core/id/InstanceUUID.java
index ae05c09554a..7162133ab2a 100644
--- a/bundles/org.openhab.core.id/src/main/java/org/openhab/core/id/InstanceUUID.java
+++ b/bundles/org.openhab.core.id/src/main/java/org/openhab/core/id/InstanceUUID.java
@@ -38,7 +38,7 @@ public class InstanceUUID {
static String uuid;
/**
- * Retrieves a unified unique id, based on {@link java.util.UUID.randomUUID()}
+ * Retrieves a unified unique id, based on {@link java.util.UUID#randomUUID()}
*
* @return a UUID which identifies the instance or null, if uuid cannot be persisted
*/
diff --git a/bundles/org.openhab.core.io.console/src/main/java/org/openhab/core/io/console/ConsoleCommandCompleter.java b/bundles/org.openhab.core.io.console/src/main/java/org/openhab/core/io/console/ConsoleCommandCompleter.java
index 5e73093f76a..49518392908 100644
--- a/bundles/org.openhab.core.io.console/src/main/java/org/openhab/core/io/console/ConsoleCommandCompleter.java
+++ b/bundles/org.openhab.core.io.console/src/main/java/org/openhab/core/io/console/ConsoleCommandCompleter.java
@@ -17,8 +17,8 @@
import org.eclipse.jdt.annotation.NonNullByDefault;
/**
- * Implementing this interface allows a {@link ConsoleCommandExtension} to
- * provide completions for the user as they write commands.
+ * Implementing this interface allows a {@link org.openhab.core.io.console.extensions.ConsoleCommandExtension}
+ * to provide completions for the user as they write commands.
*
* @author Cody Cutrer - Initial contribution
*/
diff --git a/bundles/org.openhab.core.io.http/src/main/java/org/openhab/core/io/http/Handler.java b/bundles/org.openhab.core.io.http/src/main/java/org/openhab/core/io/http/Handler.java
index 6721fdbf696..a9d38b566e0 100644
--- a/bundles/org.openhab.core.io.http/src/main/java/org/openhab/core/io/http/Handler.java
+++ b/bundles/org.openhab.core.io.http/src/main/java/org/openhab/core/io/http/Handler.java
@@ -22,7 +22,7 @@
* HTTP. Handlers are called before servlet who will receive request, thus they can not mutate servlet response, but
* they can generate its own response depending on actual needs.
* Pay attention to error handling - as a proper executions might report exceptions, but fault path handled in
- * {@link #handleError(HttpServletRequest, HttpServletResponse, HandlerContext) method must remain silent and take care
+ * {@link #handleError(HttpServletRequest, HttpServletResponse, HandlerContext)} method must remain silent and take care
* of all issues which might occur while handling error.
*
* @author Ćukasz Dywicki - Initial contribution
diff --git a/bundles/org.openhab.core.io.rest.sse/src/main/java/org/openhab/core/io/rest/sse/SseResource.java b/bundles/org.openhab.core.io.rest.sse/src/main/java/org/openhab/core/io/rest/sse/SseResource.java
index cf56c06ec31..9cbb7bd28cb 100644
--- a/bundles/org.openhab.core.io.rest.sse/src/main/java/org/openhab/core/io/rest/sse/SseResource.java
+++ b/bundles/org.openhab.core.io.rest.sse/src/main/java/org/openhab/core/io/rest/sse/SseResource.java
@@ -197,8 +197,6 @@ private void handleEventBroadcastTopic(Event event) {
/**
* Subscribes the connecting client for state updates. It will initially only send a "ready" event with a unique
* connectionId that the client can use to dynamically alter the list of tracked items.
- *
- * @return {@link EventOutput} object associated with the incoming connection.
*/
@GET
@Path("/states")
diff --git a/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/LocaleService.java b/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/LocaleService.java
index c41e565e461..5f84e8b0742 100644
--- a/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/LocaleService.java
+++ b/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/LocaleService.java
@@ -28,7 +28,7 @@ public interface LocaleService {
/**
* Returns the locale in respect to the given "Accept-Language" HTTP header.
*
- * @param language value of the "Accept-Language" HTTP header (can be null).
+ * @param acceptLanguageHttpHeader value of the "Accept-Language" HTTP header (can be null).
* @return Locale for the "Accept-Language" HTTP header or default locale if
* header is not set or can not be parsed.
*/
diff --git a/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/RESTConstants.java b/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/RESTConstants.java
index 7f3c5b5affb..73a7c68474a 100644
--- a/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/RESTConstants.java
+++ b/bundles/org.openhab.core.io.rest/src/main/java/org/openhab/core/io/rest/RESTConstants.java
@@ -27,5 +27,15 @@ public class RESTConstants {
public static final String JAX_RS_NAME = "openhab";
- public static final String API_VERSION = "5";
+ /**
+ * Version of the openHAB API
+ *
+ * Version 1: initial version
+ * Version 2: include invisible widgets into sitemap response (#499)
+ * Version 3: Addition of anyFormat icon parameter (#978)
+ * Version 4: OH3, refactored extensions to addons (#1560)
+ * Version 5: transparent charts (#2502)
+ * Version 6: extended chart period parameter format (#3863)
+ */
+ public static final String API_VERSION = "6";
}
diff --git a/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/MDNSService.java b/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/MDNSService.java
index 28331c81d22..a87d46a79ff 100644
--- a/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/MDNSService.java
+++ b/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/MDNSService.java
@@ -24,14 +24,14 @@ public interface MDNSService {
/**
* This method registers a service to be announced through Bonjour/MDNS
*
- * @param serviceDescription the {@link ServiceDescription} instance with all details to identify the service
+ * @param description the {@link ServiceDescription} instance with all details to identify the service
*/
void registerService(ServiceDescription description);
/**
* This method unregisters a service not to be announced through Bonjour/MDNS
*
- * @param serviceDescription the {@link ServiceDescription} instance with all details to identify the service
+ * @param description the {@link ServiceDescription} instance with all details to identify the service
*/
void unregisterService(ServiceDescription description);
}
diff --git a/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/ServiceDescription.java b/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/ServiceDescription.java
index 3e456c67b6c..727230c99ab 100644
--- a/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/ServiceDescription.java
+++ b/bundles/org.openhab.core.io.transport.mdns/src/main/java/org/openhab/core/io/transport/mdns/ServiceDescription.java
@@ -33,7 +33,6 @@ public class ServiceDescription {
* @param serviceName String service name, like "openHAB"
* @param servicePort Int service port, like 8080
* @param serviceProperties Hashtable service props, like url = "/rest"
- * @param serviceDescription String service description text, like "openHAB REST interface"
*/
public ServiceDescription(String serviceType, String serviceName, int servicePort,
Hashtable
* Interest in specific events may be expressed using the notifyOnXXX calls.
@@ -266,7 +266,7 @@ void setSerialPortParams(int baudrate, int dataBits, int stopBits, int parity)
/**
* Sets the flow control mode value.
*
- * @param flowcontrol The flowcontrol (
* It is designed as a Java bean, for which the different properties are constraints on the query result. These
* properties include the item name, begin and end date and the item state. A compare operator can be defined to compare
- * not only state equality, but also its decimal value (<,>).
+ * not only state equality, but also its decimal value ({@code <,>}).
*
*
* Additionally, the filter criteria supports ordering and paging of the result, so the caller can ask to only return
diff --git a/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/ManagedSemanticTagProvider.java b/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/ManagedSemanticTagProvider.java
index fbb7be82559..e0df89a68be 100644
--- a/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/ManagedSemanticTagProvider.java
+++ b/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/ManagedSemanticTagProvider.java
@@ -27,8 +27,8 @@
/**
* {@link ManagedSemanticTagProvider} is an OSGi service, that allows to add or remove
- * semantic tags at runtime by calling {@link ManagedSemanticTagProvider#add(SemanticTag)}
- * or {@link ManagedSemanticTagProvider#remove(String)}.
+ * semantic tags at runtime by calling {@link ManagedSemanticTagProvider#add}
+ * or {@link ManagedSemanticTagProvider#remove}.
* An added semantic tag is automatically exposed to the {@link SemanticTagRegistry}.
* Persistence of added semantic tags is handled by a {@link StorageService}.
*
diff --git a/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/SemanticTagRegistry.java b/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/SemanticTagRegistry.java
index 7c84ab65c2c..a009bf7f534 100644
--- a/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/SemanticTagRegistry.java
+++ b/bundles/org.openhab.core.semantics/src/main/java/org/openhab/core/semantics/SemanticTagRegistry.java
@@ -42,7 +42,7 @@ public interface SemanticTagRegistry extends Registry
* The {@link Firmware} implements the {@link Comparable} interface in order to be able to sort firmwares based on their
* versions. Firmwares are sorted in a descending sequence, i.e. that the latest firmware will be the first
- * element in a sorted result set. The implementation of {@link Firmware#compareTo(Firmware)} splits the firmware
+ * element in a sorted result set. The implementation of {@link Firmware#compareTo} splits the firmware
* version by the delimiters ".", "-" and "_" and compares the different parts of the firmware version. As a result the
* firmware version 2-0-1 is newer then firmware version 2.0.0 which again is newer than firmware version
* 1-9_9.9_abc. Consequently 2.0-0, 2-0_0 and 2_0.0 represent the same firmware version.
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/FirmwareUpdateHandler.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/FirmwareUpdateHandler.java
index 60117bfba69..02c705addd5 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/FirmwareUpdateHandler.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/FirmwareUpdateHandler.java
@@ -15,6 +15,7 @@
import org.eclipse.jdt.annotation.NonNullByDefault;
import org.openhab.core.thing.Thing;
import org.openhab.core.thing.ThingStatus;
+import org.openhab.core.thing.ThingStatusDetail;
import org.openhab.core.thing.firmware.FirmwareUpdateService;
/**
@@ -53,7 +54,7 @@ public interface FirmwareUpdateHandler {
/**
* Returns true, if this firmware update handler is in a state in which the firmware update can be executed,
* otherwise false (e.g. the thing is {@link ThingStatus#OFFLINE} or its status detail is already
- * {@link ThingStatusDetail#FIRMWARE_UPDATING.)
+ * {@link ThingStatusDetail#FIRMWARE_UPDATING}.)
*
* @return true, if this firmware update handler is in a state in which the firmware update can be executed,
* otherwise false
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/ProgressCallback.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/ProgressCallback.java
index bbcf9c5db5c..70a44312c7f 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/ProgressCallback.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/binding/firmware/ProgressCallback.java
@@ -107,8 +107,9 @@ public interface ProgressCallback {
* previous defined sequence.
*
* @param progress the progress between 0 and 100
- * @throws IllegalArgumentException if given progress is < 0 or > 100
- * @throws IllegalArgumentException if given progress is smaller than old progress
+ * @throws IllegalArgumentException if given progress is {@code < 0} or {@code > 100} or if given progress is
+ * smaller than old
+ * progress
* @throws IllegalStateException if update is finished
*/
void update(int progress);
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingEventFactory.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingEventFactory.java
index ffa8a64a862..6e1c483fa89 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingEventFactory.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingEventFactory.java
@@ -320,7 +320,7 @@ public String getChannel() {
* Creates a {@link ChannelTriggeredEvent}
*
* @param event the event
- * @param channel the {@link ChannelUID}
+ * @param channelUID the {@link ChannelUID}
* @return Created {@link ChannelTriggeredEvent}
*/
public static ChannelTriggeredEvent createTriggerEvent(String event, ChannelUID channelUID) {
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingStatusInfoChangedEvent.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingStatusInfoChangedEvent.java
index ea7ffb92cc3..072585a550d 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingStatusInfoChangedEvent.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/events/ThingStatusInfoChangedEvent.java
@@ -43,8 +43,8 @@ public class ThingStatusInfoChangedEvent extends AbstractEvent {
* @param topic the topic
* @param payload the payload
* @param thingUID the thing UID
- * @param thingStatusInfo the thing status info object
- * @param thingStatusInfo the old thing status info object
+ * @param newThingStatusInfo the thing status info object
+ * @param oldThingStatusInfo the old thing status info object
*/
protected ThingStatusInfoChangedEvent(String topic, String payload, ThingUID thingUID,
ThingStatusInfo newThingStatusInfo, ThingStatusInfo oldThingStatusInfo) {
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareEventFactory.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareEventFactory.java
index 09fad627ef1..9073a9c0919 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareEventFactory.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareEventFactory.java
@@ -68,7 +68,6 @@ protected Event createEventByType(String eventType, String topic, String payload
* Creates a new {@link FirmwareStatusInfoEvent}.
*
* @param firmwareStatusInfo the firmware status information (must not be null)
- * @param thingUID the thing UID for which the new firmware status info is to be sent (must not be null)
* @return the corresponding firmware status info event
* @throws IllegalArgumentException if given firmware status info is null
*/
@@ -86,7 +85,6 @@ public static FirmwareStatusInfoEvent createFirmwareStatusInfoEvent(FirmwareStat
* Creates a new {@link FirmwareUpdateProgressInfoEvent}.
*
* @param progressInfo the progress information of the firmware update process (must not be null)
- * @param thingUID the thing UID for which the progress info is to be sent (must not be null)
* @return the corresponding progress info event
* @throws IllegalArgumentException if given progress info is null
*/
@@ -105,7 +103,6 @@ public static FirmwareUpdateProgressInfoEvent createFirmwareUpdateProgressInfoEv
* Creates a new {@link FirmwareUpdateResultInfoEvent}.
*
* @param firmwareUpdateResultInfo the firmware update result information (must not be null)
- * @param thingUID the thing UID for which the result information is to be sent (must not be null)
* @return the corresponding firmware update result info event
* @throws IllegalArgumentException if given firmware update result info event is null
*/
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareStatusInfo.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareStatusInfo.java
index 850d873e4d6..2d1cf20c501 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareStatusInfo.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/firmware/FirmwareStatusInfo.java
@@ -58,7 +58,7 @@ private FirmwareStatusInfo(ThingUID thingUID, FirmwareStatus firmwareStatus, @Nu
}
/**
- * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UNKNOWN) as firmware status.
+ * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UNKNOWN} as firmware status.
*
* @return the firmware status info (not null)
*/
@@ -67,7 +67,7 @@ public static FirmwareStatusInfo createUnknownInfo(ThingUID thingUID) {
}
/**
- * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UP_TO_DATE) as firmware status.
+ * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UP_TO_DATE} as firmware status.
*
* @return the firmware status info (not null)
*/
@@ -76,7 +76,7 @@ public static FirmwareStatusInfo createUpToDateInfo(ThingUID thingUID) {
}
/**
- * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UPDATE_AVAILABLE) as firmware status.
+ * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UPDATE_AVAILABLE} as firmware status.
*
* @return the firmware status info (not null)
*/
@@ -85,7 +85,7 @@ public static FirmwareStatusInfo createUpdateAvailableInfo(ThingUID thingUID) {
}
/**
- * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UPDATE_EXECUTBALE) as firmware status. The
+ * Creates a new {@link FirmwareStatusInfo} having {@link FirmwareStatus#UPDATE_EXECUTABLE} as firmware status. The
* given firmware version represents the version of the latest updatable firmware for the thing.
*
* @param firmwareVersion the version of the latest updatable firmware for the thing (must not be null)
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelGroupTypeI18nLocalizationService.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelGroupTypeI18nLocalizationService.java
index 462748b3590..9c9a4459476 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelGroupTypeI18nLocalizationService.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelGroupTypeI18nLocalizationService.java
@@ -37,7 +37,8 @@
* @author Markus Rathgeb - Initial contribution
* @author Markus Rathgeb - Move code from XML thing type provider to separate service
* @author Laurent Garnier - fix localized label and description for channel group definition
- * @author Christoph Weitkamp - factored out from {@link XmlChannelTypeProvider} and {@link XmlChannelGroupTypeProvider}
+ * @author Christoph Weitkamp - factored out from {@link org.openhab.core.thing.xml.internal.XmlChannelTypeProvider} and
+ * {@link org.openhab.core.thing.xml.internal.XmlChannelGroupTypeProvider}
* @author Henning Treu - factored out from {@link ThingTypeI18nLocalizationService}
* @author Christoph Weitkamp - Removed "advanced" attribute
*/
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelTypeI18nLocalizationService.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelTypeI18nLocalizationService.java
index 538593e1ddf..5dd98c3ba45 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelTypeI18nLocalizationService.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ChannelTypeI18nLocalizationService.java
@@ -45,7 +45,8 @@
* @author Markus Rathgeb - Initial contribution
* @author Markus Rathgeb - Move code from XML thing type provider to separate service
* @author Laurent Garnier - fix localized label and description for channel group definition
- * @author Christoph Weitkamp - factored out from {@link XmlChannelTypeProvider} and {@link XmlChannelGroupTypeProvider}
+ * @author Christoph Weitkamp - factored out from {@link org.openhab.core.thing.xml.internal.XmlChannelTypeProvider} and
+ * {@link org.openhab.core.thing.xml.internal.XmlChannelGroupTypeProvider}
* @author Henning Treu - factored out from {@link ThingTypeI18nLocalizationService}
*/
@Component(service = ChannelTypeI18nLocalizationService.class)
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ThingTypeI18nLocalizationService.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ThingTypeI18nLocalizationService.java
index d6a60251672..0810bd21320 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ThingTypeI18nLocalizationService.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/i18n/ThingTypeI18nLocalizationService.java
@@ -41,7 +41,8 @@
* @author Markus Rathgeb - Initial contribution
* @author Markus Rathgeb - Move code from XML thing type provider to separate service
* @author Laurent Garnier - fix localized label and description for channel group definition
- * @author Christoph Weitkamp - factored out from {@link XmlChannelTypeProvider} and {@link XmlChannelGroupTypeProvider}
+ * @author Christoph Weitkamp - factored out from {@link org.openhab.core.thing.xml.internal.XmlChannelTypeProvider} and
+ * {@link org.openhab.core.thing.xml.internal.XmlChannelGroupTypeProvider}
*/
@Component(service = ThingTypeI18nLocalizationService.class)
@NonNullByDefault
diff --git a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/internal/ThingRegistryImpl.java b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/internal/ThingRegistryImpl.java
index 7416b310a4f..860fd3999a7 100644
--- a/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/internal/ThingRegistryImpl.java
+++ b/bundles/org.openhab.core.thing/src/main/java/org/openhab/core/thing/internal/ThingRegistryImpl.java
@@ -96,7 +96,7 @@ public void updateConfiguration(ThingUID thingUID, Map
- * Attention: If you iterate over multiple channels to find the according channel types, please
- * fetch the thing type first using
- * {@link ThingTypeRegistry#getThingType(ThingTypeUID)} and use
- * {@link ThingType#getChannelType(ChannelUID)} afterwards.
- *
* @param channel channel
* @return channel type or null if no channel type was found
*/
@@ -146,12 +139,6 @@ public List
- * Attention: If you iterate over multiple channels to find the according channel types, please
- * fetch the thing type first using
- * {@link ThingTypeRegistry#getThingType(ThingTypeUID)} and use
- * {@link ThingType#getChannelType(ChannelUID)} afterwards.
- *
* @param channel channel
* @param locale locale (can be null)
* @return channel type or null if no channel type was found
diff --git a/bundles/org.openhab.core.ui.icon/src/main/java/org/openhab/core/ui/icon/IconProvider.java b/bundles/org.openhab.core.ui.icon/src/main/java/org/openhab/core/ui/icon/IconProvider.java
index 7d42d51ab88..1974d719b5b 100644
--- a/bundles/org.openhab.core.ui.icon/src/main/java/org/openhab/core/ui/icon/IconProvider.java
+++ b/bundles/org.openhab.core.ui.icon/src/main/java/org/openhab/core/ui/icon/IconProvider.java
@@ -66,9 +66,9 @@ public interface IconProvider {
/**
* retrieves the {@link InputStream} of an icon
*
- * @param iconName the icon name
+ * @param category the icon category
* @param iconSetId the id of the icon set for which the icon is requested
- * @param the string representation of the state (for the case that the icon differs for different states)
+ * @param state the string representation of the state (for the case that the icon differs for different states)
* @param format the format of the stream (usually either png or svg)
* @return a byte stream of the icon in the given format or null, if no icon exists
*/
diff --git a/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/components/RootUIComponent.java b/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/components/RootUIComponent.java
index 1fcd867c493..59665ea747c 100644
--- a/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/components/RootUIComponent.java
+++ b/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/components/RootUIComponent.java
@@ -26,7 +26,7 @@
import org.openhab.core.config.core.dto.ConfigDescriptionDTO;
/**
- * A root component is a special type of {@link Component} at the root of the hierarchy.
+ * A root component is a special type of {@link UIComponent} at the root of the hierarchy.
* It has a number of specific parameters, a set of tags, a timestamp, some configurable
* parameters ("props") and is identifiable by its UID (generally a GUID).
*
@@ -106,7 +106,7 @@ public void setTimestamp(Date date) {
}
/**
- * Updates the timestamp of the component to the current date & time.
+ * Updates the timestamp of the component to the current date and time.
*/
public void updateTimestamp() {
this.timestamp = new Date();
diff --git a/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/internal/chart/ChartServlet.java b/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/internal/chart/ChartServlet.java
index 9464e1c4195..82091f3f92f 100644
--- a/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/internal/chart/ChartServlet.java
+++ b/bundles/org.openhab.core.ui/src/main/java/org/openhab/core/ui/internal/chart/ChartServlet.java
@@ -12,15 +12,15 @@
*/
package org.openhab.core.ui.internal.chart;
-import static java.util.Map.entry;
-
import java.awt.image.BufferedImage;
import java.io.IOException;
import java.time.Duration;
import java.time.LocalDateTime;
+import java.time.Period;
import java.time.ZonedDateTime;
import java.time.format.DateTimeFormatter;
import java.time.format.DateTimeParseException;
+import java.time.temporal.TemporalAmount;
import java.util.Map;
import java.util.Objects;
import java.util.concurrent.ConcurrentHashMap;
@@ -69,6 +69,7 @@
*
* @author Chris Jackson - Initial contribution
* @author Holger Reichert - Support for themes, DPI, legend hiding
+ * @author Laurent Garnier - Extend support to ISO8601 format for chart period parameter
*/
@Component(immediate = true, service = { ChartServlet.class, Servlet.class }, configurationPid = "org.openhab.chart", //
property = Constants.SERVICE_PID + "=org.openhab.chart")
@@ -101,16 +102,6 @@ public class ChartServlet extends HttpServlet {
private static final Duration DEFAULT_PERIOD = Duration.ofDays(1);
- private static final Map
- * Please note that for the constants we follow the Java 8 Date & Time constants.
+ * Please note that for the constants we follow the Java 8 Date and Time constants.
* Major difference is the day number. In Quartz this is 0-6 for SAT-SUN while
* here it is 1-7 for MON-SUN.
*
@@ -112,9 +112,8 @@ public interface CronScheduler {
* time, the runnable will be run. The method returns a {@link ScheduledCompletableFuture}
* that can be used to stop scheduling. The run method of cronJob takes
* an environment object. An environment object is a custom interface where
- * the names of the methods are the keys in the properties (see {@link DTOs}).
+ * the names of the methods are the keys in the properties (see {@link org.openhab.core.items.dto.ItemDTO DTOs}).
*
- * @param
- *
*/
public XmlDocumentReader() {
diff --git a/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/AbstractDiscoveryService.java b/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/AbstractDiscoveryService.java
index 094ab1f484b..4427b84bec6 100644
--- a/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/AbstractDiscoveryService.java
+++ b/bundles/org.openhab.core.config.discovery/src/main/java/org/openhab/core/config/discovery/AbstractDiscoveryService.java
@@ -41,7 +41,7 @@
* The {@link AbstractDiscoveryService} provides methods which handle the {@link DiscoveryListener}s.
*
* Subclasses do not have to care about adding and removing those listeners.
- * They can use the protected methods {@link #thingDiscovered(DiscoveryResult)} and {@link #thingRemoved(String)} in
+ * They can use the protected methods {@link #thingDiscovered(DiscoveryResult)} and {@link #thingRemoved(ThingUID)} in
* order to notify the registered {@link DiscoveryListener}s.
*
* @author Oliver Libutzki - Initial contribution
@@ -83,7 +83,7 @@ public abstract class AbstractDiscoveryService implements DiscoveryService {
* service automatically stops its forced discovery process (>= 0).
* @param backgroundDiscoveryEnabledByDefault defines, whether the default for this discovery service is to
* enable background discovery or not.
- * @throws IllegalArgumentException if the timeout < 0
+ * @throws IllegalArgumentException if {@code timeout < 0}
*/
public AbstractDiscoveryService(@Nullable Set
- * This method must not block any calls such as {@link #startScan()} and must
+ * This method must not block any calls such as {@link #startScan} and must
* return fast.
* ModbusRegisterArray
array from register values
*
* @param registerValues register values, each int
corresponding to one register
- * @return
*/
public ModbusRegisterArray(int... registerValues) {
bytes = new byte[registerValues.length * 2];
diff --git a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCallback.java b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCallback.java
index d14d3caee58..a23b7521837 100644
--- a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCallback.java
+++ b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCallback.java
@@ -26,7 +26,7 @@ public interface ModbusWriteCallback extends ModbusResultCallback {
/**
* Callback handling response data
*
- * @param asyncModbusWriteResult result of the write operation
+ * @param result result of the write operation
*/
void handle(AsyncModbusWriteResult result);
}
diff --git a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCoilRequestBlueprint.java b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCoilRequestBlueprint.java
index 99ed9ae2078..8753294db14 100644
--- a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCoilRequestBlueprint.java
+++ b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteCoilRequestBlueprint.java
@@ -35,8 +35,8 @@ public class ModbusWriteCoilRequestBlueprint extends ModbusWriteRequestBlueprint
* @param slaveId slave id to write to
* @param reference reference address
* @param data bit to write
- * @param writeMultiple whether to use {@link ModbusWriteFunctionCode.WRITE_MULTIPLE_COILS} over
- * {@link ModbusWriteFunctionCode.WRITE_COIL}
+ * @param writeMultiple whether to use {@link ModbusWriteFunctionCode#WRITE_MULTIPLE_COILS} over
+ * {@link ModbusWriteFunctionCode#WRITE_COIL}
* @param maxTries maximum number of tries in case of errors, should be at least 1
*/
public ModbusWriteCoilRequestBlueprint(int slaveId, int reference, boolean data, boolean writeMultiple,
@@ -50,8 +50,8 @@ public ModbusWriteCoilRequestBlueprint(int slaveId, int reference, boolean data,
* @param slaveId slave id to write to
* @param reference reference address
* @param data bit(s) to write
- * @param writeMultiple whether to use {@link ModbusWriteFunctionCode.WRITE_MULTIPLE_COILS} over
- * {@link ModbusWriteFunctionCode.WRITE_COIL}. Useful with single bit of data.
+ * @param writeMultiple whether to use {@link ModbusWriteFunctionCode#WRITE_MULTIPLE_COILS} over
+ * {@link ModbusWriteFunctionCode#WRITE_COIL}. Useful with single bit of data.
* @param maxTries maximum number of tries in case of errors, should be at least 1
* @throws IllegalArgumentException in case data
is empty, writeMultiple
is
* false
but there are many bits to write.
diff --git a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteRegisterRequestBlueprint.java b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteRegisterRequestBlueprint.java
index b21f207a6eb..895ea0679e0 100644
--- a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteRegisterRequestBlueprint.java
+++ b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ModbusWriteRegisterRequestBlueprint.java
@@ -35,8 +35,8 @@ public class ModbusWriteRegisterRequestBlueprint extends ModbusWriteRequestBluep
* @param slaveId slave id to write to
* @param reference reference address
* @param registers register(s) to write
- * @param writeMultiple whether to use {@link ModbusWriteFunctionCode.WRITE_MULTIPLE_COILS} over
- * {@link ModbusWriteFunctionCode.WRITE_COIL}. Useful with single register of data.
+ * @param writeMultiple whether to use {@link ModbusWriteFunctionCode#WRITE_MULTIPLE_COILS} over
+ * {@link ModbusWriteFunctionCode#WRITE_COIL}. Useful with single register of data.
* @param maxTries maximum number of tries in case of errors, should be at least 1
* @throws IllegalArgumentException in case data
is empty, writeMultiple
is
* false
but there are many registers to write.
diff --git a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/PollTask.java b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/PollTask.java
index c7ece74b99b..4c962bda9ca 100644
--- a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/PollTask.java
+++ b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/PollTask.java
@@ -22,7 +22,7 @@
*
* @author Sami Salonen - Initial contribution
*
- * @see ModbusManager.registerRegularPoll
+ * @see ModbusCommunicationInterface#registerRegularPoll
*/
@NonNullByDefault
public interface PollTask extends
diff --git a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ValueBuffer.java b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ValueBuffer.java
index ed7e869223a..fdbe674dbb0 100644
--- a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ValueBuffer.java
+++ b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/ValueBuffer.java
@@ -165,7 +165,7 @@ public ValueBuffer get(byte[] dst) {
* Extract signed 8-bit integer at current position, and advance position.
*
* @return signed 8-bit integer (byte)
- * @see ModbusBitUtilities.extractSInt8
+ * @see ModbusBitUtilities#extractSInt8
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public byte getSInt8() {
@@ -176,7 +176,7 @@ public byte getSInt8() {
* Extract unsigned 8-bit integer at current position, and advance position.
*
* @return unsigned 8-bit integer
- * @see ModbusBitUtilities.extractUInt8
+ * @see ModbusBitUtilities#extractUInt8
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public short getUInt8() {
@@ -187,7 +187,7 @@ public short getUInt8() {
* Extract signed 16-bit integer at current position, and advance position.
*
* @return signed 16-bit integer (short)
- * @see ModbusBitUtilities.extractSInt16
+ * @see ModbusBitUtilities#extractSInt16
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public short getSInt16() {
@@ -198,7 +198,7 @@ public short getSInt16() {
* Extract unsigned 16-bit integer at current position, and advance position.
*
* @return unsigned 16-bit integer
- * @see ModbusBitUtilities.extractUInt16
+ * @see ModbusBitUtilities#extractUInt16
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public int getUInt16() {
@@ -209,7 +209,7 @@ public int getUInt16() {
* Extract signed 32-bit integer at current position, and advance position.
*
* @return signed 32-bit integer
- * @see ModbusBitUtilities.extractSInt32
+ * @see ModbusBitUtilities#extractSInt32
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public int getSInt32() {
@@ -220,7 +220,7 @@ public int getSInt32() {
* Extract unsigned 32-bit integer at current position, and advance position.
*
* @return unsigned 32-bit integer
- * @see ModbusBitUtilities.extractUInt32
+ * @see ModbusBitUtilities#extractUInt32
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public long getUInt32() {
@@ -233,7 +233,7 @@ public long getUInt32() {
* This is identical with getSInt32, but with registers swapped.
*
* @return signed 32-bit integer
- * @see ModbusBitUtilities.extractSInt32Swap
+ * @see ModbusBitUtilities#extractSInt32Swap
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public int getSInt32Swap() {
@@ -246,7 +246,7 @@ public int getSInt32Swap() {
* This is identical with getUInt32, but with registers swapped.
*
* @return unsigned 32-bit integer
- * @see ModbusBitUtilities.extractUInt32Swap
+ * @see ModbusBitUtilities#extractUInt32Swap
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public long getUInt32Swap() {
@@ -257,7 +257,7 @@ public long getUInt32Swap() {
* Extract signed 64-bit integer at current position, and advance position.
*
* @return signed 64-bit integer
- * @see ModbusBitUtilities.extractInt64
+ * @see ModbusBitUtilities#extractSInt64
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public long getSInt64() {
@@ -268,7 +268,7 @@ public long getSInt64() {
* Extract unsigned 64-bit integer at current position, and advance position.
*
* @return unsigned 64-bit integer
- * @see ModbusBitUtilities.extractUInt64
+ * @see ModbusBitUtilities#extractUInt64
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public BigInteger getUInt64() {
@@ -281,7 +281,7 @@ public BigInteger getUInt64() {
* This is identical with getSInt64, but with registers swapped.
*
* @return signed 64-bit integer
- * @see ModbusBitUtilities.extractInt64Swap
+ * @see ModbusBitUtilities#extractSInt64Swap
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public long getSInt64Swap() {
@@ -294,7 +294,7 @@ public long getSInt64Swap() {
* This is identical with getUInt64, but with registers swapped.
*
* @return unsigned 64-bit integer
- * @see ModbusBitUtilities.extractUInt64Swap
+ * @see ModbusBitUtilities#extractUInt64Swap
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public BigInteger getUInt64Swap() {
@@ -307,7 +307,7 @@ public BigInteger getUInt64Swap() {
* Note that this method can return floating point NaN and floating point infinity.
*
* @return single-precision 32-bit IEEE 754 floating point
- * @see ModbusBitUtilities.extractFloat32
+ * @see ModbusBitUtilities#extractFloat32
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public float getFloat32() {
@@ -322,7 +322,7 @@ public float getFloat32() {
* Note that this method can return floating point NaN and floating point infinity.
*
* @return single-precision 32-bit IEEE 754 floating point
- * @see ModbusBitUtilities.extractFloat32
+ * @see ModbusBitUtilities#extractFloat32
* @throws IllegalArgumentException when there are not enough bytes in this ValueBuffer
*/
public float getFloat32Swap() {
diff --git a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/json/WriteRequestJsonUtilities.java b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/json/WriteRequestJsonUtilities.java
index 757b3be1d76..3f8ae22bb2d 100644
--- a/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/json/WriteRequestJsonUtilities.java
+++ b/bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/json/WriteRequestJsonUtilities.java
@@ -85,10 +85,10 @@ private WriteRequestJsonUtilities() {
* protocol specification
* @throws IllegalStateException in case of parsing errors and unexpected json structure
*
- * @see WriteRequestJsonUtilities.JSON_FUNCTION_CODE
- * @see WriteRequestJsonUtilities.JSON_ADDRESS
- * @see WriteRequestJsonUtilities.JSON_VALUE
- * @see WriteRequestJsonUtilities.JSON_MAX_TRIES
+ * @see WriteRequestJsonUtilities#JSON_FUNCTION_CODE
+ * @see WriteRequestJsonUtilities#JSON_ADDRESS
+ * @see WriteRequestJsonUtilities#JSON_VALUE
+ * @see WriteRequestJsonUtilities#JSON_MAX_TRIES
*/
public static Collectionint
) parameter.
+ * @param flowcontrolRtsctsOut The flowcontrol (int
) parameter.
* @throws UnsupportedCommOperationException Unsupported Comm Operation Exception.
*/
void setFlowControlMode(int flowcontrolRtsctsOut) throws UnsupportedCommOperationException;
@@ -281,7 +281,7 @@ void setSerialPortParams(int baudrate, int dataBits, int stopBits, int parity)
/**
* Enable receive threshold with the specified thresh parameter.
*
- * @param thresh The thresh (int
) parameter.
+ * @param i The thresh (int
) parameter.
* @throws UnsupportedCommOperationException Unsupported Comm Operation Exception.
*/
void enableReceiveThreshold(int i) throws UnsupportedCommOperationException;
diff --git a/bundles/org.openhab.core.io.transport.upnp/src/main/java/org/openhab/core/io/transport/upnp/UpnpIOService.java b/bundles/org.openhab.core.io.transport.upnp/src/main/java/org/openhab/core/io/transport/upnp/UpnpIOService.java
index 36168b44855..69366df89c3 100644
--- a/bundles/org.openhab.core.io.transport.upnp/src/main/java/org/openhab/core/io/transport/upnp/UpnpIOService.java
+++ b/bundles/org.openhab.core.io.transport.upnp/src/main/java/org/openhab/core/io/transport/upnp/UpnpIOService.java
@@ -28,7 +28,7 @@ public interface UpnpIOService {
* Invoke an UPNP Action
*
* @param participant the participant to invoke the action for
- * @param serivceID the UPNP service to invoke the action upon
+ * @param serviceID the UPNP service to invoke the action upon
* @param actionID the Action to invoke
* @param inputs a map of {variable,values} to parameterize the Action that will be invoked
*/
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/CommonWebSocketServlet.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/CommonWebSocketServlet.java
index 7937ef0e39b..d1eb7e95523 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/CommonWebSocketServlet.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/CommonWebSocketServlet.java
@@ -30,6 +30,7 @@
import org.openhab.core.auth.AuthenticationException;
import org.openhab.core.auth.Role;
import org.openhab.core.io.rest.auth.AuthFilter;
+import org.openhab.core.io.websocket.event.EventWebSocketAdapter;
import org.osgi.service.component.annotations.Activate;
import org.osgi.service.component.annotations.Component;
import org.osgi.service.component.annotations.Reference;
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/WebSocketAdapter.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/WebSocketAdapter.java
index 5007e1faf10..ecf9263010b 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/WebSocketAdapter.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/WebSocketAdapter.java
@@ -35,7 +35,7 @@ public interface WebSocketAdapter {
/**
* Creates a websocket instance.
- * It should use the {@link org.eclipse.jetty.websocket.api.annotations} or implement
+ * It should use the {@code org.eclipse.jetty.websocket.api.annotations} or implement
* {@link org.eclipse.jetty.websocket.api.WebSocketListener}.
*
* @return a websocket instance.
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventDTO.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventDTO.java
similarity index 98%
rename from bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventDTO.java
rename to bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventDTO.java
index 6038e41c929..87f0138aecc 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventDTO.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventDTO.java
@@ -10,7 +10,7 @@
*
* SPDX-License-Identifier: EPL-2.0
*/
-package org.openhab.core.io.websocket;
+package org.openhab.core.io.websocket.event;
import java.util.Objects;
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventProcessingException.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventProcessingException.java
similarity index 94%
rename from bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventProcessingException.java
rename to bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventProcessingException.java
index b2a504ea61e..a83ab244214 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventProcessingException.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventProcessingException.java
@@ -10,7 +10,7 @@
*
* SPDX-License-Identifier: EPL-2.0
*/
-package org.openhab.core.io.websocket;
+package org.openhab.core.io.websocket.event;
import org.eclipse.jdt.annotation.NonNullByDefault;
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventWebSocket.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventWebSocket.java
similarity index 99%
rename from bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventWebSocket.java
rename to bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventWebSocket.java
index f37bb4cc8e2..f0136dc3532 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventWebSocket.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventWebSocket.java
@@ -10,7 +10,7 @@
*
* SPDX-License-Identifier: EPL-2.0
*/
-package org.openhab.core.io.websocket;
+package org.openhab.core.io.websocket.event;
import java.io.IOException;
import java.lang.reflect.Type;
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventWebSocketAdapter.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventWebSocketAdapter.java
similarity index 96%
rename from bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventWebSocketAdapter.java
rename to bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventWebSocketAdapter.java
index 6ef61b804cb..df905c7e3ee 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/EventWebSocketAdapter.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/EventWebSocketAdapter.java
@@ -10,7 +10,7 @@
*
* SPDX-License-Identifier: EPL-2.0
*/
-package org.openhab.core.io.websocket;
+package org.openhab.core.io.websocket.event;
import java.util.Set;
import java.util.concurrent.CopyOnWriteArraySet;
@@ -21,6 +21,7 @@
import org.openhab.core.events.Event;
import org.openhab.core.events.EventPublisher;
import org.openhab.core.events.EventSubscriber;
+import org.openhab.core.io.websocket.WebSocketAdapter;
import org.openhab.core.items.ItemRegistry;
import org.osgi.service.component.annotations.Activate;
import org.osgi.service.component.annotations.Component;
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/ItemEventUtility.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/ItemEventUtility.java
similarity index 99%
rename from bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/ItemEventUtility.java
rename to bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/ItemEventUtility.java
index e8f1d2b9ec9..547e161d0a0 100644
--- a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/ItemEventUtility.java
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/event/ItemEventUtility.java
@@ -10,7 +10,7 @@
*
* SPDX-License-Identifier: EPL-2.0
*/
-package org.openhab.core.io.websocket;
+package org.openhab.core.io.websocket.event;
import java.util.List;
import java.util.regex.Matcher;
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/log/LogDTO.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/log/LogDTO.java
new file mode 100644
index 00000000000..ff4c0587372
--- /dev/null
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/log/LogDTO.java
@@ -0,0 +1,34 @@
+/**
+ * Copyright (c) 2010-2023 Contributors to the openHAB project
+ *
+ * See the NOTICE file(s) distributed with this work for additional
+ * information.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License 2.0 which is available at
+ * http://www.eclipse.org/legal/epl-2.0
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ */
+package org.openhab.core.io.websocket.log;
+
+import java.util.Date;
+
+import org.eclipse.jdt.annotation.NonNullByDefault;
+import org.eclipse.jdt.annotation.Nullable;
+import org.openhab.core.io.websocket.event.EventDTO;
+import org.osgi.service.log.LogLevel;
+
+/**
+ * The {@link EventDTO} is used for serialization and deserialization of events
+ *
+ * @author Jan N. Klug - Initial contribution
+ */
+@NonNullByDefault
+public class LogDTO {
+ public @Nullable String loggerName;
+ public @Nullable LogLevel level;
+ public @Nullable Date timestamp;
+ public long unixtime;
+ public @Nullable String message;
+}
diff --git a/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/log/LogWebSocket.java b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/log/LogWebSocket.java
new file mode 100644
index 00000000000..e08cd24536e
--- /dev/null
+++ b/bundles/org.openhab.core.io.websocket/src/main/java/org/openhab/core/io/websocket/log/LogWebSocket.java
@@ -0,0 +1,148 @@
+/**
+ * Copyright (c) 2010-2023 Contributors to the openHAB project
+ *
+ * See the NOTICE file(s) distributed with this work for additional
+ * information.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License 2.0 which is available at
+ * http://www.eclipse.org/legal/epl-2.0
+ *
+ * SPDX-License-Identifier: EPL-2.0
+ */
+package org.openhab.core.io.websocket.log;
+
+import java.io.IOException;
+import java.util.Date;
+import java.util.List;
+import java.util.Objects;
+import java.util.function.Predicate;
+import java.util.regex.Pattern;
+
+import org.eclipse.jdt.annotation.NonNullByDefault;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.jetty.websocket.api.RemoteEndpoint;
+import org.eclipse.jetty.websocket.api.Session;
+import org.eclipse.jetty.websocket.api.StatusCode;
+import org.eclipse.jetty.websocket.api.annotations.OnWebSocketClose;
+import org.eclipse.jetty.websocket.api.annotations.OnWebSocketConnect;
+import org.eclipse.jetty.websocket.api.annotations.OnWebSocketError;
+import org.eclipse.jetty.websocket.api.annotations.OnWebSocketMessage;
+import org.eclipse.jetty.websocket.api.annotations.WebSocket;
+import org.osgi.service.log.LogEntry;
+import org.osgi.service.log.LogListener;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.google.gson.Gson;
+import com.google.gson.JsonParseException;
+import com.google.gson.reflect.TypeToken;
+
+/**
+ * The {@link LogWebSocket} is the WebSocket implementation for logs
+ *
+ * @author Jan N. Klug - Initial contribution
+ */
+@WebSocket
+@NonNullByDefault
+@SuppressWarnings("unused")
+public class LogWebSocket implements LogListener {
+ @SuppressWarnings("unchecked")
+ private static final TypeToken> STRING_LIST_TYPE = (TypeToken
>) TypeToken
+ .getParameterized(List.class, String.class);
+
+ private final Logger logger = LoggerFactory.getLogger(LogWebSocket.class);
+
+ private final LogWebSocketAdapter wsAdapter;
+ private final Gson gson;
+
+ private @Nullable Session session;
+ private @Nullable RemoteEndpoint remoteEndpoint;
+ private String remoteIdentifier = "
true
+ * @param isPreIndexingPhase whether the method is called in a pre linking phase, i.e. when the global index isn't fully updated. You
+ * must not rely on linking using the index if isPreIndexingPhase is true
*/
def dispatch void infer(RuleModel ruleModel, IJvmDeclaredTypeAcceptor acceptor, boolean isPreIndexingPhase) {
val className = ruleModel.eResource.URI.lastSegment.split("\\.").head.toFirstUpper + "Rules"
diff --git a/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/actions/CoreUtil.java b/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/actions/CoreUtil.java
index 5b35a55387c..084c286ef85 100644
--- a/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/actions/CoreUtil.java
+++ b/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/actions/CoreUtil.java
@@ -36,6 +36,14 @@ public static int hsbTosRgb(HSBType hsb) {
return ColorUtil.hsbTosRgb(hsb);
}
+ public static int[] hsbToRgbw(HSBType hsb) {
+ return ColorUtil.hsbToRgbw(hsb);
+ }
+
+ public static PercentType[] hsbToRgbwPercent(HSBType hsb) {
+ return ColorUtil.hsbToRgbwPercent(hsb);
+ }
+
public static double[] hsbToXY(HSBType hsb) {
return ColorUtil.hsbToXY(hsb);
}
diff --git a/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/formatting/ScriptFormatter.xtend b/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/formatting/ScriptFormatter.xtend
index db71387f9f8..377bf6b9509 100644
--- a/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/formatting/ScriptFormatter.xtend
+++ b/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/formatting/ScriptFormatter.xtend
@@ -26,7 +26,7 @@ import org.eclipse.xtext.formatting.impl.FormattingConfig
* see : http://www.eclipse.org/Xtext/documentation.html#formatting
* on how and when to use it
*
- * Also see {@link org.eclipse.xtext.xtext.XtextFormattingTokenSerializer} as an example
+ * Also see {@link org.eclipse.xtext.xtext.XtextFormatter} as an example
*/
class ScriptFormatter extends AbstractDeclarativeFormatter {
diff --git a/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/jvmmodel/ScriptJvmModelInferrer.xtend b/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/jvmmodel/ScriptJvmModelInferrer.xtend
index 5d871849367..98d490c2dcc 100644
--- a/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/jvmmodel/ScriptJvmModelInferrer.xtend
+++ b/bundles/org.openhab.core.model.script/src/org/openhab/core/model/script/jvmmodel/ScriptJvmModelInferrer.xtend
@@ -98,11 +98,11 @@ class ScriptJvmModelInferrer extends AbstractModelInferrer {
/**
* Is called for each instance of the first argument's type contained in a resource.
*
- * @param element - the model to create one or more JvmDeclaredTypes from.
- * @param acceptor - each created JvmDeclaredType without a container should be passed to the acceptor in order get attached to the
+ * @param script the model to create one or more JvmDeclaredTypes from.
+ * @param acceptor each created JvmDeclaredType without a container should be passed to the acceptor in order get attached to the
* current resource.
- * @param isPreLinkingPhase - whether the method is called in a pre linking phase, i.e. when the global index isn't fully updated. You
- * must not rely on linking using the index if iPrelinkingPhase is true
+ * @param isPreIndexingPhase whether the method is called in a pre linking phase, i.e. when the global index isn't fully updated. You
+ * must not rely on linking using the index if isPreIndexingPhase is true
*/
def dispatch void infer(Script script, IJvmDeclaredTypeAcceptor acceptor, boolean isPreIndexingPhase) {
val className = script.eResource.URI.lastSegment.split("\\.").head.toFirstUpper + "Script"
diff --git a/bundles/org.openhab.core.model.sitemap/src/org/openhab/core/model/sitemap/formatting/SitemapFormatter.xtend b/bundles/org.openhab.core.model.sitemap/src/org/openhab/core/model/sitemap/formatting/SitemapFormatter.xtend
index 3992a31efc1..b0272142f5f 100644
--- a/bundles/org.openhab.core.model.sitemap/src/org/openhab/core/model/sitemap/formatting/SitemapFormatter.xtend
+++ b/bundles/org.openhab.core.model.sitemap/src/org/openhab/core/model/sitemap/formatting/SitemapFormatter.xtend
@@ -26,7 +26,7 @@ import org.eclipse.xtext.formatting.impl.FormattingConfig
* see : http://www.eclipse.org/Xtext/documentation.html#formatting
* on how and when to use it
*
- * Also see {@link org.eclipse.xtext.xtext.XtextFormattingTokenSerializer} as an example
+ * Also see {@link org.eclipse.xtext.xtext.XtextFormatter} as an example
*/
class SitemapFormatter extends AbstractDeclarativeFormatter {
diff --git a/bundles/org.openhab.core.model.thing/src/org/openhab/core/model/thing/formatting/ThingFormatter.xtend b/bundles/org.openhab.core.model.thing/src/org/openhab/core/model/thing/formatting/ThingFormatter.xtend
index 0f30c797157..7f946285220 100644
--- a/bundles/org.openhab.core.model.thing/src/org/openhab/core/model/thing/formatting/ThingFormatter.xtend
+++ b/bundles/org.openhab.core.model.thing/src/org/openhab/core/model/thing/formatting/ThingFormatter.xtend
@@ -26,7 +26,7 @@ import org.eclipse.xtext.formatting.impl.FormattingConfig
* see : http://www.eclipse.org/Xtext/documentation.html#formatting
* on how and when to use it
*
- * Also see {@link org.eclipse.xtext.xtext.XtextFormattingTokenSerializer} as an example
+ * Also see {@link org.eclipse.xtext.xtext.XtextFormatter} as an example
*/
class ThingFormatter extends AbstractDeclarativeFormatter {
diff --git a/bundles/org.openhab.core.persistence/src/main/java/org/openhab/core/persistence/FilterCriteria.java b/bundles/org.openhab.core.persistence/src/main/java/org/openhab/core/persistence/FilterCriteria.java
index 132660ea71b..73964aadf21 100644
--- a/bundles/org.openhab.core.persistence/src/main/java/org/openhab/core/persistence/FilterCriteria.java
+++ b/bundles/org.openhab.core.persistence/src/main/java/org/openhab/core/persistence/FilterCriteria.java
@@ -24,7 +24,7 @@
* {@code
* HTTP/1.1 302 Found
* Location: https://client.example.com/cb?code=SplxlOBeZQQYbYS6WxSbIA&state=xyz
+ * }
+ *
* @return AuthorizationCode This authorizationCode can be used in the call {#getOAuthTokenByAuthCode(String)}
* @throws OAuthException If the state from redirectURLwithParams does not exactly match the expectedState, or
* exceptions arise while parsing redirectURLwithParams.
diff --git a/bundles/org.openhab.core/src/main/java/org/openhab/core/cache/ExpiringCache.java b/bundles/org.openhab.core/src/main/java/org/openhab/core/cache/ExpiringCache.java
index 15cc1b002f1..9263dfba1f2 100644
--- a/bundles/org.openhab.core/src/main/java/org/openhab/core/cache/ExpiringCache.java
+++ b/bundles/org.openhab.core/src/main/java/org/openhab/core/cache/ExpiringCache.java
@@ -43,7 +43,7 @@ public class ExpiringCache
+ *
*
* @param str the input xml as String to escape, may be null
* @return the escaped xml as String, may be null
@@ -96,7 +96,7 @@ public class StringUtils {
* "'cat'" => "'cat'"
*
*
- * @param val the String to capitalize, may be null
+ * @param str the String to capitalize, may be null
* @return the capitalized String, may be null
*/
public static @Nullable String capitalize(@Nullable String str) {
@@ -289,15 +289,15 @@ public static String[] splitByCharacterType(@Nullable String str) {
* Simple method to un escape XML special characters in String.
* There are five XML Special characters which needs to be escaped:
*
- * {@code
* & - &
* < - <
* > - >
* " - "
* ' - '
- *
+ * }
+ *
*
- * @param input the input xml as String to unescape, may be null
+ * @param str the input xml as String to unescape, may be null
* @return the unescaped xml as String, may be null
*/
public static @Nullable String unEscapeXml(@Nullable String str) {
diff --git a/bundles/org.openhab.core/src/test/java/org/openhab/core/util/ColorUtilTest.java b/bundles/org.openhab.core/src/test/java/org/openhab/core/util/ColorUtilTest.java
index 21acc54d127..1f02ffa9aa7 100644
--- a/bundles/org.openhab.core/src/test/java/org/openhab/core/util/ColorUtilTest.java
+++ b/bundles/org.openhab.core/src/test/java/org/openhab/core/util/ColorUtilTest.java
@@ -59,6 +59,72 @@ public void inversionTest(HSBType hsb) {
assertThat(deltaBri, is(lessThanOrEqualTo(1.0)));
}
+ @Test
+ public void hsbToRgbwTest() {
+ HSBType hsb = HSBType.WHITE;
+ PercentType[] rgbw = ColorUtil.hsbToRgbwPercent(hsb);
+ assertEquals(0.0, rgbw[0].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[1].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[2].doubleValue(), 0.01);
+ assertEquals(100.0, rgbw[3].doubleValue(), 0.01);
+
+ hsb = HSBType.BLACK;
+ rgbw = ColorUtil.hsbToRgbwPercent(hsb);
+ assertEquals(0.0, rgbw[0].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[1].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[2].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[3].doubleValue(), 0.01);
+
+ hsb = HSBType.RED;
+ rgbw = ColorUtil.hsbToRgbwPercent(hsb);
+ assertEquals(100.0, rgbw[0].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[1].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[2].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[3].doubleValue(), 0.01);
+
+ hsb = HSBType.GREEN;
+ rgbw = ColorUtil.hsbToRgbwPercent(hsb);
+ assertEquals(0.0, rgbw[0].doubleValue(), 0.01);
+ assertEquals(100.0, rgbw[1].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[2].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[3].doubleValue(), 0.01);
+
+ hsb = HSBType.BLUE;
+ rgbw = ColorUtil.hsbToRgbwPercent(hsb);
+ assertEquals(0.0, rgbw[0].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[1].doubleValue(), 0.01);
+ assertEquals(100.0, rgbw[2].doubleValue(), 0.01);
+ assertEquals(0.0, rgbw[3].doubleValue(), 0.01);
+ }
+
+ @Test
+ public void rgbwToHsbTest() {
+ // Test Red
+ HSBType hsb = ColorUtil.rgbToHsb(new int[] { 255, 0, 0, 0 });
+ int[] convertedRgb = ColorUtil.hsbToRgb(hsb);
+ assertRgbEquals(new int[] { 255, 0, 0 }, convertedRgb);
+
+ // Test Green
+ hsb = ColorUtil.rgbToHsb(new int[] { 0, 255, 0, 0 });
+ convertedRgb = ColorUtil.hsbToRgb(hsb);
+ assertRgbEquals(new int[] { 0, 255, 0 }, convertedRgb);
+
+ // Test Blue
+ hsb = ColorUtil.rgbToHsb(new int[] { 0, 0, 255, 0 });
+ convertedRgb = ColorUtil.hsbToRgb(hsb);
+ assertRgbEquals(new int[] { 0, 0, 255 }, convertedRgb);
+
+ // Test White
+ hsb = ColorUtil.rgbToHsb(new int[] { 0, 0, 0, 255 });
+ convertedRgb = ColorUtil.hsbToRgb(hsb);
+ assertRgbEquals(new int[] { 255, 255, 255 }, convertedRgb);
+
+ // Test Black
+ hsb = ColorUtil.rgbToHsb(new int[] { 0, 0, 0, 0 });
+ convertedRgb = ColorUtil.hsbToRgb(hsb);
+ assertRgbEquals(new int[] { 0, 0, 0 }, convertedRgb);
+ }
+
@ParameterizedTest
@MethodSource("invalids")
public void invalidXyValues(double[] xy) {
{@code
* & => &
* < => <
* > => >
* " => "
* ' => '
- *
+ * }