PageRenderTime 41ms CodeModel.GetById 20ms app.highlight 3ms RepoModel.GetById 17ms app.codeStats 0ms

/src/libtomahawk/infosystem/infoplugins/generic/musicbrainzPlugin.h

http://github.com/tomahawk-player/tomahawk
C++ Header | 69 lines | 36 code | 16 blank | 17 comment | 0 complexity | ae9a46bdd6794a7e338d0a2836c3b3e0 MD5 | raw file
 1/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
 2 *
 3 *   Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
 4 *
 5 *   Tomahawk 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 3 of the License, or
 8 *   (at your option) any later version.
 9 *
10 *   Tomahawk 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
16 *   along with Tomahawk. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19#ifndef MUSICBRAINZPLUGIN_H
20#define MUSICBRAINZPLUGIN_H
21
22#include "infosystem/infosystem.h"
23#include "infosystem/infosystemworker.h"
24
25class QNetworkReply;
26
27namespace Tomahawk
28{
29
30namespace InfoSystem
31{
32
33class MusicBrainzPlugin : public InfoPlugin
34{
35    Q_OBJECT
36
37public:
38    MusicBrainzPlugin();
39    virtual ~MusicBrainzPlugin();
40
41protected slots:
42    virtual void getInfo( Tomahawk::InfoSystem::InfoRequestData requestData );
43    virtual void notInCacheSlot( InfoStringHash criteria, InfoRequestData requestData );
44
45    virtual void pushInfo( QString caller, Tomahawk::InfoSystem::InfoType type, QVariant data )
46    {
47        Q_UNUSED( caller );
48        Q_UNUSED( type );
49        Q_UNUSED( data );
50    }
51
52
53private slots:
54    void artistSearchSlot();
55    void albumSearchSlot();
56    void tracksSearchSlot();
57
58    void albumFoundSlot();
59    void tracksFoundSlot();
60
61private:
62    bool isValidTrackData( Tomahawk::InfoSystem::InfoRequestData requestData );
63};
64
65}
66
67}
68
69#endif // MUSICBRAINZPLUGIN_H