/* * Sailfin: a Jellyfin client written using Qt * Copyright (C) 2021 Chris Josten and the Sailfin Contributors. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ /* * WARNING: THIS IS AN AUTOMATICALLY GENERATED FILE! PLEASE DO NOT EDIT THIS, AS YOUR EDITS WILL GET * OVERWRITTEN AT SOME POINT! * * If there is a bug in this file, please fix the code generator used to generate this file found in * core/openapigenerator.d. * * This file is generated based on Jellyfin's OpenAPI description, "openapi.json". Please update that * file with a newer file if needed instead of manually updating the files. */ #include namespace Jellyfin { namespace DTO { DeviceProfile::DeviceProfile(QObject *parent) {} DeviceProfile DeviceProfile::fromJson(QJsonObject source) {DeviceProfile instance; instance->setFromJson(source, false); return instance; } void DeviceProfile::setFromJson(QJsonObject source) { m_name = fromJsonValue(source["Name"]); m_jellyfinId = fromJsonValue(source["Id"]); m_identification = fromJsonValue>(source["Identification"]); m_friendlyName = fromJsonValue(source["FriendlyName"]); m_manufacturer = fromJsonValue(source["Manufacturer"]); m_manufacturerUrl = fromJsonValue(source["ManufacturerUrl"]); m_modelName = fromJsonValue(source["ModelName"]); m_modelDescription = fromJsonValue(source["ModelDescription"]); m_modelNumber = fromJsonValue(source["ModelNumber"]); m_modelUrl = fromJsonValue(source["ModelUrl"]); m_serialNumber = fromJsonValue(source["SerialNumber"]); m_enableAlbumArtInDidl = fromJsonValue(source["EnableAlbumArtInDidl"]); m_enableSingleAlbumArtLimit = fromJsonValue(source["EnableSingleAlbumArtLimit"]); m_enableSingleSubtitleLimit = fromJsonValue(source["EnableSingleSubtitleLimit"]); m_supportedMediaTypes = fromJsonValue(source["SupportedMediaTypes"]); m_userId = fromJsonValue(source["UserId"]); m_albumArtPn = fromJsonValue(source["AlbumArtPn"]); m_maxAlbumArtWidth = fromJsonValue(source["MaxAlbumArtWidth"]); m_maxAlbumArtHeight = fromJsonValue(source["MaxAlbumArtHeight"]); m_maxIconWidth = fromJsonValue(source["MaxIconWidth"]); m_maxIconHeight = fromJsonValue(source["MaxIconHeight"]); m_maxStreamingBitrate = fromJsonValue(source["MaxStreamingBitrate"]); m_maxStaticBitrate = fromJsonValue(source["MaxStaticBitrate"]); m_musicStreamingTranscodingBitrate = fromJsonValue(source["MusicStreamingTranscodingBitrate"]); m_maxStaticMusicBitrate = fromJsonValue(source["MaxStaticMusicBitrate"]); m_sonyAggregationFlags = fromJsonValue(source["SonyAggregationFlags"]); m_protocolInfo = fromJsonValue(source["ProtocolInfo"]); m_timelineOffsetSeconds = fromJsonValue(source["TimelineOffsetSeconds"]); m_requiresPlainVideoItems = fromJsonValue(source["RequiresPlainVideoItems"]); m_requiresPlainFolders = fromJsonValue(source["RequiresPlainFolders"]); m_enableMSMediaReceiverRegistrar = fromJsonValue(source["EnableMSMediaReceiverRegistrar"]); m_ignoreTranscodeByteRangeRequests = fromJsonValue(source["IgnoreTranscodeByteRangeRequests"]); m_xmlRootAttributes = fromJsonValue>>(source["XmlRootAttributes"]); m_directPlayProfiles = fromJsonValue>>(source["DirectPlayProfiles"]); m_transcodingProfiles = fromJsonValue>>(source["TranscodingProfiles"]); m_containerProfiles = fromJsonValue>>(source["ContainerProfiles"]); m_codecProfiles = fromJsonValue>>(source["CodecProfiles"]); m_responseProfiles = fromJsonValue>>(source["ResponseProfiles"]); m_subtitleProfiles = fromJsonValue>>(source["SubtitleProfiles"]); } QJsonObject DeviceProfile::toJson() { QJsonObject result; result["Name"] = toJsonValue(m_name); result["Id"] = toJsonValue(m_jellyfinId); result["Identification"] = toJsonValue>(m_identification); result["FriendlyName"] = toJsonValue(m_friendlyName); result["Manufacturer"] = toJsonValue(m_manufacturer); result["ManufacturerUrl"] = toJsonValue(m_manufacturerUrl); result["ModelName"] = toJsonValue(m_modelName); result["ModelDescription"] = toJsonValue(m_modelDescription); result["ModelNumber"] = toJsonValue(m_modelNumber); result["ModelUrl"] = toJsonValue(m_modelUrl); result["SerialNumber"] = toJsonValue(m_serialNumber); result["EnableAlbumArtInDidl"] = toJsonValue(m_enableAlbumArtInDidl); result["EnableSingleAlbumArtLimit"] = toJsonValue(m_enableSingleAlbumArtLimit); result["EnableSingleSubtitleLimit"] = toJsonValue(m_enableSingleSubtitleLimit); result["SupportedMediaTypes"] = toJsonValue(m_supportedMediaTypes); result["UserId"] = toJsonValue(m_userId); result["AlbumArtPn"] = toJsonValue(m_albumArtPn); result["MaxAlbumArtWidth"] = toJsonValue(m_maxAlbumArtWidth); result["MaxAlbumArtHeight"] = toJsonValue(m_maxAlbumArtHeight); result["MaxIconWidth"] = toJsonValue(m_maxIconWidth); result["MaxIconHeight"] = toJsonValue(m_maxIconHeight); result["MaxStreamingBitrate"] = toJsonValue(m_maxStreamingBitrate); result["MaxStaticBitrate"] = toJsonValue(m_maxStaticBitrate); result["MusicStreamingTranscodingBitrate"] = toJsonValue(m_musicStreamingTranscodingBitrate); result["MaxStaticMusicBitrate"] = toJsonValue(m_maxStaticMusicBitrate); result["SonyAggregationFlags"] = toJsonValue(m_sonyAggregationFlags); result["ProtocolInfo"] = toJsonValue(m_protocolInfo); result["TimelineOffsetSeconds"] = toJsonValue(m_timelineOffsetSeconds); result["RequiresPlainVideoItems"] = toJsonValue(m_requiresPlainVideoItems); result["RequiresPlainFolders"] = toJsonValue(m_requiresPlainFolders); result["EnableMSMediaReceiverRegistrar"] = toJsonValue(m_enableMSMediaReceiverRegistrar); result["IgnoreTranscodeByteRangeRequests"] = toJsonValue(m_ignoreTranscodeByteRangeRequests); result["XmlRootAttributes"] = toJsonValue>>(m_xmlRootAttributes); result["DirectPlayProfiles"] = toJsonValue>>(m_directPlayProfiles); result["TranscodingProfiles"] = toJsonValue>>(m_transcodingProfiles); result["ContainerProfiles"] = toJsonValue>>(m_containerProfiles); result["CodecProfiles"] = toJsonValue>>(m_codecProfiles); result["ResponseProfiles"] = toJsonValue>>(m_responseProfiles); result["SubtitleProfiles"] = toJsonValue>>(m_subtitleProfiles); return result; } QString DeviceProfile::name() const { return m_name; } void DeviceProfile::setName(QString newName) { m_name = newName; } QString DeviceProfile::jellyfinId() const { return m_jellyfinId; } void DeviceProfile::setJellyfinId(QString newJellyfinId) { m_jellyfinId = newJellyfinId; } QSharedPointer DeviceProfile::identification() const { return m_identification; } void DeviceProfile::setIdentification(QSharedPointer newIdentification) { m_identification = newIdentification; } QString DeviceProfile::friendlyName() const { return m_friendlyName; } void DeviceProfile::setFriendlyName(QString newFriendlyName) { m_friendlyName = newFriendlyName; } QString DeviceProfile::manufacturer() const { return m_manufacturer; } void DeviceProfile::setManufacturer(QString newManufacturer) { m_manufacturer = newManufacturer; } QString DeviceProfile::manufacturerUrl() const { return m_manufacturerUrl; } void DeviceProfile::setManufacturerUrl(QString newManufacturerUrl) { m_manufacturerUrl = newManufacturerUrl; } QString DeviceProfile::modelName() const { return m_modelName; } void DeviceProfile::setModelName(QString newModelName) { m_modelName = newModelName; } QString DeviceProfile::modelDescription() const { return m_modelDescription; } void DeviceProfile::setModelDescription(QString newModelDescription) { m_modelDescription = newModelDescription; } QString DeviceProfile::modelNumber() const { return m_modelNumber; } void DeviceProfile::setModelNumber(QString newModelNumber) { m_modelNumber = newModelNumber; } QString DeviceProfile::modelUrl() const { return m_modelUrl; } void DeviceProfile::setModelUrl(QString newModelUrl) { m_modelUrl = newModelUrl; } QString DeviceProfile::serialNumber() const { return m_serialNumber; } void DeviceProfile::setSerialNumber(QString newSerialNumber) { m_serialNumber = newSerialNumber; } bool DeviceProfile::enableAlbumArtInDidl() const { return m_enableAlbumArtInDidl; } void DeviceProfile::setEnableAlbumArtInDidl(bool newEnableAlbumArtInDidl) { m_enableAlbumArtInDidl = newEnableAlbumArtInDidl; } bool DeviceProfile::enableSingleAlbumArtLimit() const { return m_enableSingleAlbumArtLimit; } void DeviceProfile::setEnableSingleAlbumArtLimit(bool newEnableSingleAlbumArtLimit) { m_enableSingleAlbumArtLimit = newEnableSingleAlbumArtLimit; } bool DeviceProfile::enableSingleSubtitleLimit() const { return m_enableSingleSubtitleLimit; } void DeviceProfile::setEnableSingleSubtitleLimit(bool newEnableSingleSubtitleLimit) { m_enableSingleSubtitleLimit = newEnableSingleSubtitleLimit; } QString DeviceProfile::supportedMediaTypes() const { return m_supportedMediaTypes; } void DeviceProfile::setSupportedMediaTypes(QString newSupportedMediaTypes) { m_supportedMediaTypes = newSupportedMediaTypes; } QString DeviceProfile::userId() const { return m_userId; } void DeviceProfile::setUserId(QString newUserId) { m_userId = newUserId; } QString DeviceProfile::albumArtPn() const { return m_albumArtPn; } void DeviceProfile::setAlbumArtPn(QString newAlbumArtPn) { m_albumArtPn = newAlbumArtPn; } qint32 DeviceProfile::maxAlbumArtWidth() const { return m_maxAlbumArtWidth; } void DeviceProfile::setMaxAlbumArtWidth(qint32 newMaxAlbumArtWidth) { m_maxAlbumArtWidth = newMaxAlbumArtWidth; } qint32 DeviceProfile::maxAlbumArtHeight() const { return m_maxAlbumArtHeight; } void DeviceProfile::setMaxAlbumArtHeight(qint32 newMaxAlbumArtHeight) { m_maxAlbumArtHeight = newMaxAlbumArtHeight; } qint32 DeviceProfile::maxIconWidth() const { return m_maxIconWidth; } void DeviceProfile::setMaxIconWidth(qint32 newMaxIconWidth) { m_maxIconWidth = newMaxIconWidth; } qint32 DeviceProfile::maxIconHeight() const { return m_maxIconHeight; } void DeviceProfile::setMaxIconHeight(qint32 newMaxIconHeight) { m_maxIconHeight = newMaxIconHeight; } qint32 DeviceProfile::maxStreamingBitrate() const { return m_maxStreamingBitrate; } void DeviceProfile::setMaxStreamingBitrate(qint32 newMaxStreamingBitrate) { m_maxStreamingBitrate = newMaxStreamingBitrate; } qint32 DeviceProfile::maxStaticBitrate() const { return m_maxStaticBitrate; } void DeviceProfile::setMaxStaticBitrate(qint32 newMaxStaticBitrate) { m_maxStaticBitrate = newMaxStaticBitrate; } qint32 DeviceProfile::musicStreamingTranscodingBitrate() const { return m_musicStreamingTranscodingBitrate; } void DeviceProfile::setMusicStreamingTranscodingBitrate(qint32 newMusicStreamingTranscodingBitrate) { m_musicStreamingTranscodingBitrate = newMusicStreamingTranscodingBitrate; } qint32 DeviceProfile::maxStaticMusicBitrate() const { return m_maxStaticMusicBitrate; } void DeviceProfile::setMaxStaticMusicBitrate(qint32 newMaxStaticMusicBitrate) { m_maxStaticMusicBitrate = newMaxStaticMusicBitrate; } QString DeviceProfile::sonyAggregationFlags() const { return m_sonyAggregationFlags; } void DeviceProfile::setSonyAggregationFlags(QString newSonyAggregationFlags) { m_sonyAggregationFlags = newSonyAggregationFlags; } QString DeviceProfile::protocolInfo() const { return m_protocolInfo; } void DeviceProfile::setProtocolInfo(QString newProtocolInfo) { m_protocolInfo = newProtocolInfo; } qint32 DeviceProfile::timelineOffsetSeconds() const { return m_timelineOffsetSeconds; } void DeviceProfile::setTimelineOffsetSeconds(qint32 newTimelineOffsetSeconds) { m_timelineOffsetSeconds = newTimelineOffsetSeconds; } bool DeviceProfile::requiresPlainVideoItems() const { return m_requiresPlainVideoItems; } void DeviceProfile::setRequiresPlainVideoItems(bool newRequiresPlainVideoItems) { m_requiresPlainVideoItems = newRequiresPlainVideoItems; } bool DeviceProfile::requiresPlainFolders() const { return m_requiresPlainFolders; } void DeviceProfile::setRequiresPlainFolders(bool newRequiresPlainFolders) { m_requiresPlainFolders = newRequiresPlainFolders; } bool DeviceProfile::enableMSMediaReceiverRegistrar() const { return m_enableMSMediaReceiverRegistrar; } void DeviceProfile::setEnableMSMediaReceiverRegistrar(bool newEnableMSMediaReceiverRegistrar) { m_enableMSMediaReceiverRegistrar = newEnableMSMediaReceiverRegistrar; } bool DeviceProfile::ignoreTranscodeByteRangeRequests() const { return m_ignoreTranscodeByteRangeRequests; } void DeviceProfile::setIgnoreTranscodeByteRangeRequests(bool newIgnoreTranscodeByteRangeRequests) { m_ignoreTranscodeByteRangeRequests = newIgnoreTranscodeByteRangeRequests; } QList> DeviceProfile::xmlRootAttributes() const { return m_xmlRootAttributes; } void DeviceProfile::setXmlRootAttributes(QList> newXmlRootAttributes) { m_xmlRootAttributes = newXmlRootAttributes; } QList> DeviceProfile::directPlayProfiles() const { return m_directPlayProfiles; } void DeviceProfile::setDirectPlayProfiles(QList> newDirectPlayProfiles) { m_directPlayProfiles = newDirectPlayProfiles; } QList> DeviceProfile::transcodingProfiles() const { return m_transcodingProfiles; } void DeviceProfile::setTranscodingProfiles(QList> newTranscodingProfiles) { m_transcodingProfiles = newTranscodingProfiles; } QList> DeviceProfile::containerProfiles() const { return m_containerProfiles; } void DeviceProfile::setContainerProfiles(QList> newContainerProfiles) { m_containerProfiles = newContainerProfiles; } QList> DeviceProfile::codecProfiles() const { return m_codecProfiles; } void DeviceProfile::setCodecProfiles(QList> newCodecProfiles) { m_codecProfiles = newCodecProfiles; } QList> DeviceProfile::responseProfiles() const { return m_responseProfiles; } void DeviceProfile::setResponseProfiles(QList> newResponseProfiles) { m_responseProfiles = newResponseProfiles; } QList> DeviceProfile::subtitleProfiles() const { return m_subtitleProfiles; } void DeviceProfile::setSubtitleProfiles(QList> newSubtitleProfiles) { m_subtitleProfiles = newSubtitleProfiles; } } // NS Jellyfin } // NS DTO