Skip to content

Commit

Permalink
[MainUI] Update openhab-js tern defs (#1576)
Browse files Browse the repository at this point in the history
This updated the tern definitions for the openhab-js version included
in the addon (3.1.2).

Reference
openhab/openhab-js@v3.0.0...v3.1.2.

Signed-off-by: Florian Hotze <[email protected]>
  • Loading branch information
florian-h05 authored Dec 12, 2022
1 parent e77e3f4 commit b4aff86
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions bundles/org.openhab.ui/web/src/assets/openhab-js-tern-defs.json
Original file line number Diff line number Diff line change
Expand Up @@ -350,17 +350,31 @@
}
},
"CacheNamespace": {
"shared": {
"!doc": "Shared cache that is shared across all rules and scripts, it can therefore be accessed from any automation language. A key is removed when all scripts that ever accessed it are unloaded, if the key stores a timer, the timer is cancelled.",
"!type": "JSCache"
},
"private": {
"!doc": "Private cache for each script. It can only be accessed by the same script and is cleared when the script is unloaded. When the script is unloaded, all timers in the script are cancelled.",
"!type": "JSCache"
}
},
"JSCache": {
"get": {
"!doc": "Returns the value to which the specified key is mapped",
"!doc": "Returns the value to which the specified key is mapped. The optional defaultSupplier will return a default value if the key has no associated value.",
"!type": "fn(key: string, defaultSupplier?: fn()) -> ?"
},
"put": {
"!doc": "Associates the specified value with the specified key",
"!doc": "Associates the specified value with the specified key.",
"!type": "fn(key: string, value: ?) -> ?"
},
"remove": {
"!doc": "Removes the mapping for a key from this map if it is present",
"!doc": "Removes the mapping for a key from this map if it is present.",
"!type": "fn(key: string) -> ?"
},
"exists": {
"!doc": "Checks whether a value is associated with the given key.",
"!type": "fn(key: string) -> boolean"
}
},
"Timer": {
Expand Down Expand Up @@ -637,7 +651,7 @@
"!type": "ThingsNamespace"
},
"cache": {
"!doc": "Shared cache namespace. This namespace provides a default cache that can be use to set and retrieve objects that will be persisted between reloads of scripts.",
"!doc": "Cache namespace. This namespace provides caches that can be used to set and retrieve objects that will be persisted between reloads of scripts.",
"!type": "CacheNamespace"
},
"log": {
Expand Down

0 comments on commit b4aff86

Please sign in to comment.