libmpdclient 2.9
playlist.h
Go to the documentation of this file.
1/* libmpdclient
2 (c) 2003-2010 The Music Player Daemon Project
3 This project's homepage is: http://www.musicpd.org
4
5 Redistribution and use in source and binary forms, with or without
6 modification, are permitted provided that the following conditions
7 are met:
8
9 - Redistributions of source code must retain the above copyright
10 notice, this list of conditions and the following disclaimer.
11
12 - Redistributions in binary form must reproduce the above copyright
13 notice, this list of conditions and the following disclaimer in the
14 documentation and/or other materials provided with the distribution.
15
16 - Neither the name of the Music Player Daemon nor the names of its
17 contributors may be used to endorse or promote products derived from
18 this software without specific prior written permission.
19
20 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21 ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR
24 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25 EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
27 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
28 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
29 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
30 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31*/
32
41#ifndef LIBMPDCLIENT_PLAYLIST_H
42#define LIBMPDCLIENT_PLAYLIST_H
43
44#include <mpd/compiler.h>
45
46#include <stdbool.h>
47#include <time.h>
48
49struct mpd_pair;
50struct mpd_connection;
51
59struct mpd_playlist;
60
61#ifdef __cplusplus
62extern "C" {
63#endif
64
68void
70
76mpd_malloc
77struct mpd_playlist *
78mpd_playlist_dup(const struct mpd_playlist *playlist);
79
84mpd_pure
85const char *
86mpd_playlist_get_path(const struct mpd_playlist *playlist);
87
92mpd_pure
93time_t
95
104mpd_malloc
105struct mpd_playlist *
106mpd_playlist_begin(const struct mpd_pair *pair);
107
116bool
117mpd_playlist_feed(struct mpd_playlist *playlist, const struct mpd_pair *pair);
118
125bool
127
134mpd_malloc
135struct mpd_playlist *
137
145bool
146mpd_send_list_playlist(struct mpd_connection *connection, const char *name);
147
155bool
156mpd_send_list_playlist_meta(struct mpd_connection *connection, const char *name);
157
158bool
159mpd_send_playlist_clear(struct mpd_connection *connection, const char *name);
160
161bool
162mpd_run_playlist_clear(struct mpd_connection *connection, const char *name);
163
164bool
165mpd_send_playlist_add(struct mpd_connection *connection, const char *name,
166 const char *path);
167
168bool
170 const char *name, const char *path);
171
172bool
173mpd_send_playlist_move(struct mpd_connection *connection, const char *name,
174 unsigned from, unsigned to);
175
176bool
177mpd_send_playlist_delete(struct mpd_connection *connection, const char *name,
178 unsigned pos);
179
180bool
182 const char *name, unsigned pos);
183
184bool
185mpd_send_save(struct mpd_connection *connection, const char *name);
186
187bool
188mpd_run_save(struct mpd_connection *connection, const char *name);
189
190bool
191mpd_send_load(struct mpd_connection *connection, const char *name);
192
193bool
194mpd_run_load(struct mpd_connection *connection, const char *name);
195
196bool
198 const char *from, const char *to);
199
200bool
202 const char *from, const char *to);
203
204bool
205mpd_send_rm(struct mpd_connection *connection, const char *name);
206
207bool
208mpd_run_rm(struct mpd_connection *connection, const char *name);
209
210#ifdef __cplusplus
211}
212#endif
213
214#endif
Compiler specific definitions.
bool mpd_run_playlist_add(struct mpd_connection *connection, const char *name, const char *path)
mpd_malloc struct mpd_playlist * mpd_playlist_begin(const struct mpd_pair *pair)
bool mpd_run_save(struct mpd_connection *connection, const char *name)
bool mpd_send_list_playlist_meta(struct mpd_connection *connection, const char *name)
bool mpd_send_rename(struct mpd_connection *connection, const char *from, const char *to)
bool mpd_send_save(struct mpd_connection *connection, const char *name)
void mpd_playlist_free(struct mpd_playlist *playlist)
bool mpd_playlist_feed(struct mpd_playlist *playlist, const struct mpd_pair *pair)
bool mpd_run_playlist_delete(struct mpd_connection *connection, const char *name, unsigned pos)
bool mpd_send_playlist_move(struct mpd_connection *connection, const char *name, unsigned from, unsigned to)
bool mpd_send_playlist_delete(struct mpd_connection *connection, const char *name, unsigned pos)
bool mpd_run_load(struct mpd_connection *connection, const char *name)
mpd_malloc struct mpd_playlist * mpd_recv_playlist(struct mpd_connection *connection)
bool mpd_send_playlist_clear(struct mpd_connection *connection, const char *name)
bool mpd_send_list_playlists(struct mpd_connection *connection)
bool mpd_run_rm(struct mpd_connection *connection, const char *name)
mpd_pure time_t mpd_playlist_get_last_modified(const struct mpd_playlist *playlist)
bool mpd_send_list_playlist(struct mpd_connection *connection, const char *name)
bool mpd_run_playlist_clear(struct mpd_connection *connection, const char *name)
bool mpd_send_load(struct mpd_connection *connection, const char *name)
mpd_pure const char * mpd_playlist_get_path(const struct mpd_playlist *playlist)
bool mpd_send_playlist_add(struct mpd_connection *connection, const char *name, const char *path)
bool mpd_run_rename(struct mpd_connection *connection, const char *from, const char *to)
bool mpd_send_rm(struct mpd_connection *connection, const char *name)
mpd_malloc struct mpd_playlist * mpd_playlist_dup(const struct mpd_playlist *playlist)
Definition: pair.h:41