]> git.basschouten.com Git - openhab-addons.git/commitdiff
Link to Java 17 documentation (#15406)
authorWouter Born <github@maindrain.net>
Sun, 13 Aug 2023 11:44:05 +0000 (13:44 +0200)
committerGitHub <noreply@github.com>
Sun, 13 Aug 2023 11:44:05 +0000 (13:44 +0200)
This prevents issues because older documentation may not apply to Java 17.

Signed-off-by: Wouter Born <github@maindrain.net>
12 files changed:
bundles/org.openhab.automation.jsscripting/README.md
bundles/org.openhab.binding.exec/README.md
bundles/org.openhab.binding.logreader/README.md
bundles/org.openhab.binding.mqtt.generic/README.md
bundles/org.openhab.binding.mqtt/src/main/java/org/openhab/binding/mqtt/internal/ssl/PinTrustManager.java
bundles/org.openhab.binding.mqtt/xtend_examples.md
bundles/org.openhab.binding.network/src/main/java/org/openhab/binding/network/internal/PresenceDetection.java
bundles/org.openhab.binding.ntp/README.md
bundles/org.openhab.binding.telegram/README.md
bundles/org.openhab.io.metrics/README.md
bundles/org.openhab.transform.map/README.md
bundles/org.openhab.transform.regex/README.md

index d2112f77ca670678fb966a9a4638a9fe19df1bf7..bc9655c5bc2b3c9e368092ca233b99d4f3bb7435 100644 (file)
@@ -1319,11 +1319,11 @@ var { ON, OFF, QuantityType } = require("@runtime");
 |-------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------|
 | `State`                 | [`org.openhab.core.types.State`](https://www.openhab.org/javadoc/latest/org/openhab/core/types/state)                                                 |
 | `Command`               | [`org.openhab.core.types.Command`](https://www.openhab.org/javadoc/latest/org/openhab/core/types/command)                                             |
-| `URLEncoder`            | [`java.net.URLEncoder`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/net/URLEncoder.html)                                        |
-| `File`                  | [`java.io.File`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/File.html)                                                      |
-| `Files`                 | [`java.nio.file.Files`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/file/Files.html)                                        |
-| `Path`                  | [`java.nio.file.Path`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/file/Path.html)                                          |
-| `Paths`                 | [`java.nio.file.Paths`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/file/Paths.html)                                        |
+| `URLEncoder`            | [`java.net.URLEncoder`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/net/URLEncoder.html)                                        |
+| `File`                  | [`java.io.File`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/File.html)                                                      |
+| `Files`                 | [`java.nio.file.Files`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Files.html)                                        |
+| `Path`                  | [`java.nio.file.Path`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Path.html)                                          |
+| `Paths`                 | [`java.nio.file.Paths`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/nio/file/Paths.html)                                        |
 | `IncreaseDecreaseType`  | [`org.openhab.core.library.types.IncreaseDecreaseType`](https://www.openhab.org/javadoc/latest/org/openhab/core/library/types/increasedecreasetype)   |
 | `DECREASE`              | `IncreaseDecreaseType` enum item                                                                                                                      |
 | `INCREASE`              | `IncreaseDecreaseType` enum item                                                                                                                      |
@@ -1367,10 +1367,10 @@ var { ON, OFF, QuantityType } = require("@runtime");
 | `MetricPrefix`          | [`org.openhab.core.library.unit.MetricPrefix`](https://www.openhab.org/javadoc/latest/org/openhab/core/library/unit/metricprefix)                     |
 | `Units`                 | [`org.openhab.core.library.unit.Units`](https://www.openhab.org/javadoc/latest/org/openhab/core/library/unit/units)                                   |
 | `BinaryPrefix`          | [`org.openhab.core.library.unit.BinaryPrefix`](https://www.openhab.org/javadoc/latest/org/openhab/core/library/unit/binaryprefix)                     |
-| `ChronoUnit`            | [`java.time.temporal.ChronoUnit`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/time/temporal/ChronoUnit.html)                    |
-| `Duration`              | [`java.time.Duration`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/time/Duration.html)                                          |
-| `ZoneId`                | [`java.time.ZoneId`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/time/ZoneId.html)                                              |
-| `ZonedDateTime`         | [`java.time.ZonedDateTime`](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/time/ZonedDateTime.html)                                |
+| `ChronoUnit`            | [`java.time.temporal.ChronoUnit`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/time/temporal/ChronoUnit.html)                    |
+| `Duration`              | [`java.time.Duration`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/time/Duration.html)                                          |
+| `ZoneId`                | [`java.time.ZoneId`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/time/ZoneId.html)                                              |
+| `ZonedDateTime`         | [`java.time.ZonedDateTime`](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/time/ZonedDateTime.html)                                |
 
 `require("@runtime")` also defines "services" such as `items`, `things`, `rules`, `events`, `actions`, `ir`, `itemRegistry`.
 You can use these services for backwards compatibility purposes or ease migration from JSR223 scripts.
index 6d0f52b0f5c30c8c10b52894775efbf616424030..4d82de4216a02373eb8b5d6aac09dfbbc132c2f3 100644 (file)
@@ -47,7 +47,7 @@ For each shell command, a separate Thing has to be defined.
 Thing exec:command:uniquename [command="/command/to/execute here", interval=15, timeout=5, autorun=false]
 ```
 
-The `command` itself can be enhanced using the well known syntax of the [Java formatter class syntax](https://docs.oracle.com/javase/8/docs/api/java/util/Formatter.html#syntax).
+The `command` itself can be enhanced using the well known syntax of the [Java formatter class syntax](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Formatter.html#syntax).
 The following parameters are automatically added:
 
 - the current date (as java.util.Date, example: `%1$tY-%1$tm-%1$td`)
index be3117e69ec04df3228378f993a86ed6788b006a..a31e218e283b1fae005ae294638ce3de3c49f960 100644 (file)
@@ -27,7 +27,7 @@ The `reader` Thing has the following configuration parameters:
 | `customPatterns`              | String  |   no     |                                  | Search patterns separated by \| character for custom events.                            |
 | `customBlacklistingPatterns`  | String  |   no     |                                  | Search patterns for blacklisting unwanted custom events separated by \| character.      |
 
-Search patterns follows [Java regular expression syntax](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/regex/Pattern.html).
+Search patterns follows [Java regular expression syntax](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/regex/Pattern.html).
 Be aware that search patterns are case sensitive.
 
 ## Channels
index 7601509caa8bd15ccae1fdb13c6c032fa48c2d51..46aae9e0eeac7b75ddef289eeac50cace3c35321 100644 (file)
@@ -303,7 +303,7 @@ Please note that value will be discarded and not sent if one transformation fail
 
 This feature is quite powerful in transforming an item state before it is published to the MQTT broker.
 It has the syntax: `%[flags][width]conversion`.
-Find the full documentation on the [Java](https://docs.oracle.com/javase/8/docs/api/java/util/Formatter.html) web page.
+Find the full documentation on the [Java](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Formatter.html) web page.
 
 The default is "%s" which means: Output the item state as string.
 
index e3609899a94e86f1673d6f5bc14cc2fd42f9ed08..9a1a9f36ef6c68f81f6da642d12bd2089cfdf7dc 100644 (file)
@@ -71,7 +71,7 @@ public class PinTrustManager extends X509ExtendedTrustManager {
 
     /**
      * A signature name depends on the security provider but usually follows
-     * https://docs.oracle.com/javase/8/docs/technotes/guides/security/StandardNames.html#Signature.
+     * https://docs.oracle.com/en/java/javase/17/docs/specs/security/standard-names.html#signature-algorithms.
      * E.g.: "SHA256withRSA". We need "SHA" and "256" to initialize a {@link PinMessageDigest}.
      */
     PinMessageDigest getMessageDigestForSigAlg(String sigAlg) throws CertificateException {
index 8735256794f289548aa08be6faf23ed091ecd7d1..64e44d3c1ba823adf6ca1d9e3da37d1effa65d44 100644 (file)
@@ -39,7 +39,7 @@ mqtt:broker:myAuthentificatedBroker [ host="192.168.0.43", secure=false, usernam
 In a fourth connection, the public key pinning is enabled again.
 This time, a public key hash is provided to pin the connection to a specific server.
 It follows the form "hashname:hashvalue". Valid _hashnames_ are SHA-1, SHA-224, SHA-256, SHA-384, SHA-512 and all others listed
-in [Java MessageDigest Algorithms](https://docs.oracle.com/javase/9/docs/specs/security/standard-names.html#messagedigest-algorithms).
+in [Java MessageDigest Algorithms](https://docs.oracle.com/en/java/javase/17/docs/specs/security/standard-names.html#messagedigest-algorithms).
 
 `mqttConnections.things`:
 
index 0877cbb89a97bfa2fed4f08edefa552cb15118ad..1ec2845c742d3d3297fba99fa716fa6559d428af 100644 (file)
@@ -506,7 +506,7 @@ public class PresenceDetection implements IPRequestReceivedCallback {
      * Performs a java ping. It is not recommended to use this, as it is not interruptible,
      * and will not work on windows systems reliably and will fall back from ICMP pings to
      * the TCP echo service on port 7 which barely no device or server supports nowadays.
-     * (http://docs.oracle.com/javase/7/docs/api/java/net/InetAddress.html#isReachable%28int%29)
+     * (https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/net/InetAddress.html#isReachable%28int%29)
      */
     protected void performJavaPing() {
         logger.trace("Perform java ping presence detection for {}", hostname);
index a79c46901d6c162adcb9a70c026524e52006e95c..8289d5278f6b9087601932bc0b111c5a9b23e114 100644 (file)
@@ -33,7 +33,7 @@ The ntp binding has two channels:
 - `dateTime` which provides the data in a dateTime type
 - `string` which provides the data in a string type. The string channel can be configured with the formatting of the date & time. This also allows proper representation of timezones other than the java machine default one.
 
-See the [java documentation](https://docs.oracle.com/javase/8/docs/api/java/util/Formatter.html) for the detailed information on the formatting
+See the [Java documentation](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Formatter.html) for the detailed information on the formatting
 
 ## Full Example
 
index 0ff1b33de3b395ce1b3bc22fa7d3ad6185d07c73..b24517f2c25d315e3284b0ce12324c1b15710067 100644 (file)
@@ -196,7 +196,7 @@ These actions will send a message to all chat ids configured for this bot.
 | Action                     | Description  |
 |----------------------------|--------------|
 | sendTelegram(String message) | Sends a message. |
-| sendTelegram(String format, Object... args)          | Sends a formatted message (See <https://docs.oracle.com/javase/8/docs/api/java/util/Formatter.html> for more information).
+| sendTelegram(String format, Object... args)          | Sends a formatted message (See <https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Formatter.html> for more information).
 | sendTelegramQuery(String message, String replyId, String... buttons) | Sends a question to the user that can be answered via the defined buttons. The replyId can be freely choosen and is sent back with the answer. Then, the id is required to identify what question has been answered (e.g. in case of multiple open questions). The final result looks like this: ![Telegram Inline Keyboard](doc/queryExample.png). |
 | sendTelegramAnswer(String replyId, String message) | Sends a message after the user has answered a question. You should _always_ call this method after you received an answer. It will remove buttons from the specific question and will also stop the progress bar displayed at the client side. If no message is necessary, just pass `null` here. |
 | sendTelegramPhoto(String photoURL, String caption) | Sends a picture. Can be one of the URL formats, see the Note below, or a base64 encoded image (simple base64 data or data URI scheme). |
index b4783e5ae5c4940ee998404bd400b07d6d8c4c89..d126720dd7dba1a8facda50d417decd129dfb05e 100644 (file)
@@ -82,7 +82,7 @@ The InfluxDB exporter service will start as soon as the _influxMetricsEnabled_ c
 
 The Java Management Extensions (JMX) exporter service will start as soon as the _jmxMetricsEnabled_ configuration parameter is set to true.
 
-You can monitor the JMX metrics using a tool like [JConsole](https://docs.oracle.com/en/java/javase/11/management/using-jconsole.html) or [VisualVM](https://visualvm.github.io/) (after installing the VisualVM-MBeans plugin).
+You can monitor the JMX metrics using a tool like [JConsole](https://docs.oracle.com/en/java/javase/17/management/using-jconsole.html) or [VisualVM](https://visualvm.github.io/) (after installing the VisualVM-MBeans plugin).
 When the JMX exporter is enabled, the metrics will be available under the "metrics" MBean.
 JConsole and VisualVM will only be able to connect using JMX when openHAB is started in debug mode (use `start_debug.sh` or `start_debug.bat`).
 
index c70d7fbaf7e5684bceb2eaeee3cc5ddbf659c13d..ebd0873649b8fcd3b6eebd88635d221c15819b15 100644 (file)
@@ -4,7 +4,7 @@ Transforms the input by mapping it to another string. It expects the mappings to
 The file name must have the `.map` extension. 
 
 This file should be in property syntax, i.e. simple lines with "key=value" pairs. 
-The file format is documented [here](https://docs.oracle.com/javase/8/docs/api/java/util/Properties.html#load-java.io.Reader-).
+The file format is documented [here](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Properties.html#load(java.io.Reader)).
 To organize the various transformations one might use subfolders.
 
 A default value can be provided if no matching entry is found by using "=value" syntax. 
index 0a8f255b88b7b7507564584c247155caba22e55f..73ea4c92006b7f32291f12198f6687c4bed14076 100644 (file)
@@ -8,7 +8,7 @@ A full regex is in the form `s/<regex>/<substitution>/g` whereat the delimiter `
 The regular expression in the format `s/<regex>/result/g`, replaces all occurrences of `<regex>` in the source string with `result`.
 The regular expression in the format `s/<regex>/result/` (without `g`), replaces the first occurrence of `<regex>` in the source string with `result`.
 
-If the regular expression contains a [capture group](https://docs.oracle.com/javase/8/docs/api/java/util/regex/Pattern.html#cg) defined by `()`, it returns the captured string. 
+If the regular expression contains a [capture group](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/regex/Pattern.html#cg) defined by `()`, it returns the captured string.
 Multiple capture groups can be used to retrieve multiple strings and can be combined as a result string defined in the `substitution`.
 
 The transformation can be set to be restricted to only match if the input string begins with a character by prepending `^` to the beginning of a pattern or to only match if the input string ends with a specified character by appending `$` at the end.