LeechCraft  0.6.70-16373-g319c272718
Modular cross-platform feature rich live environment.
idiscographyprovider.h
Go to the documentation of this file.
1 /**********************************************************************
2  * LeechCraft - modular cross-platform feature rich internet client.
3  * Copyright (C) 2006-2014 Georg Rudoy
4  *
5  * Distributed under the Boost Software License, Version 1.0.
6  * (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7  **********************************************************************/
8 
9 #pragma once
10 
11 #include <util/sll/either.h>
12 #include "audiostructs.h"
13 
14 template<typename>
15 class QFuture;
16 
17 namespace Media
18 {
27  {
30  int Number_;
31 
34  QString Name_;
35 
38  int Length_;
39  };
40 
45  struct ReleaseInfo
46  {
49  QString ID_;
50 
53  QString Name_;
54 
57  int Year_;
58 
61  enum class Type
62  {
65  Standard,
66 
69  EP,
70 
73  Single,
74 
78 
81  Live,
82 
85  Soundtrack,
86 
90  Other
91  } Type_;
92 
96  };
97 
107  class Q_DECL_EXPORT IDiscographyProvider
108  {
109  public:
110  virtual ~IDiscographyProvider () {}
111 
120 
128  virtual QString GetServiceName () const = 0;
129 
145  virtual QFuture<Result_t> GetDiscography (const QString& artist, const QStringList& hints) = 0;
146 
156  virtual QFuture<Result_t> GetReleaseInfo (const QString& artist, const QString& release) = 0;
157  };
158 }
159 
160 Q_DECLARE_INTERFACE (Media::IDiscographyProvider, "org.LeechCraft.Media.IDiscographyProvider/1.0")
enum Media::ReleaseInfo::Type Type_
Information about a track release.
QString ID_
The internal ID of this release.
A single track release.
QString Name_
The name of this release.
Information about a release, like an album or a single.
Interface for plugins supporting getting artist discography.
int Length_
The length of the track in this release.
Some other release type currently unrecognized by LeechCraft.
Type
The enum describing the recognized types of the releases.
QString Name_
The name of the track.
int Number_
The number of the track in the release.
int Year_
The year of this release.
QList< QList< ReleaseTrackInfo > > TrackInfos_