Jellyfin Qt
QML Library for interacting with the Jellyfin multimedia server
Loading...
Searching...
No Matches
artistinfo.h
Go to the documentation of this file.
1/*
2 * Sailfin: a Jellyfin client written using Qt
3 * Copyright (C) 2021 Chris Josten and the Sailfin Contributors.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library 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 GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 */
19/*
20 * WARNING: THIS IS AN AUTOMATICALLY GENERATED FILE! PLEASE DO NOT EDIT THIS, AS YOUR EDITS WILL GET
21 * OVERWRITTEN AT SOME POINT!
22 *
23 * If there is a bug in this file, please fix the code generator used to generate this file found in
24 * core/openapigenerator.d.
25 *
26 * This file is generated based on Jellyfin's OpenAPI description, "openapi.json". Please update that
27 * file with a newer file if needed instead of manually updating the files.
28 */
29
30#ifndef JELLYFIN_DTO_ARTISTINFO_H
31#define JELLYFIN_DTO_ARTISTINFO_H
32
33#include <QDateTime>
34#include <QJsonObject>
35#include <QJsonValue>
36#include <QList>
37#include <QString>
38#include <QStringList>
39#include <optional>
40
43
44namespace Jellyfin {
45// Forward declaration
46class ApiClient;
47}
48namespace Jellyfin {
49namespace DTO {
50
51
53public:
55 bool isAutomated,
57 );
58
59 ArtistInfo(const ArtistInfo &other);
60
64 void replaceData(ArtistInfo &other);
65
66 static ArtistInfo fromJson(QJsonObject source);
67 void setFromJson(QJsonObject source);
68 QJsonObject toJson() const;
69
70 // Properties
74 QString name() const;
78 void setName(QString newName);
79 bool nameNull() const;
80 void setNameNull();
81
85 QString originalTitle() const;
89 void setOriginalTitle(QString newOriginalTitle);
90 bool originalTitleNull() const;
92
96 QString path() const;
100 void setPath(QString newPath);
101 bool pathNull() const;
102 void setPathNull();
103
107 QString metadataLanguage() const;
111 void setMetadataLanguage(QString newMetadataLanguage);
112 bool metadataLanguageNull() const;
114
118 QString metadataCountryCode() const;
122 void setMetadataCountryCode(QString newMetadataCountryCode);
123 bool metadataCountryCodeNull() const;
125
129 QJsonObject providerIds() const;
133 void setProviderIds(QJsonObject newProviderIds);
134 bool providerIdsNull() const;
135 void setProviderIdsNull();
136
140 std::optional<qint32> year() const;
144 void setYear(std::optional<qint32> newYear);
145 bool yearNull() const;
146 void setYearNull();
147
148
149 std::optional<qint32> indexNumber() const;
150
151 void setIndexNumber(std::optional<qint32> newIndexNumber);
152 bool indexNumberNull() const;
153 void setIndexNumberNull();
154
155
156 std::optional<qint32> parentIndexNumber() const;
157
158 void setParentIndexNumber(std::optional<qint32> newParentIndexNumber);
159 bool parentIndexNumberNull() const;
161
162
163 QDateTime premiereDate() const;
164
165 void setPremiereDate(QDateTime newPremiereDate);
166 bool premiereDateNull() const;
167 void setPremiereDateNull();
168
169
170 bool isAutomated() const;
171
172 void setIsAutomated(bool newIsAutomated);
173
174
176
177 void setSongInfos(QList<SongInfo> newSongInfos);
178
179
180protected:
181 QString m_name;
183 QString m_path;
186 QJsonObject m_providerIds;
187 std::optional<qint32> m_year = std::nullopt;
188 std::optional<qint32> m_indexNumber = std::nullopt;
189 std::optional<qint32> m_parentIndexNumber = std::nullopt;
190 QDateTime m_premiereDate;
193
194private:
195 // Private constructor which generates an invalid object, for use withing ArtistInfo::fromJson();
196 ArtistInfo();
197};
198
199
200} // NS DTO
201
202namespace Support {
203
205
206template <>
207ArtistInfo fromJsonValue(const QJsonValue &source, convertType<ArtistInfo>);
208
209template<>
210QJsonValue toJsonValue(const ArtistInfo &source, convertType<ArtistInfo>);
211
212} // NS DTO
213} // NS Jellyfin
214
215#endif // JELLYFIN_DTO_ARTISTINFO_H
An Api client for Jellyfin. Handles requests and authentication.
Definition apiclient.h:90
Definition artistinfo.h:52
QJsonObject toJson() const
Definition artistinfo.cpp:99
void replaceData(ArtistInfo &other)
Definition artistinfo.cpp:61
QString m_metadataLanguage
Definition artistinfo.h:184
std::optional< qint32 > m_year
Definition artistinfo.h:187
void setPath(QString newPath)
Gets or sets the path.
Definition artistinfo.cpp:185
bool metadataCountryCodeNull() const
Definition artistinfo.cpp:214
bool m_isAutomated
Definition artistinfo.h:191
QString path() const
Gets or sets the path.
Definition artistinfo.cpp:183
QString m_metadataCountryCode
Definition artistinfo.h:185
void setName(QString newName)
Gets or sets the name.
Definition artistinfo.cpp:159
QJsonObject m_providerIds
Definition artistinfo.h:186
std::optional< qint32 > m_parentIndexNumber
Definition artistinfo.h:189
void setOriginalTitle(QString newOriginalTitle)
Gets or sets the original title.
Definition artistinfo.cpp:172
bool isAutomated() const
Definition artistinfo.cpp:287
QList< SongInfo > songInfos() const
Definition artistinfo.cpp:293
void setMetadataLanguage(QString newMetadataLanguage)
Gets or sets the metadata language.
Definition artistinfo.cpp:198
QString name() const
Gets or sets the name.
Definition artistinfo.cpp:157
QString m_originalTitle
Definition artistinfo.h:182
void setPathNull()
Definition artistinfo.cpp:192
bool parentIndexNumberNull() const
Definition artistinfo.cpp:266
std::optional< qint32 > parentIndexNumber() const
Definition artistinfo.cpp:261
bool pathNull() const
Definition artistinfo.cpp:188
void setPremiereDate(QDateTime newPremiereDate)
Definition artistinfo.cpp:276
void setMetadataLanguageNull()
Definition artistinfo.cpp:205
void setPremiereDateNull()
Definition artistinfo.cpp:283
QString m_path
Definition artistinfo.h:183
void setNameNull()
Definition artistinfo.cpp:166
bool metadataLanguageNull() const
Definition artistinfo.cpp:201
void setOriginalTitleNull()
Definition artistinfo.cpp:179
void setIsAutomated(bool newIsAutomated)
Definition artistinfo.cpp:289
void setMetadataCountryCodeNull()
Definition artistinfo.cpp:218
QString originalTitle() const
Gets or sets the original title.
Definition artistinfo.cpp:170
std::optional< qint32 > year() const
Gets or sets the year.
Definition artistinfo.cpp:235
void setSongInfos(QList< SongInfo > newSongInfos)
Definition artistinfo.cpp:295
void setProviderIdsNull()
Definition artistinfo.cpp:231
bool premiereDateNull() const
Definition artistinfo.cpp:279
void setProviderIds(QJsonObject newProviderIds)
Gets or sets the provider ids.
Definition artistinfo.cpp:224
std::optional< qint32 > m_indexNumber
Definition artistinfo.h:188
void setIndexNumber(std::optional< qint32 > newIndexNumber)
Definition artistinfo.cpp:250
QList< SongInfo > m_songInfos
Definition artistinfo.h:192
QJsonObject providerIds() const
Gets or sets the provider ids.
Definition artistinfo.cpp:222
std::optional< qint32 > indexNumber() const
Definition artistinfo.cpp:248
bool indexNumberNull() const
Definition artistinfo.cpp:253
void setFromJson(QJsonObject source)
Definition artistinfo.cpp:83
void setParentIndexNumber(std::optional< qint32 > newParentIndexNumber)
Definition artistinfo.cpp:263
bool yearNull() const
Definition artistinfo.cpp:240
void setParentIndexNumberNull()
Definition artistinfo.cpp:270
bool nameNull() const
Definition artistinfo.cpp:162
QString m_name
Definition artistinfo.h:181
void setYear(std::optional< qint32 > newYear)
Gets or sets the year.
Definition artistinfo.cpp:237
void setYearNull()
Definition artistinfo.cpp:244
QString metadataLanguage() const
Gets or sets the metadata language.
Definition artistinfo.cpp:196
void setIndexNumberNull()
Definition artistinfo.cpp:257
void setMetadataCountryCode(QString newMetadataCountryCode)
Gets or sets the metadata country code.
Definition artistinfo.cpp:211
bool providerIdsNull() const
Definition artistinfo.cpp:227
QDateTime m_premiereDate
Definition artistinfo.h:190
QString metadataCountryCode() const
Gets or sets the metadata country code.
Definition artistinfo.cpp:209
bool originalTitleNull() const
Definition artistinfo.cpp:175
QDateTime premiereDate() const
Definition artistinfo.cpp:274
ArtistInfo(bool isAutomated, QList< SongInfo > songInfos)
Definition artistinfo.cpp:36
static ArtistInfo fromJson(QJsonObject source)
Definition artistinfo.cpp:76
Definition mediaplayer2.h:20
Contains auto-generated Data Transfer Objects for the Jellyfin HTTP API.
Definition accessschedule.h:128
Jellyfin::DTO::ArtistInfo ArtistInfo
Definition artistinfo.h:204
AccessSchedule fromJsonValue(const QJsonValue &source, convertType< AccessSchedule >)
Definition accessschedule.cpp:133
QJsonValue toJsonValue(const AccessSchedule &source, convertType< AccessSchedule >)
Definition accessschedule.cpp:139
Definition jsonconvimpl.h:45