Jellyfin Qt
QML Library for interacting with the Jellyfin multimedia server
Loading...
Searching...
No Matches
groupinfodto.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_GROUPINFODTO_H
31#define JELLYFIN_DTO_GROUPINFODTO_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 QString groupId,
56 QString groupName,
58 QStringList participants,
59 QDateTime lastUpdatedAt
60 );
61
62 GroupInfoDto(const GroupInfoDto &other);
63
67 void replaceData(GroupInfoDto &other);
68
69 static GroupInfoDto fromJson(QJsonObject source);
70 void setFromJson(QJsonObject source);
71 QJsonObject toJson() const;
72
73 // Properties
77 QString groupId() const;
81 void setGroupId(QString newGroupId);
82
86 QString groupName() const;
90 void setGroupName(QString newGroupName);
91
92
93 GroupStateType state() const;
94
95 void setState(GroupStateType newState);
96
100 QStringList participants() const;
104 void setParticipants(QStringList newParticipants);
105
109 QDateTime lastUpdatedAt() const;
113 void setLastUpdatedAt(QDateTime newLastUpdatedAt);
114
115
116protected:
117 QString m_groupId;
118 QString m_groupName;
120 QStringList m_participants;
122
123private:
124 // Private constructor which generates an invalid object, for use withing GroupInfoDto::fromJson();
125 GroupInfoDto();
126};
127
128
129} // NS DTO
130
131namespace Support {
132
134
135template <>
136GroupInfoDto fromJsonValue(const QJsonValue &source, convertType<GroupInfoDto>);
137
138template<>
139QJsonValue toJsonValue(const GroupInfoDto &source, convertType<GroupInfoDto>);
140
141} // NS DTO
142} // NS Jellyfin
143
144#endif // JELLYFIN_DTO_GROUPINFODTO_H
An Api client for Jellyfin. Handles requests and authentication.
Definition apiclient.h:90
Definition groupinfodto.h:52
QDateTime lastUpdatedAt() const
Gets the date when this DTO has been created.
Definition groupinfodto.cpp:119
GroupStateType m_state
Definition groupinfodto.h:119
QString groupId() const
Gets the group identifier.
Definition groupinfodto.cpp:95
QString m_groupName
Definition groupinfodto.h:118
static GroupInfoDto fromJson(QJsonObject source)
Definition groupinfodto.cpp:68
void replaceData(GroupInfoDto &other)
Definition groupinfodto.cpp:60
GroupInfoDto(QString groupId, QString groupName, GroupStateType state, QStringList participants, QDateTime lastUpdatedAt)
Definition groupinfodto.cpp:36
void setState(GroupStateType newState)
Definition groupinfodto.cpp:109
void setGroupId(QString newGroupId)
Gets the group identifier.
Definition groupinfodto.cpp:97
QJsonObject toJson() const
Definition groupinfodto.cpp:84
QString m_groupId
Definition groupinfodto.h:117
QStringList participants() const
Gets the participants.
Definition groupinfodto.cpp:113
GroupStateType state() const
Definition groupinfodto.cpp:107
QDateTime m_lastUpdatedAt
Definition groupinfodto.h:121
void setLastUpdatedAt(QDateTime newLastUpdatedAt)
Gets the date when this DTO has been created.
Definition groupinfodto.cpp:121
void setFromJson(QJsonObject source)
Definition groupinfodto.cpp:75
void setGroupName(QString newGroupName)
Gets the group name.
Definition groupinfodto.cpp:103
QStringList m_participants
Definition groupinfodto.h:120
QString groupName() const
Gets the group name.
Definition groupinfodto.cpp:101
void setParticipants(QStringList newParticipants)
Gets the participants.
Definition groupinfodto.cpp:115
Contains auto-generated Data Transfer Objects for the Jellyfin HTTP API.
GroupStateTypeClass::Value GroupStateType
Definition groupstatetype.h:61
Definition accessschedule.h:128
Jellyfin::DTO::GroupInfoDto GroupInfoDto
Definition groupinfodto.h:133
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