aboutsummaryrefslogtreecommitdiffstats
path: root/src/DatabaseSimple.hxx (unfollow)
Commit message (Collapse)AuthorFilesLines
2013-01-30TagPool, ...: include cleanupMax Kellermann1-3/+1
2013-01-03Directory: rename struct directory to DirectoryMax Kellermann1-3/+3
2013-01-03database.h: rename to DatabaseSimple.hxxMax Kellermann1-3/+3
2013-01-03database.h: move prototypes to DatabaseGlue.hxxMax Kellermann1-14/+0
2013-01-03database.h: eliminate db_*_song()Max Kellermann1-9/+0
Use the C++ API.
2012-08-16DatabasePlugin: add method ReturnSong()Max Kellermann1-0/+4
Allow the plugin to allocate the GetSong() return value.
2012-08-08DatabaseGlue: pass block to db_init()Max Kellermann1-2/+2
Let the caller take care for legacy conversion.
2012-08-08DatabaseGlue: add function db_is_simple()Max Kellermann1-0/+18
Preparing for non-"simple" database plugins.
2012-08-02DatabaseGlue: remove db_walk(), db_visit()Max Kellermann1-12/+0
Unused.
2012-08-02gcc.h: re-add gcc_const and gcc_pureMax Kellermann1-5/+5
Remove GLib dependency from some headers.
2012-02-13database: add "pure" attributesMax Kellermann1-0/+5
2012-02-13database: remove obsolete prototype db_check()Max Kellermann1-3/+0
2012-02-02directory: require the caller to lock the db_mutexMax Kellermann1-0/+3
Reduce the number of lock/unlock cycles, and make database handling safer.
2011-09-13db_plugin: add method visit()Max Kellermann1-0/+7
2011-09-13database: don't allow uri==NULLMax Kellermann1-0/+5
Add nonnull attributes and fix all callers.
2011-09-13database: add struct db_visitorMax Kellermann1-3/+5
Use this struct for db_walk().
2011-09-10db_plugin: introducing a plugin API for the song databaseMax Kellermann1-8/+3
First draft, not really pluggable currently - hard-coded to use the "simple" plugin, and calls several of its internal functions. The API is very simple currently, all searches are still performed over the root "directory" object. Future changes to the API will move those search implementations into the plugin, to allow more efficient implementations, or implementations that don't have the whole tree in memory all the time.
2011-09-09database: return GError on failureMax Kellermann1-2/+2
2011-01-29copyright year 2011Max Kellermann1-1/+1
2009-12-31Update copyright notices.Avuton Olrich1-1/+1
2009-03-13all: Update copyright header.Avuton Olrich1-7/+7
This updates the copyright header to all be the same, which is pretty much an update of where to mail request for a copy of the GPL and the years of the MPD project. This also puts all committers under 'The Music Player Project' umbrella. These entries should go individually in the AUTHORS file, for consistancy.
2009-03-02database: db_load() returns GErrorMax Kellermann1-1/+3
Do error reporting with GLib's GError library.
2009-01-18mapper: make the music_directory optionalMax Kellermann1-0/+4
Without a music_directory, MPD is an excellent streaming client.
2009-01-18database: pass database file name to db_init()Max Kellermann1-7/+5
Don't include conf.h in database.c.
2009-01-08update: save the database even if it is emptyMax Kellermann1-0/+11
Save an empty database, even if the music directory is empty.
2009-01-04database: use stdboolMax Kellermann1-3/+4
Make db_load(), db_save() and db_check() return bool instead of int.
2009-01-04database: db_init() initializes library, does not updateMax Kellermann1-0/+13
For updating the database, directory_update_init() should be called explicitly.
2008-10-31added prefix to header macrosMax Kellermann1-2/+2
"LOG_H" is a macro which is also used by ffmpeg/log.h. This is ffmpeg's fault, because short macros should be reserved for applications, but since it's always a good idea to choose prefixed macro names, even for applications, we are going to do that in MPD.
2008-10-09database: renamed get_get_song() to db_get_song()Max Kellermann1-1/+1
Search'n'replace typo..
2008-10-08database: renamed functions, "db_" prefix and no CamelCaseMax Kellermann1-12/+18
Yet another CamelCase removal patch.
2008-10-08database: removed printDirectoryInfo()Max Kellermann1-3/+0
The same can be achieved with directory_print(db_get_directory()).
2008-10-08directory: moved code to database.cMax Kellermann1-17/+27
Taming the directory.c monster, part II: move the database management stuff to database. directory.c should only contain code which works on directory objects.
2008-10-08directory: converted typedef Directory to struct directoryMax Kellermann1-2/+2
The struct can be forward-declared by other headers, which relaxes the header dependencies.
2008-10-08update: merged exploreDirectory() into updateDirectory()Max Kellermann1-1/+1
exploreDirectory() duplicates some code in updateDirectory(). Merge both functions, and use directory_is_empty() to determine whether update or explore mode should be used.
2008-10-08directory: moved code to update.cMax Kellermann1-10/+20
The source directory.c mixes several libraries: directory object management, database management and database update, resulting in a 1000+ line monster. Move the whole database update code to update.c.
2008-09-07audio_format: converted typedef AudioFormat to struct audio_formatMax Kellermann1-3/+4
Get rid of CamelCase, and don't use a typedef, so we can forward-declare it, and unclutter the include dependencies.
2008-08-26moved code to crossfade.cMax Kellermann1-9/+10
decode.c should be a lot smaller; start by moving all code which handles cross-fading to crossfade.c. Also includes camelCase conversion.
2008-08-26clean up CPP includesMax Kellermann1-2/+0
Include only headers which are really required. This speeds up compilation and helps detect cross-layer accesses.
2008-06-02remove audioDeviceStates from playerData and getPlayerDataEric Wong1-8/+0
git-svn-id: https://svn.musicpd.org/mpd/trunk@7372 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-13Make the OutputBuffer API more consistentEric Wong1-1/+1
We had functions names varied between outputBufferFoo, fooOutputBuffer, and output_buffer_foo That was too confusing for my little brain to handle. And the global variable was somehow named 'cb' instead of the more obvious 'ob'... git-svn-id: https://svn.musicpd.org/mpd/trunk@7355 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-13Stop passing our single OutputBuffer object everywhereEric Wong1-1/+1
All of our main singleton data structures are implicitly shared, so there's no reason to keep passing them around and around in the stack and making our internal API harder to deal with. git-svn-id: https://svn.musicpd.org/mpd/trunk@7354 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-13Stop passing our single DecoderControl object everywhereEric Wong1-1/+1
This at least makes the argument list to a lot of our plugin functions shorter and removes a good amount of line nois^W^Wcode, hopefully making things easier to read and follow. git-svn-id: https://svn.musicpd.org/mpd/trunk@7353 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-13Get rid of PlayerControl inside the PlayerData structEric Wong1-1/+1
It actually increases our image size a small bit and may even hurt performance a very small bit, but makes the code less verbose and easier to manage. I don't see a reason for mpd to ever support playing multiple files at the same time (users can run multiple instances of mpd if they really want to play Zaireeka, but that's such an edge case it's not worth ever supporting in our code). git-svn-id: https://svn.musicpd.org/mpd/trunk@7352 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-12clean up CPP includesMax Kellermann1-2/+0
Try to only include headers which are really needed. We should particularly check all "headers including other headers". The long-term goal is to have a manageable, small API for plugins (decoders, output) without so many mpd internals cluttering the namespace. git-svn-id: https://svn.musicpd.org/mpd/trunk@7319 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-12remove buffered_chunks, use cb->sizeMax Kellermann1-1/+0
Second patch to make OutputBuffer self-contained: since OutputBuffer now knows its own size, we do not need the global variable "buffered_chunks" anymore. git-svn-id: https://svn.musicpd.org/mpd/trunk@7311 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-12moved CHUNK_SIZE to outputBuffer.hMax Kellermann1-3/+0
The chunk size should be in outputBuffer.h since the output buffer code is its primary user. git-svn-id: https://svn.musicpd.org/mpd/trunk@7268 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2008-04-12unsigned integers in playerData.[ch]Max Kellermann1-2/+2
The number of buffered chunks can obviously not become negative. The "buffered_before_play<0" therefore cannot be useful, so let's remove it, too. git-svn-id: https://svn.musicpd.org/mpd/trunk@7232 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2007-04-05The massive copyright updateAvuton Olrich1-1/+1
git-svn-id: https://svn.musicpd.org/mpd/trunk@5834 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2006-08-20Fix warnings for -Wmissing-prototypesAvuton Olrich1-3/+3
Add -Wmissing-prototypes if compiling with gcc Static where possible git-svn-id: https://svn.musicpd.org/mpd/trunk@4657 09075e82-0dd4-0310-85a5-a0d7c8717e4f
2006-08-06merge changes from mpd-tree:Warren Dukes1-3/+0
-use tree for tagTracker -eliminate the master process git-svn-id: https://svn.musicpd.org/mpd/trunk@4571 09075e82-0dd4-0310-85a5-a0d7c8717e4f