mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-30 09:03:23 -05:00
f9d9964914
This parser actually supports way more than is needed for RSP proper, as mt-daapd was piggybacking on the RSP queries for its smart playlists. As I don't have (yet?) the RSP specs, better safe than sorry here. This will be revisited at some point. Or not.
32 lines
510 B
C
32 lines
510 B
C
|
|
#ifndef __RSP_QUERY_H__
|
|
#define __RSP_QUERY_H__
|
|
|
|
#include <stdint.h>
|
|
|
|
#define RSP_TYPE_STRING 0
|
|
#define RSP_TYPE_INT 1
|
|
#define RSP_TYPE_DATE 2
|
|
|
|
struct rsp_query_field_map {
|
|
uint32_t hash;
|
|
int field_type;
|
|
char *rsp_field;
|
|
/* RSP fields are named after the DB columns - or vice versa */
|
|
};
|
|
|
|
|
|
struct rsp_query_field_map *
|
|
rsp_query_field_lookup(char *field);
|
|
|
|
char *
|
|
rsp_query_parse_sql(const char *rsp_query);
|
|
|
|
int
|
|
rsp_query_init(void);
|
|
|
|
void
|
|
rsp_query_deinit(void);
|
|
|
|
#endif /* !__RSP_QUERY_H__ */
|