MPD 0.20.6

- Main Page
- Namespaces
- Data Structures
- Files

- File List
- Globals

PlaylistFile.hxx
Go to the documentation of this file.
1 /*
2 * Copyright 2003-2017 The Music Player Daemon Project
3 * http://www.musicpd.org
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 */
19
20 #ifndef MPD_PLAYLIST_FILE_HXX
21 #define MPD_PLAYLIST_FILE_HXX
22
23 #include <vector>
24 #include <string>
25
26 class DetachedSong;
27 class SongLoader;
28 class PlaylistVector;
29 class AllocatedPath;
30
31 typedef std::vector<std::string> PlaylistFileContents;
32
33 extern bool playlist_saveAbsolutePaths;
34
38 void
39 spl_global_init();
40
45 bool
46 spl_valid_name(const char *name_utf8);
47
48 AllocatedPath
49 spl_map_to_fs(const char *name_utf8);
50
54 PlaylistVector
55 ListPlaylistFiles();
56
57 PlaylistFileContents
58 LoadPlaylistFile(const char *utf8path);
59
60 void
61 spl_move_index(const char *utf8path, unsigned src, unsigned dest);
62
63 void
64 spl_clear(const char *utf8path);
65
66 void
67 spl_delete(const char *name_utf8);
68
69 void
70 spl_remove_index(const char *utf8path, unsigned pos);
71
72 void
73 spl_append_song(const char *utf8path, const DetachedSong &song);
74
78 void
79 spl_append_uri(const char *path_utf8,
80 const SongLoader &loader, const char *uri_utf8);
81
82 void
83 spl_rename(const char *utf8from, const char *utf8to);
84
85 #endif
PlaylistFileContents
std::vector< std::string > PlaylistFileContents
Definition: PlaylistFile.hxx:29
spl_map_to_fs
AllocatedPath spl_map_to_fs(const char *name_utf8)
AllocatedPath
A path name in the native file system character set.
Definition: AllocatedPath.hxx:38
path_utf8
const Storage const char const char * path_utf8
Definition: DatabasePlaylist.hxx:31
ListPlaylistFiles
PlaylistVector ListPlaylistFiles()
Returns a list of stored_playlist_info struct pointers.
PlaylistVector
Definition: PlaylistVector.hxx:28
spl_rename
void spl_rename(const char *utf8from, const char *utf8to)
spl_append_uri
void spl_append_uri(const char *path_utf8, const SongLoader &loader, const char *uri_utf8)
Throws #std::runtime_error on error.
spl_append_song
void spl_append_song(const char *utf8path, const DetachedSong &song)
spl_delete
void spl_delete(const char *name_utf8)
spl_clear
void spl_clear(const char *utf8path)
LoadPlaylistFile
PlaylistFileContents LoadPlaylistFile(const char *utf8path)
SongLoader
A utility class that loads a DetachedSong object by its URI.
Definition: SongLoader.hxx:41
spl_remove_index
void spl_remove_index(const char *utf8path, unsigned pos)
DetachedSong
Definition: DetachedSong.hxx:37
spl_move_index
void spl_move_index(const char *utf8path, unsigned src, unsigned dest)
spl_global_init
void spl_global_init()
Perform some global initialization, e.g.
spl_valid_name
bool spl_valid_name(const char *name_utf8)
Determines whether the specified string is a valid name for a stored playlist.
playlist_saveAbsolutePaths
bool playlist_saveAbsolutePaths