LeechCraft 0.6.70-17609-g3dde4097dd
Modular cross-platform feature rich live environment.
Loading...
Searching...
No Matches
audiostructs.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 <QStringList>
12#include <QVariantMap>
13#include <QUrl>
14#include <util/sll/eitherfwd.h>
15
16namespace Media
17{
20 struct AudioInfo
21 {
24 QString Artist_;
25
28 QString Album_;
29
32 QString Title_;
33
36 QStringList Genres_ {};
37
40 qint32 Length_ = 0;
41
44 qint32 Year_ = 0;
45
48 qint32 TrackNumber_ = 0;
49
56 QVariantMap Other_ {};
57
58 bool operator== (const AudioInfo& other) const = default;
59 bool operator!= (const AudioInfo& other) const = default;
60 };
61
64 struct TagInfo
65 {
68 QString Name_;
69
70 bool operator== (const TagInfo& other) const = default;
71 bool operator!= (const TagInfo& other) const = default;
72 };
73
77
81 {
84 QString Name_;
85
88 QString ShortDesc_;
89
92 QString FullDesc_;
93
96 QUrl Image_;
97
101
110 QUrl Page_;
111
115
116 bool operator== (const ArtistInfo& other) const = default;
117 bool operator!= (const ArtistInfo& other) const = default;
118 };
119
134 {
138
144
147 QStringList SimilarTo_;
148
149 bool operator== (const SimilarityInfo& other) const = default;
150 bool operator!= (const SimilarityInfo& other) const = default;
151 };
152
156
158}
159
LC::Util::Either< QString, SimilarityInfos_t > SimilarityQueryResult_t
QList< SimilarityInfo > SimilarityInfos_t
A list of SimilarityInfo structures.
QList< TagInfo > TagInfos_t
A list of tags.
A structure describing an artist.
QUrl Image_
An URL of a thumbnail artist image.
QString Name_
The artist name.
QString ShortDesc_
Short artist description.
QString FullDesc_
Full artist description, not including the short description.
bool operator==(const ArtistInfo &other) const =default
QUrl Page_
An URL to a page describing this artist.
bool operator!=(const ArtistInfo &other) const =default
TagInfos_t Tags_
Genres this artist plays in.
QUrl LargeImage_
A bigger artist image.
Describes a single audio track.
bool operator!=(const AudioInfo &other) const =default
QString Artist_
The artist performing this track.
qint32 Year_
The year of the Album_ this track is on.
QString Album_
The album this track is on.
QStringList Genres_
The genres of this track.
QVariantMap Other_
Other fields of this audio info.
qint32 TrackNumber_
The number of this track on the Album_.
bool operator==(const AudioInfo &other) const =default
qint32 Length_
The length of this track in seconds.
QString Title_
The title of this track.
Describes similarty information of an artist.
bool operator==(const SimilarityInfo &other) const =default
QStringList SimilarTo_
Names of the artists similar to this one.
ArtistInfo Artist_
Information about artist this similary info is about.
bool operator!=(const SimilarityInfo &other) const =default
int Similarity_
Similarity in percents.
Information about a tag like a genre.
QString Name_
Name of the tag.
bool operator!=(const TagInfo &other) const =default
bool operator==(const TagInfo &other) const =default
Q_DECLARE_METATYPE(QVariantList *)