Jellyfin Qt
QML Library for interacting with the Jellyfin multimedia server
Loading...
Searching...
No Matches
bufferrequestdto.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_BUFFERREQUESTDTO_H
31#define JELLYFIN_DTO_BUFFERREQUESTDTO_H
32
33#include <QDateTime>
34#include <QJsonObject>
35#include <QJsonValue>
36#include <QString>
37#include <optional>
38
40
41namespace Jellyfin {
42// Forward declaration
43class ApiClient;
44}
45namespace Jellyfin {
46namespace DTO {
47
48
50public:
52 QDateTime when,
53 qint64 positionTicks,
54 bool isPlaying,
55 QString playlistItemId
56 );
57
59
63 void replaceData(BufferRequestDto &other);
64
65 static BufferRequestDto fromJson(QJsonObject source);
66 void setFromJson(QJsonObject source);
67 QJsonObject toJson() const;
68
69 // Properties
73 QDateTime when() const;
77 void setWhen(QDateTime newWhen);
78
82 qint64 positionTicks() const;
86 void setPositionTicks(qint64 newPositionTicks);
87
91 bool isPlaying() const;
95 void setIsPlaying(bool newIsPlaying);
96
100 QString playlistItemId() const;
104 void setPlaylistItemId(QString newPlaylistItemId);
105
106
107protected:
108 QDateTime m_when;
112
113private:
114 // Private constructor which generates an invalid object, for use withing BufferRequestDto::fromJson();
116};
117
118
119} // NS DTO
120
121namespace Support {
122
124
125template <>
127
128template<>
130
131} // NS DTO
132} // NS Jellyfin
133
134#endif // JELLYFIN_DTO_BUFFERREQUESTDTO_H
Definition bufferrequestdto.h:49
void setIsPlaying(bool newIsPlaying)
Gets or sets a value indicating whether the client playback is unpaused.
Definition bufferrequestdto.cpp:103
qint64 positionTicks() const
Gets or sets the position ticks.
Definition bufferrequestdto.cpp:95
QString m_playlistItemId
Definition bufferrequestdto.h:111
void replaceData(BufferRequestDto &other)
Definition bufferrequestdto.cpp:57
void setFromJson(QJsonObject source)
Definition bufferrequestdto.cpp:71
void setPlaylistItemId(QString newPlaylistItemId)
Gets or sets the playlist item identifier of the playing item.
Definition bufferrequestdto.cpp:109
QDateTime m_when
Definition bufferrequestdto.h:108
bool m_isPlaying
Definition bufferrequestdto.h:110
qint64 m_positionTicks
Definition bufferrequestdto.h:109
void setWhen(QDateTime newWhen)
Gets or sets when the request has been made by the client.
Definition bufferrequestdto.cpp:91
QString playlistItemId() const
Gets or sets the playlist item identifier of the playing item.
Definition bufferrequestdto.cpp:107
bool isPlaying() const
Gets or sets a value indicating whether the client playback is unpaused.
Definition bufferrequestdto.cpp:101
QDateTime when() const
Gets or sets when the request has been made by the client.
Definition bufferrequestdto.cpp:89
void setPositionTicks(qint64 newPositionTicks)
Gets or sets the position ticks.
Definition bufferrequestdto.cpp:97
QJsonObject toJson() const
Definition bufferrequestdto.cpp:79
static BufferRequestDto fromJson(QJsonObject source)
Definition bufferrequestdto.cpp:64
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