// This file generated by libqtelegram-code-generator.
// You can download it from: https://github.com/Aseman-Land/libqtelegram-code-generator
// DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN

#ifndef LQTG_TYPE_INPUTMEDIA
#define LQTG_TYPE_INPUTMEDIA

#include "telegramtypeobject.h"

#include <QMetaType>
#include <QVariant>
#include "../coretypes.h"

#include <QDataStream>

#include <QString>
#include <QList>
#include "documentattribute.h"
#include "inputfile.h"
#include <QtGlobal>
#include "inputgeopoint.h"
#include "inputdocument.h"
#include "inputgame.h"
#include "inputphoto.h"
#include "invoice.h"
#include <QByteArray>
#include "inputwebdocument.h"

class LIBQTELEGRAMSHARED_EXPORT InputMedia : public TelegramTypeObject
{
public:
    enum InputMediaClassType {
        typeInputMediaEmpty = 0x9664f57f,
        typeInputMediaUploadedPhoto = 0x630c9af1,
        typeInputMediaPhoto = 0xe9bfb4f3,
        typeInputMediaGeoPoint = 0xf9c44144,
        typeInputMediaContact = 0xa6e45987,
        typeInputMediaUploadedDocument = 0xd070f1e9,
        typeInputMediaUploadedThumbDocument = 0x50d88cae,
        typeInputMediaDocument = 0x1a77f29c,
        typeInputMediaVenue = 0x2827a81a,
        typeInputMediaGifExternal = 0x4843b0fd,
        typeInputMediaPhotoExternal = 0xb55f4f18,
        typeInputMediaDocumentExternal = 0xe5e9607c,
        typeInputMediaGame = 0xd33f43f3,
        typeInputMediaInvoice = 0x92153685
    };

    InputMedia(InputMediaClassType classType = typeInputMediaEmpty, InboundPkt *in = 0);
    InputMedia(InboundPkt *in);
    InputMedia(const Null&);
    InputMedia(const InputMedia &another);
    virtual ~InputMedia();

    void setAddress(const QString &address);
    QString address() const;

    void setAttributes(const QList<DocumentAttribute> &attributes);
    QList<DocumentAttribute> attributes() const;

    void setCaption(const QString &caption);
    QString caption() const;

    void setDescription(const QString &description);
    QString description() const;

    void setFile(const InputFile &file);
    InputFile file() const;

    void setFirstName(const QString &firstName);
    QString firstName() const;

    void setFlags(qint32 flags);
    qint32 flags() const;

    void setGeoPoint(const InputGeoPoint &geoPoint);
    InputGeoPoint geoPoint() const;

    void setIdInputDocument(const InputDocument &idInputDocument);
    InputDocument idInputDocument() const;

    void setIdInputGame(const InputGame &idInputGame);
    InputGame idInputGame() const;

    void setIdInputPhoto(const InputPhoto &idInputPhoto);
    InputPhoto idInputPhoto() const;

    void setInvoice(const Invoice &invoice);
    Invoice invoice() const;

    void setLastName(const QString &lastName);
    QString lastName() const;

    void setMimeType(const QString &mimeType);
    QString mimeType() const;

    void setPayload(const QByteArray &payload);
    QByteArray payload() const;

    void setPhoneNumber(const QString &phoneNumber);
    QString phoneNumber() const;

    void setPhoto(const InputWebDocument &photo);
    InputWebDocument photo() const;

    void setProvider(const QString &provider);
    QString provider() const;

    void setQ(const QString &q);
    QString q() const;

    void setStartParam(const QString &startParam);
    QString startParam() const;

    void setStickers(const QList<InputDocument> &stickers);
    QList<InputDocument> stickers() const;

    void setThumb(const InputFile &thumb);
    InputFile thumb() const;

    void setTitle(const QString &title);
    QString title() const;

    void setUrl(const QString &url);
    QString url() const;

    void setVenueId(const QString &venueId);
    QString venueId() const;

    void setClassType(InputMediaClassType classType);
    InputMediaClassType classType() const;

    bool fetch(InboundPkt *in);
    bool push(OutboundPkt *out) const;

    QMap<QString, QVariant> toMap() const;
    static InputMedia fromMap(const QMap<QString, QVariant> &map);
    static InputMedia fromJson(const QString &json);

    bool operator ==(const InputMedia &b) const;
    InputMedia &operator =(const InputMedia &b);

    bool operator==(bool stt) const { return isNull() != stt; }
    bool operator!=(bool stt) const { return !operator ==(stt); }

    QByteArray getHash(QCryptographicHash::Algorithm alg = QCryptographicHash::Md5) const;

private:
    QString m_address;
    QList<DocumentAttribute> m_attributes;
    QString m_caption;
    QString m_description;
    InputFile m_file;
    QString m_firstName;
    qint32 m_flags;
    InputGeoPoint m_geoPoint;
    InputDocument m_idInputDocument;
    InputGame m_idInputGame;
    InputPhoto m_idInputPhoto;
    Invoice m_invoice;
    QString m_lastName;
    QString m_mimeType;
    QByteArray m_payload;
    QString m_phoneNumber;
    InputWebDocument m_photo;
    QString m_provider;
    QString m_q;
    QString m_startParam;
    QList<InputDocument> m_stickers;
    InputFile m_thumb;
    QString m_title;
    QString m_url;
    QString m_venueId;
    InputMediaClassType m_classType;
};

Q_DECLARE_METATYPE(InputMedia)

QDataStream LIBQTELEGRAMSHARED_EXPORT &operator<<(QDataStream &stream, const InputMedia &item);
QDataStream LIBQTELEGRAMSHARED_EXPORT &operator>>(QDataStream &stream, InputMedia &item);

QDebug LIBQTELEGRAMSHARED_EXPORT operator<<(QDebug debug,  const InputMedia &item);

#endif // LQTG_TYPE_INPUTMEDIA
