MPD
Main Page
Data Structures
Files
File List
Globals
src
archive_plugin.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2003-2010 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_ARCHIVE_PLUGIN_H
21
#define MPD_ARCHIVE_PLUGIN_H
22
23
#include <glib.h>
24
25
#include <stdbool.h>
26
27
struct
input_stream
;
28
struct
archive_file
;
29
30
struct
archive_plugin
{
31
const
char
*
name
;
32
38
bool (*
init
)(void);
39
44
void (*
finish
)(void);
45
51
struct
archive_file
*(*open)(
const
char
*path_fs, GError **error_r);
52
58
void (*
scan_reset
)(
struct
archive_file
*);
59
65
char
*(*scan_next)(
struct
archive_file
*);
66
74
struct
input_stream
*(*open_stream)(
struct
archive_file
*af,
75
const
char
*path,
76
GError **error_r);
77
81
void (*
close
)(
struct
archive_file
*);
82
87
const
char
*
const
*
suffixes
;
88
};
89
90
struct
archive_file
*
91
archive_file_open
(
const
struct
archive_plugin
*
plugin
,
const
char
*path,
92
GError **error_r);
93
94
void
95
archive_file_close
(
struct
archive_file
*file);
96
97
void
98
archive_file_scan_reset
(
struct
archive_file
*file);
99
100
char
*
101
archive_file_scan_next
(
struct
archive_file
*file);
102
103
struct
input_stream
*
104
archive_file_open_stream
(
struct
archive_file
*file,
105
const
char
*path, GError **error_r);
106
107
#endif
Generated on Sun Aug 12 2012 21:58:00 for MPD by
1.8.2