Variables API functions.
More...
#include "dist/sds/sds.h"
#include "src/lib/list.h"
#include <stdbool.h>
Go to the source code of this file.
◆ scripts_vars_delete()
| bool scripts_vars_delete |
( |
struct t_list * |
script_var_list, |
|
|
sds |
key |
|
) |
| |
Deletes a variable in the list
- Parameters
-
| script_var_list | pointer to script var list |
| key | key to remove |
- Returns
- true on success, else false
◆ scripts_vars_file_read()
| bool scripts_vars_file_read |
( |
struct t_list * |
script_var_list, |
|
|
sds |
workdir |
|
) |
| |
Reads the scripts variables from the filesystem
- Parameters
-
| script_var_list | pointer to script var list |
| workdir | working directory |
- Returns
- true on success, else false
◆ scripts_vars_file_save()
| bool scripts_vars_file_save |
( |
struct t_list * |
script_var_list, |
|
|
sds |
workdir |
|
) |
| |
Writes the home icons to the filesystem
- Parameters
-
| script_var_list | pointer to script var list |
| workdir | working directory |
- Returns
- true on success, else false
◆ scripts_vars_list()
| sds scripts_vars_list |
( |
struct t_list * |
script_var_list, |
|
|
sds |
buffer, |
|
|
unsigned |
request_id |
|
) |
| |
Returns a jsonrpc response with all script variables
- Parameters
-
| script_var_list | pointer to script var list |
| buffer | buffer to append the response |
| request_id | jsonrpc request id |
- Returns
- pointer to buffer
◆ scripts_vars_save()
| bool scripts_vars_save |
( |
struct t_list * |
script_var_list, |
|
|
sds |
key, |
|
|
sds |
value |
|
) |
| |
Adds/modifies a variable in the list
- Parameters
-
| script_var_list | pointer to script var list |
| key | name of the variable |
| value | value of the variable |
- Returns
- true on success, else false