![]() |
LeechCraft
0.6.70-10870-g558588d6ec
Modular cross-platform feature rich live environment.
|
Interface for plugins that support fetching hypes. More...
#include "ihypesprovider.h"
Public Types | |
enum | HypeType { HypeType::NewArtists, HypeType::NewTracks, HypeType::TopArtists, HypeType::TopTracks } |
The type of the hype. More... | |
using | HypeQueryResult_t = LeechCraft::Util::Either< QString, HypedInfo_t > |
Public Member Functions | |
virtual | ~IHypesProvider () |
virtual QString | GetServiceName () const =0 |
Returns the service name. More... | |
virtual bool | SupportsHype (HypeType hype)=0 |
Returns whether the service supports the given hype type. More... | |
virtual QFuture< HypeQueryResult_t > | RequestHype (HypeType type)=0 |
Updates the list of hyped artists of the given type. More... | |
Interface for plugins that support fetching hypes.
Hypes are either popular tracks and artists or those who gain a lot of popularity right now.
Fetching hypes is asynchronous in nature, so one should request updating the hypes list via RequestHype() method for each hype type one is interesting in, and then listen to gotHypedArtists() and gotHypedTracks() signals correspondingly.
Definition at line 173 of file ihypesprovider.h.
using Media::IHypesProvider::HypeQueryResult_t = LeechCraft::Util::Either<QString, HypedInfo_t> |
Definition at line 178 of file ihypesprovider.h.
|
strong |
The type of the hype.
Enumerator | |
---|---|
NewArtists | New artists rapidly growing in popularity. |
NewTracks | New tracks rapidly growing in popularity. |
TopArtists | Top artists. |
TopTracks | Top tracks. |
Definition at line 191 of file ihypesprovider.h.
|
inlinevirtual |
Definition at line 176 of file ihypesprovider.h.
|
pure virtual |
Returns the service name.
This string returns a human-readable string with the service name, like "Last.FM".
|
pure virtual |
Updates the list of hyped artists of the given type.
[in] | type | The type of the hype to update. |
|
pure virtual |
Returns whether the service supports the given hype type.
[in] | hype | The hype type to query. |