diff options
author | Max Kellermann <max@duempel.org> | 2011-09-10 19:24:30 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2011-09-13 19:37:28 +0200 |
commit | 169db88c20dc7601f8589cfa298254c932f0947a (patch) | |
tree | b0cc3af153237379a1dbbb2fa90eb37eed05752f /src/database.h | |
parent | ca419c84b83d017c3e4309e22f92273500197eea (diff) | |
download | mpd-169db88c20dc7601f8589cfa298254c932f0947a.tar.gz mpd-169db88c20dc7601f8589cfa298254c932f0947a.tar.xz mpd-169db88c20dc7601f8589cfa298254c932f0947a.zip |
database: add struct db_visitor
Use this struct for db_walk().
Diffstat (limited to 'src/database.h')
-rw-r--r-- | src/database.h | 8 |
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); |