/*
 * WARNING: This is a generated file. Do not modify directly.
 * Any changes made to this file will be overwritten.
 * 
 * Generated on: 2024-07-08
 * Generated by: TELEports tlparser.py
 * 
 * For any modifications, please edit the source templates and regenerate this file.
 */
    
#include "qtdemojistatus.h"

#include <QJsonObject>
#include <QJsonArray>

QTdEmojiStatus::QTdEmojiStatus(QObject *parent)
    : QTdObject(parent)
{
}

QTdEmojiStatus::QTdEmojiStatus(QObject *parent, qint64 customEmojiId_)
    :         m_customEmojiId(customEmojiId_) {
}

qint64 QTdEmojiStatus::customEmojiId() const {
    return m_customEmojiId;
}

void QTdEmojiStatus::setCustomEmojiId(qint64 value) {
    if (m_customEmojiId != value) {
        m_customEmojiId = value;
        emit dataChanged();
    }
}

QJsonObject QTdEmojiStatus::marshalJson() {
    return QJsonObject{
        { "@type", QTdObject::typeString() },
        { "custom_emoji_id", m_customEmojiId }
    };
}

void QTdEmojiStatus::unmarshalJson(const QJsonObject &json) {
    QJsonObject jsonObj;
    QJsonArray jsonArray;

    QTdObject::unmarshalJson(json);
    m_customEmojiId = json["custom_emoji_id"].toVariant().toLongLong();

    emit dataChanged();
}
