Skip to content

Commit 39d3949

Browse files
author
Ravi Nadahar
committed
Complete actions
1 parent 2604888 commit 39d3949

2 files changed

Lines changed: 19 additions & 13 deletions

File tree

concepts/rules.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,13 @@ Available types of conditions include:
208208
The script condition is the most universal one, as you can choose one of the many available script/rule languages to build any condition you can think of.
209209
The only restriction is a script condition's last executed line of code must result in a boolean (i.e. `true` or `false`).
210210

211-
## Scripts
211+
## Actions
212+
213+
Once a rule has triggered, and all conditions have been met, the rule will execute one or more actions.
214+
These are what makes the rule actually _do something_.
215+
OpenHAB has a set of [standard actions with specific definitions](./standard-actions.md).
216+
217+
### Scripts
212218

213219
Unfortunately the term "Script" is overloaded in openHAB, and has multiple meanings based on the context:
214220

@@ -224,7 +230,7 @@ Unfortunately the term "Script" is overloaded in openHAB, and has multiple meani
224230

225231
These rule docs mainly refer to the first two meanings when talking about scripts.
226232

227-
## Script Actions
233+
### Script Actions
228234

229235
Script Actions are an action that allow you to run logic written in one of the available automation/rule languages, e.g. JavaScript, Rules DSL, Blockly.
230236

concepts/standard-actions.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -42,37 +42,37 @@ This action sends a `Command` to an `Item`.
4242

4343
| Parameter | Description |
4444
|------------|-----------------------------------------------------------------------------------------|
45-
| `itemName` | The name of the `Item`. |
46-
| `command` | The `Command` to send. |
45+
| `itemName` | The name of the `Item`. |
46+
| `command` | The `Command` to send. |
4747

4848
### `core.ItemStateUpdateAction`
4949

5050
This action updates the `State` of an `Item`.
5151

5252
| Parameter | Description |
5353
|------------|-----------------------------------------------------------------------------------------|
54-
| `itemName` | The name of the `Item`. |
55-
| `state` | The `State` to set. |
54+
| `itemName` | The name of the `Item`. |
55+
| `state` | The `State` to set. |
5656

5757
### `media.PlayAction`
5858

5959
This action plays an audio file.
6060

6161
| Parameter | Description |
6262
|-------------|-----------------------------------------------------------------------------------------|
63-
| `sound` | The filename of the file from the `sounds` folder. |
64-
| `[sink]` | The ID of the audio sink to use. Leave out to use the default. |
65-
| `[volume]` | The volume to be used. Leave out to use the default. |
63+
| `sound` | The filename of the file from the `sounds` folder. |
64+
| `[sink]` | The ID of the audio sink to use. Leave out to use the default. |
65+
| `[volume]` | The volume to be used. Leave out to use the default. |
6666

6767
### `media.SayAction`
6868

6969
This action uses the voice system to say the specified text.
7070

7171
| Parameter | Description |
7272
|-------------|-----------------------------------------------------------------------------------------|
73-
| `text` | The text to say. |
74-
| `[sink]` | The ID of the voice to use. Leave out to use the default. |
75-
| `[volume]` | The volume to be used. Leave out to use the default. |
73+
| `text` | The text to say. |
74+
| `[sink]` | The ID of the voice to use. Leave out to use the default. |
75+
| `[volume]` | The volume to be used. Leave out to use the default. |
7676

7777
### `script.ScriptAction`
7878

@@ -81,4 +81,4 @@ This action executes the provided script.
8181
| Parameter | Description |
8282
|-----------|-------------------------------------------------------------------------|
8383
| `type` | The code/MIME-type for the scripting language. |
84-
| `script` | The script content to execute. |
84+
| `script` | The script content to execute. |

0 commit comments

Comments
 (0)