aboutsummaryrefslogtreecommitdiffstats
path: root/src/database.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2011-09-10 19:24:30 +0200
committerMax Kellermann <max@duempel.org>2011-09-13 19:37:28 +0200
commit169db88c20dc7601f8589cfa298254c932f0947a (patch)
treeb0cc3af153237379a1dbbb2fa90eb37eed05752f /src/database.h
parentca419c84b83d017c3e4309e22f92273500197eea (diff)
downloadmpd-169db88c20dc7601f8589cfa298254c932f0947a.tar.gz
mpd-169db88c20dc7601f8589cfa298254c932f0947a.tar.xz
mpd-169db88c20dc7601f8589cfa298254c932f0947a.zip
database: add struct db_visitor
Use this struct for db_walk().
Diffstat (limited to '')
-rw-r--r--src/database.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/database.h b/src/database.h
index 3e834ab84..ab9114f2d 100644
--- a/src/database.h
+++ b/src/database.h
@@ -27,6 +27,7 @@
struct config_param;
struct directory;
+struct db_visitor;
/**
* Initialize the database library.
@@ -52,9 +53,10 @@ db_get_directory(const char *name);
struct song *
db_get_song(const char *file);
-int db_walk(const char *name,
- int (*forEachSong)(struct song *, void *),
- int (*forEachDir)(struct directory *, void *), void *data);
+bool
+db_walk(const char *uri,
+ const struct db_visitor *visitor, void *ctx,
+ GError **error_r);
bool
db_check(GError **error_r);