sticker.h
Go to the documentation of this file.
// SPDX-License-Identifier: BSD-2-Clause
// Copyright The Music Player Daemon Project
#ifndef MPD_STICKER_H
#define MPD_STICKER_H
#include "compiler.h"
#include <stdbool.h>
#include <stddef.h>
struct mpd_connection;
enum mpd_sticker_operator {
MPD_STICKER_OP_UNKOWN = -1,
MPD_STICKER_OP_EQ,
MPD_STICKER_OP_GT,
MPD_STICKER_OP_LT,
MPD_STICKER_OP_EQ_INT,
MPD_STICKER_OP_GT_INT,
MPD_STICKER_OP_LT_INT,
MPD_STICKER_OP_CONTAINS,
MPD_STICKER_OP_STARTS_WITH,
};
enum mpd_sticker_sort {
MPD_STICKER_SORT_UNKOWN = -1,
MPD_STICKER_SORT_URI,
MPD_STICKER_SORT_VALUE,
MPD_STICKER_SORT_VALUE_INT,
};
#ifdef __cplusplus
extern "C" {
#endif
bool
mpd_send_sticker_set(struct mpd_connection *connection, const char *type,
const char *uri, const char *name, const char *value);
bool
mpd_run_sticker_set(struct mpd_connection *connection, const char *type,
const char *uri, const char *name, const char *value);
bool
mpd_send_sticker_inc(struct mpd_connection *connection, const char *type,
const char *uri, const char *name, unsigned value);
bool
mpd_run_sticker_inc(struct mpd_connection *connection, const char *type,
const char *uri, const char *name, unsigned value);
bool
mpd_send_sticker_dec(struct mpd_connection *connection, const char *type,
const char *uri, const char *name, unsigned value);
bool
mpd_run_sticker_dec(struct mpd_connection *connection, const char *type,
const char *uri, const char *name, unsigned value);
bool
mpd_send_sticker_delete(struct mpd_connection *connection, const char *type,
const char *uri, const char *name);
bool
mpd_run_sticker_delete(struct mpd_connection *connection, const char *type,
const char *uri, const char *name);
bool
mpd_send_sticker_get(struct mpd_connection *connection, const char *type,
const char *uri, const char *name);
bool
mpd_send_sticker_list(struct mpd_connection *connection, const char *type,
const char *uri);
bool
mpd_send_sticker_find(struct mpd_connection *connection, const char *type,
const char *base_uri, const char *name);
const char *
mpd_parse_sticker(const char *input, size_t *name_length_r);
mpd_malloc
struct mpd_pair *
mpd_recv_sticker(struct mpd_connection *connection);
void
mpd_return_sticker(struct mpd_connection *connection, struct mpd_pair *pair);
bool
mpd_send_stickernames(struct mpd_connection *connection);
bool
mpd_send_stickertypes(struct mpd_connection *connection);
bool
mpd_send_stickernamestypes(struct mpd_connection *connection, const char *type);
bool
mpd_sticker_search_begin(struct mpd_connection *connection, const char *type,
const char *base_uri, const char *name);
bool
mpd_sticker_search_add_value_constraint(struct mpd_connection *connection,
enum mpd_sticker_operator oper,
const char *value);
bool
mpd_sticker_search_add_sort(struct mpd_connection *connection,
enum mpd_sticker_sort sort, bool descending);
bool
mpd_sticker_search_add_window(struct mpd_connection *connection,
unsigned start, unsigned end);
bool
mpd_sticker_search_commit(struct mpd_connection *connection);
void
mpd_sticker_search_cancel(struct mpd_connection *connection);
#ifdef __cplusplus
}
#endif
#endif /* MPD_STICKER_H */
mpd_sticker_operator
mpd_sticker_operator
Definition sticker.h:25
MPD_STICKER_OP_EQ_INT
@ MPD_STICKER_OP_EQ_INT
Definition sticker.h:30
MPD_STICKER_OP_EQ
@ MPD_STICKER_OP_EQ
Definition sticker.h:27
MPD_STICKER_OP_CONTAINS
@ MPD_STICKER_OP_CONTAINS
Definition sticker.h:33
MPD_STICKER_OP_GT_INT
@ MPD_STICKER_OP_GT_INT
Definition sticker.h:31
MPD_STICKER_OP_LT
@ MPD_STICKER_OP_LT
Definition sticker.h:29
MPD_STICKER_OP_GT
@ MPD_STICKER_OP_GT
Definition sticker.h:28
MPD_STICKER_OP_UNKOWN
@ MPD_STICKER_OP_UNKOWN
Definition sticker.h:26
MPD_STICKER_OP_LT_INT
@ MPD_STICKER_OP_LT_INT
Definition sticker.h:32
MPD_STICKER_OP_STARTS_WITH
@ MPD_STICKER_OP_STARTS_WITH
Definition sticker.h:34
mpd_sticker_search_cancel
void mpd_sticker_search_cancel(struct mpd_connection *connection)
mpd_run_sticker_set
bool mpd_run_sticker_set(struct mpd_connection *connection, const char *type, const char *uri, const char *name, const char *value)
mpd_send_stickertypes
bool mpd_send_stickertypes(struct mpd_connection *connection)
mpd_sticker_search_add_sort
bool mpd_sticker_search_add_sort(struct mpd_connection *connection, enum mpd_sticker_sort sort, bool descending)
mpd_run_sticker_delete
bool mpd_run_sticker_delete(struct mpd_connection *connection, const char *type, const char *uri, const char *name)
mpd_run_sticker_inc
bool mpd_run_sticker_inc(struct mpd_connection *connection, const char *type, const char *uri, const char *name, unsigned value)
mpd_send_stickernamestypes
bool mpd_send_stickernamestypes(struct mpd_connection *connection, const char *type)
mpd_sticker_search_add_value_constraint
bool mpd_sticker_search_add_value_constraint(struct mpd_connection *connection, enum mpd_sticker_operator oper, const char *value)
mpd_send_sticker_get
bool mpd_send_sticker_get(struct mpd_connection *connection, const char *type, const char *uri, const char *name)
mpd_send_sticker_delete
bool mpd_send_sticker_delete(struct mpd_connection *connection, const char *type, const char *uri, const char *name)
mpd_send_sticker_find
bool mpd_send_sticker_find(struct mpd_connection *connection, const char *type, const char *base_uri, const char *name)
mpd_recv_sticker
struct mpd_pair * mpd_recv_sticker(struct mpd_connection *connection)
mpd_run_sticker_dec
bool mpd_run_sticker_dec(struct mpd_connection *connection, const char *type, const char *uri, const char *name, unsigned value)
mpd_sticker_search_commit
bool mpd_sticker_search_commit(struct mpd_connection *connection)
mpd_sticker_search_add_window
bool mpd_sticker_search_add_window(struct mpd_connection *connection, unsigned start, unsigned end)
mpd_send_sticker_inc
bool mpd_send_sticker_inc(struct mpd_connection *connection, const char *type, const char *uri, const char *name, unsigned value)
mpd_send_stickernames
bool mpd_send_stickernames(struct mpd_connection *connection)
mpd_sticker_search_begin
bool mpd_sticker_search_begin(struct mpd_connection *connection, const char *type, const char *base_uri, const char *name)
mpd_sticker_sort
mpd_sticker_sort
Definition sticker.h:40
MPD_STICKER_SORT_VALUE
@ MPD_STICKER_SORT_VALUE
Definition sticker.h:43
MPD_STICKER_SORT_URI
@ MPD_STICKER_SORT_URI
Definition sticker.h:42
MPD_STICKER_SORT_VALUE_INT
@ MPD_STICKER_SORT_VALUE_INT
Definition sticker.h:44
MPD_STICKER_SORT_UNKOWN
@ MPD_STICKER_SORT_UNKOWN
Definition sticker.h:41
mpd_send_sticker_dec
bool mpd_send_sticker_dec(struct mpd_connection *connection, const char *type, const char *uri, const char *name, unsigned value)
mpd_send_sticker_set
bool mpd_send_sticker_set(struct mpd_connection *connection, const char *type, const char *uri, const char *name, const char *value)
mpd_return_sticker
void mpd_return_sticker(struct mpd_connection *connection, struct mpd_pair *pair)
mpd_parse_sticker
const char * mpd_parse_sticker(const char *input, size_t *name_length_r)
mpd_send_sticker_list
bool mpd_send_sticker_list(struct mpd_connection *connection, const char *type, const char *uri)
mpd_connection
mpd_pair
Definition pair.h:16
mpd_pair::name
const char * name
Definition pair.h:18
mpd_pair::value
const char * value
Definition pair.h:21