|
myMPD
Internal API documentation
|
myMPD state for Lua scripts More...
#include "compile_time.h"#include "src/mympd_api/lua_mympd_state.h"#include "src/lib/cache/cache_rax_album.h"#include "src/lib/log.h"#include "src/lib/mem.h"#include "src/lib/sds_extras.h"#include "src/lib/utility.h"#include "src/mympd_api/status.h"#include "src/mympd_client/errorhandler.h"#include "src/mympd_client/shortcuts.h"
Functions | |
| static void | lua_mympd_state_free_user_data (struct t_list_node *current) |
| bool | mympd_api_status_lua_mympd_state_set (struct t_list *lua_partition_state, struct t_mympd_state *mympd_state, struct t_partition_state *partition_state) |
| void | lua_mympd_state_set_mpd_song (struct t_list *lua_mympd_state, const char *k, const struct mpd_song *song) |
| void | lua_mympd_state_set_p (struct t_list *lua_mympd_state, const char *k, const char *v) |
| void | lua_mympd_state_set_i (struct t_list *lua_mympd_state, const char *k, int64_t v) |
| void | lua_mympd_state_set_f (struct t_list *lua_mympd_state, const char *k, double v) |
| void | lua_mympd_state_set_u (struct t_list *lua_mympd_state, const char *k, unsigned v) |
| void | lua_mympd_state_set_b (struct t_list *lua_mympd_state, const char *k, bool v) |
| void | lua_mympd_state_free (struct t_list *lua_mympd_state) |
| void | lua_mympd_state_free_void (void *lua_mympd_state) |
myMPD state for Lua scripts
| void lua_mympd_state_free | ( | struct t_list * | lua_mympd_state | ) |
Frees the lua_mympd_state list
| lua_mympd_state | pointer to the list |
|
static |
Private definitions
Private functions Callback for lua_mympd_state_free to free string values
| current | pointer to the list node |
| void lua_mympd_state_free_void | ( | void * | lua_mympd_state | ) |
Frees the lua_mympd_state list
| lua_mympd_state | void pointer to lua_mympd_state |
| void lua_mympd_state_set_b | ( | struct t_list * | lua_mympd_state, |
| const char * | k, | ||
| bool | v | ||
| ) |
Pushes a bool value to the lua_mympd_state list
| lua_mympd_state | pointer to a t_list struct |
| k | variable name |
| v | variable value |
| void lua_mympd_state_set_f | ( | struct t_list * | lua_mympd_state, |
| const char * | k, | ||
| double | v | ||
| ) |
Pushes a double value to the lua_mympd_state list
| lua_mympd_state | pointer to a t_list struct |
| k | variable name |
| v | variable value |
| void lua_mympd_state_set_i | ( | struct t_list * | lua_mympd_state, |
| const char * | k, | ||
| int64_t | v | ||
| ) |
Pushes an int64_t value to the lua_mympd_state list
| lua_mympd_state | pointer to a t_list struct |
| k | variable name |
| v | variable value |
| void lua_mympd_state_set_mpd_song | ( | struct t_list * | lua_mympd_state, |
| const char * | k, | ||
| const struct mpd_song * | song | ||
| ) |
Pushes a copy of a MPD song to the lua_mympd_state list
| lua_mympd_state | pointer to a t_list struct |
| k | variable name |
| song | Pointer to MPD song struct |
| void lua_mympd_state_set_p | ( | struct t_list * | lua_mympd_state, |
| const char * | k, | ||
| const char * | v | ||
| ) |
Pushes a string to the lua_mympd_state list
| lua_mympd_state | pointer to a t_list struct |
| k | variable name |
| v | variable value |
| void lua_mympd_state_set_u | ( | struct t_list * | lua_mympd_state, |
| const char * | k, | ||
| unsigned | v | ||
| ) |
Pushes a unsigned int value to the lua_mympd_state list
| lua_mympd_state | pointer to a t_list struct |
| k | variable name |
| v | variable value |
| bool mympd_api_status_lua_mympd_state_set | ( | struct t_list * | lua_partition_state, |
| struct t_mympd_state * | mympd_state, | ||
| struct t_partition_state * | partition_state | ||
| ) |
Public functions Copies mpd and myMPD states to the lua_mympd_state struct
| lua_partition_state | pointer to struct t_list |
| mympd_state | pointer to mympd_state |
| partition_state | pointer to partition state |